Skip to content

Instantly share code, notes, and snippets.

@martin-cowie
Last active May 17, 2016 13:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save martin-cowie/9ab5fa34b9729ba0e77c421122df32ba to your computer and use it in GitHub Desktop.
Save martin-cowie/9ab5fa34b9729ba0e77c421122df32ba to your computer and use it in GitHub Desktop.
Building and starting a MongoDB replication set in the fore.
% mongo --nodb
MongoDB shell version: 3.2.6
> replicaSet = new ReplSetTest({"nodes" : 1, "nodeOptions": {"dbpath": "/tmp/mongodb"} });
> replicaSet.startSet()
> replicaSet.initiate();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment