How to safely change port numbers for a shard mongodb cluster (2.0.1)

150 views
Skip to first unread message

ZephW

unread,
Nov 1, 2011, 11:42:33 PM11/1/11
to mongod...@googlegroups.com
I'd like to change the port number used by mongoc and mongos. What I'd like to make sure is simply restarting mongoc, mongod, and mongos instances
will achieve my goal. I know changing port number used by mongod is more of a trouble as the cluster is sharded and I have to reconfig each and every
replica for each shard.

Could someone in the mongodb team tell me if I can safely proceed? Thank you.

Bernie Hackett

unread,
Nov 4, 2011, 5:16:34 PM11/4/11
to mongodb-user
Changing the port of mongos is easy enough, you just have to update
your application to connect to mongos at the new port. To change the
port number of a config server you have to follow the steps here:

http://www.mongodb.org/display/DOCS/Changing+Config+Servers#ChangingConfigServers-Renamingaconfigserverdifferenthostname

ZephW

unread,
Nov 5, 2011, 6:37:30 AM11/5/11
to mongod...@googlegroups.com
Thank you, Bernie :)
Reply all
Reply to author
Forward
0 new messages