I have a standalone Mongo instance that has a set of replicas installed. However, it seems that I cannot connect and run any requests in the Mongo shell. I get the following:
error: { "$err" : "not master and slaveOk=false", "code" : 13435 }
I install SlaveOk as follows:
db.getMongo().setSlaveOk()
.. but I still get the error message:
error: { "$err" : "not master or secondary; cannot currently read from this replSet member", "code" : 13436 }
I cannot find a direct answer on Google: how do I connect to my replica installed using the mongo shell?
mongodb
James
source share