Skip to content

DOCS-538 new step to verify connectivity before deploy rs #282

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
Oct 4, 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
44 changes: 44 additions & 0 deletions source/administration/replica-sets.txt
Original file line number Diff line number Diff line change
Expand Up @@ -656,6 +656,50 @@ Possible causes of replication lag include:
- The :ref:`replica-set-procedure-change-oplog-size` topic this document.
- The :doc:`/tutorial/change-oplog-size` tutorial.

.. _replica-set-troubleshooting-check-connection:

Test the Connection Between Each Member
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

There must be connectivity from every :term:`replica set` member to
every other member in order for replication to work. Problems with
network or firewall rules can prevent this connectivity and prevent
replication from working. Network topologies and firewalls might allow a
connection in one direction but not the other. Therefore you must make
sure to verify that the connection works in both directions.

To test the connection from every member to
every other member, in both directions, consider the following example:

.. example:: Given a replica set with three members running on three separate
hosts:

- ``m1.example.net``
- ``m2.example.net``
- ``m3.example.net``

1. Test the connection from ``m1.example.net`` to the other hosts by running
the following operations from ``m1.example.net``:

.. code-block:: sh

mongo --host m2.example.net --port 27017

mongo --host m3.example.net --port 27017

#. Test the connection from ``m2.example.net`` to the other two
hosts by running similar appropriate operations from ``m2.example.net``.

You have now tested the connection between
``m2.example.net`` and ``m1.example.net`` twice, but each time
from a different direction.

#. Test the connection from ``m3.example.net`` to the other two
hosts by running the operations from ``m3.example.net``.

If a connection in any direction fails, there's a networking or
firewall issue that needs to be diagnosed separately.

.. index:: pair: replica set; failover
.. _replica-set-failover-administration:
.. _failover:
Expand Down
16 changes: 14 additions & 2 deletions source/tutorial/deploy-replica-set.txt
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,13 @@ Deploy a Development or Testing Replica Set

The examples in this procedure create a new replica set named ``rs0``.

1. Start three instances of :program:`mongod` as members of a replica
1. Before creating your replica set, verify that every member can
successfully connect to every other member. The connection between
any two members must work in both directions. To test the connection
from each member to every other member, see
:ref:`replica-set-troubleshooting-check-connection`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"full connectivity" is not clear as such.


#. Start three instances of :program:`mongod` as members of a replica
set named ``rs0``, as described in this step. For ephemeral tests and
the purposes of this guide, you may run the :program:`mongod`
instances in separate windows of GNU Screen. OS X and most Linux
Expand Down Expand Up @@ -186,7 +192,13 @@ deployment described above, with the following differences:

To deploy a production replica set:

1. On each system start the :program:`mongod` process by issuing a
1. Before creating your replica set, verify that every member can
successfully connect to every other member. The connection between
any two members must work in both directions. To test the connection
from each member to every other member, see
:ref:`replica-set-troubleshooting-check-connection`.

#. On each system start the :program:`mongod` process by issuing a
command similar to following:

.. code-block:: sh
Expand Down