-
Type: Improvement
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: None
-
Component/s: Networking, Replication
-
Fully Compatible
-
Platforms 2017-10-23
Currently if you run replSetInitiate without providing an initial config, mongod will attempt to deduce its hostname by inspecting the available network interfaces, and then will generate a default configuration with itself as the only member, addressed by the hostname it discovered. Now that mongods bind only to localhost by default (SERVER-28229), this breaks the bootstrapping technique that is common for setting up initial deployments, since running replSetInitiate with no config will default to a hostname based config, but then be unable to find itself in the config since it only accepts connections over localhost. Instead of trying to guess the host machine's hostname we should just generate the default config using localhost.
- causes
-
SERVER-31808 HostAndPort for replSetInitiate() no longer finds hostname for localhost
- Closed
- is related to
-
SERVER-31454 rs.initiate() does not load default configuration as expected
- Closed