Skip to content

DOCS-324 convert standalone to rs #242

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Sep 18, 2012
Merged
Show file tree
Hide file tree
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
6 changes: 3 additions & 3 deletions source/reference/command/logRotate.txt
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ logRotate
.. note::

.. versionadded:: 2.0.3
The :dbcommand:`logRotate` command is available to
:program:`mongod` instances running on Windows systems with
MongoDB release 2.0.3 and higher.
The :dbcommand:`logRotate` command is available to
:program:`mongod` instances running on Windows systems with
MongoDB release 2.0.3 and higher.

.. :error:`16175` is thrown if logRotate fails
2 changes: 1 addition & 1 deletion source/reference/configuration-options.txt
Original file line number Diff line number Diff line change
Expand Up @@ -727,7 +727,7 @@ Sharding Cluster Options

*Default:* false

When set to ``true``, :setting:``noMoveParanoia` disables a
When set to ``true``, :setting:`noMoveParanoia` disables a
"paranoid mode" for data writes for chunk migration operation. See
the :ref:`chunk migration <sharding-chunk-migration>` and
:dbcommand:`moveChunk` command documentation for more information.
Expand Down
2 changes: 1 addition & 1 deletion source/replication.txt
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,10 @@ operations in detail:
:maxdepth: 1

tutorial/deploy-replica-set
tutorial/convert-standalone-to-replica-set
tutorial/expand-replica-set
tutorial/deploy-geographically-distributed-replica-set
tutorial/change-oplog-size
tutorial/convert-replica-set-to-replicated-shard-cluster
tutorial/change-hostnames-in-a-replica-set
tutorial/convert-secondary-into-arbiter

Expand Down
1 change: 1 addition & 0 deletions source/sharding.txt
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ The following tutorials describe specific sharding procedures:
tutorial/add-shards-to-shard-cluster
tutorial/remove-shards-from-cluster
tutorial/enforce-unique-keys-for-sharded-collections
tutorial/convert-replica-set-to-replicated-shard-cluster

.. _sharding-reference:

Expand Down
64 changes: 64 additions & 0 deletions source/tutorial/convert-standalone-to-replica-set.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
=========================================
Deploy a Replica Set From a Single Server
=========================================

.. default-domain:: mongodb

This tutorial describes how to deploy a three-member :term:`replica set`
from a standalone instance of MongoDB.

To deploy a replica set from multiple existing instances of MongoDB, see
:doc:`/tutorial/deploy-replica-set`.

For background information on replica set deployments, see
:doc:`/core/replication` and
:doc:`/administration/replication-architectures`.

Procedure
---------

These procedures assume you have a standalone instance of MongoDB
installed. If you have not already installed MongoDB, see the
:ref:`installation tutorials <tutorials-installation>`.

1. Shut down the your MongoDB instance and then restart using
the :option:`--replSet <mongod --replset>` option and the name of the
:term:`replica set`, which is ``rs0`` in the example below.

To minimize downtime, consider pre-allocating new local data files by
using the :setting:`oplogSize` option. If you choose not to use this
option, the server allocate the new data files before starting back
up. This example does not use the :setting:`oplogSize` option.

Use a command similar to the following:

.. code-block:: sh

mongod --port 27017 --replSet rs0

This starts the instance as a member of a replica set named ``rs0``.
For more information on configuration options, see
:doc:`/reference/configuration-options`.

#. Open a :program:`mongo` shell and connect to the :program:`mongod`
instance. If you are running the command remotely, replace
"localhost" with the appropriate hostname. In a new shell session,
enter the following:

.. code-block:: sh

mongo localhost:27017

#. Use :method:`rs.initiate()` to initiate the replica set:

.. code-block:: javascript

rs.initiate()

The server is now operational as the :term:`primary` in a replica set
that consists of a single node. To display the replica configuration,
issue the :method:`rs.conf()` method. To check the status of the
replica set, issue :method:`rs.status()`.

#. The next step is to add members to the replica set. To do so, see
:doc:`/tutorial/expand-replica-set`.
15 changes: 10 additions & 5 deletions source/tutorial/deploy-replica-set.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,17 @@ Deploy a Replica Set

.. default-domain:: mongodb

This tutorial describes how to deploy a three member
:term:`replica set`, with specific instructions for development
and test systems and for production systems.
This tutorial describes how to create a three member
:term:`replica set` from three existing instances of MongoDB.
The tutorial provides one procedure for development and test systems and
a separate procedure for production systems.

.. seealso:: For appropriate background, see :doc:`/core/replication`
and :doc:`/administration/replication-architectures`.
To deploy a replica set from a single standalone MongoDB instance, see
:doc:`/tutorial/convert-standalone-to-replica-set`.

For background information on replica set deployments, see
:doc:`/core/replication` and
:doc:`/administration/replication-architectures`.

Overview
--------
Expand Down