Skip to content

Commit 12b177e

Browse files
committed
edits to recovery document
1 parent add7042 commit 12b177e

File tree

1 file changed

+11
-9
lines changed

1 file changed

+11
-9
lines changed

aspiration/tutorial/recover-data-following-unexpected-shutdown.txt

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,13 @@ Recover MongoDB Data following Unexpected Shutdown
66

77
If MongoDB does not shutdown cleanly [#clean-shutdown]_ the on-disk
88
representation of the data files will likely reflect an inconsistent
9-
state which leads to data corruption.
9+
state which could lead to data corruption.
1010

1111
To prevent data inconsistency and corruption, always shut down the
1212
database cleanly, and use the :ref:`durability journaling
1313
<setting-journal>`. The journal writes data to disk every 100
14-
milliseconds by default, and ensurers that MongoDB will be able to
15-
recover a constant state even in the case of a unclean shutdown due to
14+
milliseconds by default, and ensures that MongoDB will be able to
15+
recover a constant state even in the case of an unclean shutdown due to
1616
power loss or other system failure.
1717

1818
If you do not have journaling enabled, use the following procedure to
@@ -34,7 +34,7 @@ Indications
3434
~~~~~~~~~~~
3535

3636
When you are aware of a :program:`mongod` instance running without
37-
journaling that stops unexpectedly you should always run the repair
37+
journaling that stops unexpectedly, you should always run the repair
3838
operation before starting MongoDB again.
3939

4040
If the ``mongod.lock`` file in the data directory specified by
@@ -57,7 +57,7 @@ contains the following line:
5757
old lock file: /data/db/mongod.lock. probably means unclean shutdown
5858

5959
You must remove the lockfile **and** run the repair operation before
60-
starting the database normally using the following procedure.
60+
starting the database normally using the following procedure:
6161

6262
Overview
6363
~~~~~~~~
@@ -149,12 +149,14 @@ the following procedure:
149149

150150
In normal operation, you should **never** remove the ``mongod.lock``
151151
file and start :program:`mongod`. Instead use one of the above methods
152-
to recover the database and remove the lock files. In dire you
153-
situations can remove the lockfile, and start the database using the
152+
to recover the database and remove the lock files. In dire
153+
situations you can remove the lockfile, and start the database using the
154154
possibly corrupt files, and attempt to recover data from the database;
155155
however, it's impossible to predict the state of the database in these
156156
situations.
157157

158158
If you are not running with journaling, and your database shuts down
159-
unexpectedly for *any* reason, you should always assume that your
160-
database is in an inconsistent and likely corrupt state.
159+
unexpectedly for *any* reason, you should always proceed *as if* your database
160+
is in an inconsistent and likely corrupt state. If at all possible restore
161+
from :doc:`backup </administration/backup>` or if running as a :term:`replica
162+
set` re-sync from an intact member of the set.

0 commit comments

Comments
 (0)