Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8164175
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T19:15:32+00:00 2026-06-06T19:15:32+00:00

If so, how? When I first created the replica set, I chose a confusing

  • 0

If so, how?

When I first created the replica set, I chose a confusing name; I’d like to change it now.

The replica set name is mentioned in /etc/mongod.conf, and I’m not sure when it reads/rereads that. Since the replica set name can also be passed in as a command-line parameter, I’m assuming (and currently testing) the following:

  • it just uses replica set name once on startup while syncing up with other nodes
  • I have to reconfigure, stop, change replSet CLI argument or replSet value in /etc/mongod.conf, then restart

In other words, I’m assuming the answer to my original question is “no, you must restart” or “no, replica set name is immutable”. I’ll probably figure this out soon enough since I’m trying it locally.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T19:15:33+00:00Added an answer on June 6, 2026 at 7:15 pm

    Here’s how to do it with downtime:

    1. Stop all the servers
      • If authentication is enabled, make sure it is disabled or changes to the local.system.replset collection may not be authorized.
    2. Start up each server without the –replSet option, pointing at the correct data directory.
    3. Update the local.system.replset doc on each server with the new replica set name. You have to change every server here.
      Here is how to update local.system.replset in mongo shell:

      use local  
      var doc = db.system.replset.findOne()  
      doc._id = 'NewReplicaSetName'
      db.system.replset.save(doc)  
      db.system.replset.remove({_id:'OldReplicaSetName'})
      
    4. Shut them down again.
    5. Change the /etc/mongod.conf replSet option to the new name on all the servers.
    6. Start them all up with the original options.
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

First,I created a hidden frame like this: var oHiddenFrame = null; if(oHiddenFrame == null){
I created first my TestViewController.h and *.m. Afterwards my TestView.xib. Now I need to
I have a set of Styles that were first created inside the style attribute
I want to reset my sql server 2008 database like when it's first created.
I first created a Type and then created a Table and then inserted 1
My colleague created a repository in Bitbucket. I first created a folder in my
I have a question. I first created an object which extends NSObject, I provided
I have two model classes, say parent and child. Parents are created first, and
I created my first WCF service and tested it on my computer, and it
I've created my first (BIG) LayoutControl and I'm puzzled by it's mouse wheel scroll

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.