|
When loading the existing config it is updated to have "configsvr:true" in addition to the stored values. This causes the node to not error when starting like would happen if the replica set was sent a non-configsvr config during initiation or on a reconfig.
> rs.conf() // In memory config, after loading
|
{
|
"_id" : "test",
|
"version" : 3,
|
"configsvr" : true,
|
"protocolVersion" : NumberLong(1),
|
"members" : [
|
{
|
"_id" : 0,
|
"host" : "alias:7788",
|
"arbiterOnly" : false,
|
"buildIndexes" : true,
|
"hidden" : false,
|
"priority" : 1,
|
"tags" : {
|
|
},
|
"slaveDelay" : NumberLong(0),
|
"votes" : 1
|
}
|
],
|
"settings" : {
|
"chainingAllowed" : true,
|
"heartbeatIntervalMillis" : 2000,
|
"heartbeatTimeoutSecs" : 10,
|
"electionTimeoutMillis" : 5000,
|
"getLastErrorModes" : {
|
|
},
|
"getLastErrorDefaults" : {
|
"w" : 1,
|
"wtimeout" : 0
|
}
|
}
|
}
|
> db.getSiblingDB("local").system.replset.findOne() // actual stored config
|
{
|
"_id" : "test",
|
"version" : 3,
|
"protocolVersion" : NumberLong(1),
|
"members" : [
|
{
|
"_id" : 0,
|
"host" : "alias:7788",
|
"arbiterOnly" : false,
|
"buildIndexes" : true,
|
"hidden" : false,
|
"priority" : 1,
|
"tags" : {
|
|
},
|
"slaveDelay" : NumberLong(0),
|
"votes" : 1
|
}
|
],
|
"settings" : {
|
"chainingAllowed" : true,
|
"heartbeatIntervalMillis" : 2000,
|
"heartbeatTimeoutSecs" : 10,
|
"electionTimeoutMillis" : 5000,
|
"getLastErrorModes" : {
|
|
},
|
"getLastErrorDefaults" : {
|
"w" : 1,
|
"wtimeout" : 0
|
}
|
}
|
}
|
|
|