[SERVER-15821] Empty host split assertion message in log when maxSize prevents move chunk Created: 27/Oct/14  Updated: 11/Jul/16  Resolved: 29/Oct/14

Status: Closed
Project: Core Server
Component/s: Sharding
Affects Version/s: 2.7.8
Fix Version/s: 2.8.0-rc0

Type: Bug Priority: Minor - P4
Reporter: Jonathan Abrahams Assignee: Randolph Tan
Resolution: Done Votes: 0
Labels: 28qa
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
Operating System: ALL
Steps To Reproduce:

var st = new ShardingTest("maxSize", 2, 1, 1, {shards: 2, chunksize: 1, manualAddShard: true});
var dbName = "test";
var collName = "topchunk";
var db = st.getDB(dbName);
var coll = db[collName];
var configDB = st.s.getDB('config');
 
st.startBalancer();
db.adminCommand({configureFailPoint: 'skipBalanceRound', mode: 'alwaysOn'});
 
st.adminCommand({addshard: st.getConnNames()[0], maxSize: 5});
st.adminCommand({addshard: st.getConnNames()[1], maxSize: 1});
 
db.adminCommand({enableSharding: dbName});
db.adminCommand({movePrimary: dbName, to: 'shard0000'});
db.adminCommand({shardCollection: coll+"", key: {x: 1}});
 
db.adminCommand({split: coll+"", middle: {x: 1000}});
db.adminCommand({moveChunk: coll+"", find: {x: 1000}, to: 'shard0000'});
 
db.adminCommand({split: coll+"", middle: {x: 0}});
db.adminCommand({moveChunk: coll+"", find: {x: 0}, to: 'shard0001'});
 
db.printShardingStatus(true);
 
// Auto split assertion does not occur on bulk write to low top chunk
var largeStr = new Array(1000).join('x');
var bulk = coll.initializeUnorderedBulkOp();
for (var x = -2000; x < -2750; x--) {
    bulk.insert({ x: x, val: largeStr });
}
bulk.execute();
 
// Auto split assertion happens on bulk write to high top chunk
bulk = coll.initializeUnorderedBulkOp();
for (var x = 2000; x < 2750; x++) {
    bulk.insert({ x: x, val: largeStr });
}
bulk.execute();
 
db.printShardingStatus(true);
 
st.stop();

Participants:

 Description   

The mongos has the following assertion message in the log, when an auto split occurs on a high top chunk and maxSize prevents the move chunk:

 m30999| 2014-10-27T16:43:22.123-0400 I SHARDING [conn1] autosplitted test.topchunk shard: ns: test.topchunk, sh
ard: shard0000:localhost:30000, lastmod: 1|38||000000000000000000000000, min: { x: 1475.0 }, max: { x: MaxKey }
into 3 (splitThreshold 943718) (migrate suggested)
 m30999| 2014-10-27T16:43:22.124-0400 D SHARDING [conn1] found 2 shards listed on config server(s): localhost:30
000 (127.0.0.1)
 m30999| 2014-10-27T16:43:22.125-0400 D SHARDING [conn1] shard0000 has already reached the maximum total chunk s
ize.
 m30999| 2014-10-27T16:43:22.125-0400 D SHARDING [conn1] shard0001 has already reached the maximum total chunk s
ize.
 m30999| 2014-10-27T16:43:22.125-0400 I SHARDING [conn1] moving chunk (auto): ns: test.topchunk, shard: shard000
0:localhost:30000, lastmod: 2|4||000000000000000000000000, min: { x: 2749.0 }, max: { x: MaxKey } to:
 m30999| 2014-10-27T16:43:22.125-0400 D -        [conn1] User Assertion: 9:Empty host component parsing HostAndPort from ""
 m30999| 2014-10-27T16:43:22.125-0400 W SHARDING [conn1] could not autosplit collection test.topchunk :: caused by :: 9 Empty host component parsing HostAndPort from ""



 Comments   
Comment by Githook User [ 29/Oct/14 ]

Author:

{u'username': u'renctan', u'name': u'Randolph Tan', u'email': u'randolph@10gen.com'}

Message: SERVER-15821 Empty host split assertion message in log when maxSize prevents move chunk
Branch: master
https://github.com/mongodb/mongo/commit/873f985afc5d4ad88f8be57f19fde6a3814ad5d6

Generated at Thu Feb 08 03:39:06 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.