mirror of
https://github.com/mongodb/mongo.git
synced 2024-12-01 09:32:32 +01:00
better logging messages
This commit is contained in:
parent
bf56f218e8
commit
6c3aac4b9a
@ -737,7 +737,7 @@ namespace mongo {
|
||||
connTo.done();
|
||||
|
||||
if ( ! ok ){
|
||||
errmsg = "_recvChunkStart failed: ";
|
||||
errmsg = "moveChunk failed to engage TO-shard in the data transfer: ";
|
||||
assert( res["errmsg"].type() );
|
||||
errmsg += res["errmsg"].String();
|
||||
result.append( "cause" , res );
|
||||
@ -757,12 +757,12 @@ namespace mongo {
|
||||
res = res.getOwned();
|
||||
conn.done();
|
||||
|
||||
log(0) << "_recvChunkStatus : " << res << " my mem used: " << migrateFromStatus.mbUsed() << endl;
|
||||
log(0) << "moveChunk data transfer progress: " << res << " my mem used: " << migrateFromStatus.mbUsed() << endl;
|
||||
|
||||
if ( ! ok || res["state"].String() == "fail" ){
|
||||
log( LL_ERROR ) << "_recvChunkStatus error : " << res << endl;
|
||||
errmsg = "_recvChunkStatus error";
|
||||
result.append( "cause" ,res );
|
||||
log( LL_WARNING ) << "moveChunk error transfering data caused migration abort: " << res << endl;
|
||||
errmsg = "data transfer error";
|
||||
result.append( "cause" , res );
|
||||
return false;
|
||||
}
|
||||
|
||||
@ -818,8 +818,6 @@ namespace mongo {
|
||||
res );
|
||||
connTo.done();
|
||||
|
||||
log() << "moveChunk commit result: " << res << endl;
|
||||
|
||||
if ( ! ok ){
|
||||
{
|
||||
writelock lk( ns );
|
||||
@ -828,7 +826,8 @@ namespace mongo {
|
||||
shardingState.undoDonateChunk( ns , min , max , currVersion );
|
||||
}
|
||||
|
||||
log() << "_recvChunkCommit failed: " << res << " resetting shard version to: " << currVersion << endl;
|
||||
log() << "movChunk migrate commit not accepted by TO-shard: " << res
|
||||
<< " resetting shard version to: " << currVersion << endl;
|
||||
|
||||
errmsg = "_recvChunkCommit failed!";
|
||||
result.append( "cause" , res );
|
||||
@ -919,7 +918,7 @@ namespace mongo {
|
||||
|
||||
} else {
|
||||
|
||||
log() << "moveChunk: no chunks left to update version for collection '" << ns << "'" << endl;
|
||||
log() << "moveChunk moved last chunk out for collection '" << ns << "'" << endl;
|
||||
}
|
||||
|
||||
updates.done();
|
||||
@ -957,7 +956,7 @@ namespace mongo {
|
||||
//
|
||||
// if the commit made it to the config, we'll see the chunk in the new shard and there's no action
|
||||
// if the commit did not make it, currently the only way to fix this state is to bounce the mongod so
|
||||
// that the old state (before migrating) we'll be brought in
|
||||
// that the old state (before migrating) be brought in
|
||||
|
||||
log( LL_WARNING ) << "moveChunk commit outcome ongoing: " << cmd << " for command :" << cmdResult << endl;
|
||||
sleepsecs( 10 );
|
||||
|
Loading…
Reference in New Issue
Block a user