mongodb创建副本集命令

mongodb创建副本集命令

 

./mongod --replSet spock --dbpath ../data --smallfiles

 

> config ={
... "_id":"spock",
... "members":[
... {"_id":0,"host":"192.168.100.25:27017"},
... {"_id":1,"host":"192.168.100.30:27017"},
... {"_id":2,"host":"192.168.100.37:27017"}
... ]
... }

你可能感兴趣的:(mongodb)