赛雷feng
2018-11-14 17:10
复制集当前的primary是23001端口实例,但是通过rs.status()看到的23002端口实例syncingTo指向另一个从节点23005实例。
"members" : [
{
"_id" : 0,
"name" : "10.10.99.102:23001",
"health" : 1,
"state" : 1,
"stateStr" : "PRIMARY",
"uptime" : 6976,
"optime" : {
"ts" : Timestamp(1542186401, 1),
"t" : NumberLong(6)
},
"optimeDurable" : {
"ts" : Timestamp(1542186401, 1),
"t" : NumberLong(6)
},
"optimeDate" : ISODate("2018-11-14T09:06:41Z"),
"optimeDurableDate" : ISODate("2018-11-14T09:06:41Z"),
"lastHeartbeat" : ISODate("2018-11-14T09:06:46.592Z"),
"lastHeartbeatRecv" : ISODate("2018-11-14T09:06:46.273Z"),
"pingMs" : NumberLong(0),
"electionTime" : Timestamp(1542179439, 1),
"electionDate" : ISODate("2018-11-14T07:10:39Z"),
"configVersion" : 7
},
{
"_id" : 1,
"name" : "10.10.99.102:23002",
"health" : 1,
"state" : 2,
"stateStr" : "SECONDARY",
"uptime" : 91513,
"optime" : {
"ts" : Timestamp(1542182801, 1),
"t" : NumberLong(6)
},
"optimeDate" : ISODate("2018-11-14T08:06:41Z"),
"syncingTo" : "10.10.99.102:23005",
"configVersion" : 7,
"self" : true
},
看一下实例是不是一个
rs.status() 方法的问题,
MongoDB复制集—复制集监控
8962 学习 · 9 问题
相似问题