mongos数据分布不均匀,move chunk失败

现象

2018-02-06T14:41:05.130+0800 I SHARDING [Balancer] moveChunk result: { cause: { ok: 0.0, errmsg: "can't accept new chunks because  there are still 1236 deletes from previous migration" }, ok: 0.0, errmsg: "moveChunk failed to engage TO-shard in the data transfer:  :: caused by :: UnknownError: can't accept new chunks because  there are still 1236 deletes...", code: 8 }

mongos集群数据分布不均匀,后台日志显示move chunk失败,我尝试手工迁移,报错一样

mongos> sh.moveChunk("recruit.externalResumeStorage", {"rid" : "1836776472", "sourceId" : 6}, "udb-f4rrmx")

{
"cause" : {
"cause" : {
"ok" : 0,
"errmsg" : "can't accept new chunks because  there are still 1236 deletes from previous migration"
},
"ok" : 0,
"errmsg" : "moveChunk failed to engage TO-shard in the data transfer:  :: caused by :: UnknownError: can't accept new chunks because  there are still 1236 deletes from previous migration",
"code" : 8
},
"code" : 8,
"ok" : 0,
"errmsg" : "move failed"
}

故障原因

应该是bug,参考https://jira.mongodb.org/browse/SERVER-14047

解决方法

重启整个mongos集群,包括mongos节点,config节点,sharding节点


你可能感兴趣的:(NoSQL/MongoDB,DB故障处理案例)