Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- mongod --port 27017 --dbpath data\db1 --replSet replicationSet
- mongod --port 27018 --dbpath data\db2 --replSet replicationSet
- mongod --port 27019 --dbpath data\db3 --replSet replicationSet
- mongod --port 27020 --dbpath data\db4 --replSet replicationSet
- mongod --port 27021 --dbpath data\db5 --replSet replicationSet
- mongo --host="127.0.0.1:27017"
- cfg = rs.conf()
- cfg.members[0].host = "127.0.0.1:27017"
- rs.reconfig(cfg)
- rs.add("127.0.0.1:27018")
- rs.add("127.0.0.1:27019")
- rs.add("127.0.0.1:27020")
- rs.add("127.0.0.1:27021")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement