Quantcast
Channel: StackExchange Replication Questions
Viewing all articles
Browse latest Browse all 17268

MongoDB replicaset config info differs among replica members

$
0
0

I have a replicaset running in MongoDB3.0. I did some changes to the replicaset configuration a period after the initial setup. For some reason, I have different replicaset config information in different members.

  1. Arbiter server:

    {
        "_id" : "rs0",
        "version" : 98161,
        "members" : [
            {
                    "_id" : 0,
                    "host" : "SEVER1:27017",
                    "arbiterOnly" : false,
                    "buildIndexes" : true,
                    "hidden" : false,
                    "priority" : 1,
                    "tags" : {
    
                    },
                    "slaveDelay" : 0,
                    "votes" : 1
            },
            {
                    "_id" : 2,
                    "host" : "SERVER1:27015",
                    "arbiterOnly" : false,
                    "buildIndexes" : true,
                    "hidden" : false,
                    "priority" : 0,
                    "tags" : {
    
                    },
                    "slaveDelay" : 0,
                    "votes" : 1
            },
            {
                    "_id" : 3,
                    "host" : "SERVER1:27016",
                    "arbiterOnly" : false,
                    "buildIndexes" : true,
                    "hidden" : false,
                    "priority" : 1,
                    "tags" : {
    
                    },
                    "slaveDelay" : 0,
                    "votes" : 1
            }
        ],
        "settings" : {
            "chainingAllowed" : true,
            "heartbeatTimeoutSecs" : 10,
            "getLastErrorModes" : {
    
            },
            "getLastErrorDefaults" : {
                    "w" : 1,
                    "wtimeout" : 0
            }
        }
    }
    
  2. Primary Server:

    {
        "_id" : "rs0",
        "version" : 45994,
        "members" : [
            {
                    "_id" : 0,
                    "host" : "SERVER1:27017",
                    "arbiterOnly" : false,
                    "buildIndexes" : true,
                    "hidden" : false,
                    "priority" : 1,
                    "tags" : {
    
                    },
                    "slaveDelay" : 0,
                    "votes" : 1
            },
            {
                    "_id" : 3,
                    "host" : "SERVER2:27017",
                    "arbiterOnly" : false,
                    "buildIndexes" : true,
                    "hidden" : false,
                    "priority" : 0,
                    "tags" : {
    
                    },
                    "slaveDelay" : 0,
                    "votes" : 1
            },
            {
                    "_id" : 4,
                    "host" : "SERVER3:27017",
                    "arbiterOnly" : true,
                    "buildIndexes" : true,
                    "hidden" : false,
                    "priority" : 1,
                    "tags" : {
    
                    },
                    "slaveDelay" : 0,
                    "votes" : 1
            }
    ],
    "settings" : {
            "chainingAllowed" : true,
            "heartbeatTimeoutSecs" : 10,
            "getLastErrorModes" : {
    
            },
            "getLastErrorDefaults" : {
                    "w" : 1,
                    "wtimeout" : 0
            }
        }
    }
    

The primary server configuration is correctly configured with members from three different servers. However, the arbiter server has a wrong configuration with members from same host but different port (old initial setup). How could I force the correct configuration from primary to the arbiter server?

I have tried so far:

  1. rs.reconfig() with/without {force:true}
  2. rs.remove()/rs.add/rs.addAbt() etc.
  3. Manually edit the conf() object to contain a correct list of members and run reconfig, but only end up with same old wrong config.

Any advice would be appreciated.


Viewing all articles
Browse latest Browse all 17268

Trending Articles