NoMatchingDocument: Did not find replica set configuration document in local.system.replset


I have a standalone MongoDB instance in my AWS EC2 instance. I’m planning to shift it to Mongo Atlas. The prerequisite is to convert the MongoDB instance into a replica set.

Below is the code for my mongo.conf file:

I’m using the below command to create the replica set:

I’m getting the below error:

What else should I change in my mongo.conf file?


I had same issue but I resolved following below steps :

I am on Windows server . Mongo DB shell version 3.0.4 . Error in below screen shot same as you mentioned

enter image description here

So I connect to Mongo shell switch to local .

Use following command. Please note SIR is my replica set name


enter image description here

Leave a Reply