Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 11 additions & 7 deletions source/tutorial/deploy-replica-set.txt
Original file line number Diff line number Diff line change
Expand Up @@ -79,16 +79,20 @@ The examples in this procedure create a new replica set named ``rs0``.

.. code-block:: sh

mongod --port 27017 --dbpath /srv/mongodb/rs0-0 --replSet rs0
mongod --port 27018 --dbpath /srv/mongodb/rs0-1 --replSet rs0
mongod --port 27019 --dbpath /srv/mongodb/rs0-2 --replSet rs0
mongod --port 27017 --dbpath /srv/mongodb/rs0-0 --replSet rs0 --smallfiles --oplogSize 128
mongod --port 27018 --dbpath /srv/mongodb/rs0-1 --replSet rs0 --smallfiles --oplogSize 128
mongod --port 27019 --dbpath /srv/mongodb/rs0-2 --replSet rs0 --smallfiles --oplogSize 128

This starts each instance as a member of a replica set named
``rs0``, each running on a distinct port. If you are already using
these ports, you can select different ports. See the documentation
of the following options for more information: :option:`--port
<mongod --port>`, :option:`--dbpath <mongod --dbpath>`, and
:option:`--replSet <mongod --replSet>`.
these ports, select different ports.

The :setting:`smallfiles` and :setting:`oplogSize`
options are used for testing, not for production, and
reduce the disk space that each
:program:`mongod` uses. For more information on these and other
configuration options, see
:doc:`/reference/configuration-options`.

#. Open a :program:`mongo` shell and connect to the first
:program:`mongod` instance, with the following command:
Expand Down