[SERVER-16157] bind_ip = 127.0.0.1 && rs.initiate(): error 93 "No host described in new configuration 1 for replica set indexers maps to this node" Created: 14/Nov/14 Updated: 18/Feb/17 Resolved: 14/Nov/14 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Replication |
| Affects Version/s: | 2.8.0-rc0 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Thomas Riccardi | Assignee: | Andy Schwerin |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Operating System: | ALL | |||||||||||||||||||||||||
| Steps To Reproduce: | config file:
Start mongod with config file, then mongo shell:
|
|||||||||||||||||||||||||
| Participants: |
| Description |
|
With "bind_ip = 127.0.0.1" config, it's no more possible to create a replica set in mongodb 2.8.0-rc0:
It worked with mongodb 2.6.4 (and 2.4 & 2.2 & 2.0 I think). |
| Comments |
| Comment by Nikhil Kumar Gupta [ 18/Feb/17 ] |
|
I see similar error message in 3.4.1 Later I realize this occurred due to below reason. Thanks, Nikhil |
| Comment by Andy Schwerin [ 17/Nov/14 ] |
|
I don't recommend calling rs.initiate() with no parameters for anything other than testing / playing around with replica sets. It's always surprising to learn what name a mongod node gives itself if you let it. |
| Comment by Thomas Riccardi [ 17/Nov/14 ] |
|
KO so this means the standard 'rs.initiate()' command doesn't work anymore for local only replica-sets, since it defaults to the public hostname, not the local one ('localhost'). We could change the rs.initiate() behavior in case of bind_ip local only to fix the initial scenario, but it would confuse more than the current situation I think. Lastly, I did have MYHOST in the /etc/hosts, but bound to 127.0.1.1, not 127.0.0.1 (that's how debian and ubuntu do, it seems), so indeed mongod didn't listen on 127.0.1.1:2707, this explains why i didn't work. I confirm that my initial scenario works when I add MYHOST to /etc/hosts on 127.0.0.1 before rs.initiate(). It also works if instead I configure mongod with "bind_ip=127.0.0.1,127.0.1.1" before rs.initiate(). |
| Comment by Andy Schwerin [ 14/Nov/14 ] |
|
It was an error that this worked in prior versions of MongoDB, that was fixed as a side-effect of |