Skip to content

Commit 819999e

Browse files
author
Sam Kleinman
committed
DOCS-2324: fsync lock recomendation in sharded cluster backup
1 parent fca2a11 commit 819999e

File tree

2 files changed

+24
-4
lines changed

2 files changed

+24
-4
lines changed

source/includes/steps-backup-sharded-cluster-with-snapshots.yaml

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,21 @@ post: |
1515
For more information, see the
1616
:ref:`sharding-balancing-disable-temporarily` procedure.
1717
---
18-
title: Lock one secondary member of each replica set in each shard.
18+
title: If necessary, lock one secondary member of each replica set in each shard.
1919
stepnum: 2
2020
ref: lock
2121
content: |
22-
Lock one secondary member of each replica set in each shard so that your
22+
If your :program:`mongod` does not have journaling enabled *or* your
23+
journal and data files are on different volumes, you **must** lock
24+
your :program:`mongod` before capturing a back up.
25+
26+
If your :program:`mongod` has journaling enabled and your journal
27+
and data files are on the same volume, you may skip this step.
28+
29+
If you need to lock the :program:`monogd`, attempt to lock one
30+
secondary member of each replica set in each shard so that your
2331
backups reflect the state of your database at the nearest possible
24-
approximation of a single moment in time. Lock these :program:`mongod`
25-
instances in as short of an interval as possible.
32+
approximation of a single moment in time.
2633
2734
To lock a secondary, connect through the :program:`mongo` shell to the
2835
secondary member's :program:`mongod` instance and issue the
@@ -69,6 +76,9 @@ title: Unlock locked replica set members.
6976
stepnum: 5
7077
ref: unlock
7178
content: |
79+
If you locked any :program:`mongod` instances to capture the backup,
80+
unlock them now.
81+
7282
Unlock all locked replica set members of each shard using the
7383
:method:`db.fsyncUnlock()` method in the :program:`mongo` shell.
7484
---

source/tutorial/backup-sharded-cluster-with-filesystem-snapshots.txt

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,16 @@ of the backup while minimizing impact on the cluster by taking the
5050
backup from a secondary member of the replica set that provides each
5151
shard.
5252

53+
Consistency
54+
~~~~~~~~~~~
55+
56+
If the journal and data files are on the same logical volume, you can
57+
use a single point-in-time snapshot to capture a valid copy of the data.
58+
59+
If the journal and data files are on different file systems, you must
60+
use :method:`db.fsyncLock()` and :method:`db.fsyncUnLock()` to capture
61+
a valid copy of your data.
62+
5363
Procedure
5464
---------
5565

0 commit comments

Comments
 (0)