Quantcast
Channel: StackExchange Replication Questions
Viewing all articles
Browse latest Browse all 17268

mongodb could not find host matching read preference { mode: \"primary\" } for set?

$
0
0

I am deploy a monodb sharding, I have deploy a replica set in three machines:

dev41:27017,dev42:27017,dev193:27017

and configsvr in three machine:

dev41:27019,dev42:27019,dev193:27019

and also a mongos in machine:

dev41:28000

at last I try to add my replica into mongos:

mongo dev41:28000/admin
sh.addShard('rs0/dev41,dev42,dev193')

then I got errors:

{
    "ok" : 0,
    "errmsg" : "could not find host matching read preference { mode: \"primary\" } for set rs0",
    "code" : 133
}

Viewing all articles
Browse latest Browse all 17268

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>