[SERVER-3610] addShard fails with arbiter in replica set Created: 16/Aug/11  Updated: 16/Nov/21  Resolved: 17/Aug/11

Status: Closed
Project: Core Server
Component/s: Replication, Sharding
Affects Version/s: 1.8.2
Fix Version/s: 1.9.2

Type: Bug Priority: Major - P3
Reporter: Raviv Pavel Assignee: Eliot Horowitz (Inactive)
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Operating System: ALL
Participants:

 Description   

Calling addShard fails when the shard has an arbiter.

rs1:PRIMARY> rs.status()
{
"set" : "rs1",
"date" : ISODate("2011-08-16T11:14:17Z"),
"myState" : 1,
"members" : [
{
"_id" : 0,
"name" : "192.168.10.114:27017",
"health" : 1,
"state" : 2,
"stateStr" : "SECONDARY",
"uptime" : 80051,
"optime" :

{ "t" : 1313056200000, "i" : 1 }

,
"optimeDate" :
ISODate("2011-08-11T09:50:00Z"),
"lastHeartbeat" :
ISODate("2011-08-16T11:14:17Z")
},
{
"_id" : 1,
"name" : "192.168.10.114:27018",
"health" : 1,
"state" : 1,
"stateStr" : "PRIMARY",
"optime" :

{ "t" : 1313056200000, "i" : 1 }

,
"optimeDate" :
ISODate("2011-08-11T09:50:00Z"),
"self" : true
},
{
"_id" : 2,
"name" : "192.168.10.114:27019",
"health" : 1,
"state" : 7,
"stateStr" : "ARBITER",
"uptime" : 79859,
"optime" :

{ "t" : 0, "i" : 0 }

,
"optimeDate" :
ISODate("1970-01-01T00:00:00Z"),
"lastHeartbeat" :
ISODate("2011-08-16T11:14:17Z")
}
],
"ok" : 1
}
> db.runCommand(

{ addshard : "rs1/192.168.10.114:27017,192.168.10.114:27018,192.168.10.114:27019" }

);

{
"ok" : 0,
"errmsg" : "host 192.168.10.114:27019 does not belong to
replica set as a non-passive memberrs1"
}



 Comments   
Comment by auto [ 17/Aug/11 ]

Author:

{u'login': u'erh', u'name': u'Eliot Horowitz', u'email': u'eliot@10gen.com'}

Message: test for SERVER-3610
Branch: master
https://github.com/mongodb/mongo/commit/328ca2cdef89c55bc06180769618fff275fbd503

Generated at Thu Feb 08 03:03:31 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.