Skip to content

Commit 96afe7c

Browse files
author
Bob Grabar
committed
DOCS-156 edits to overview page
1 parent ef6de2f commit 96afe7c

File tree

2 files changed

+60
-107
lines changed

2 files changed

+60
-107
lines changed

source/administration/backups.txt

Lines changed: 58 additions & 105 deletions
Original file line numberDiff line numberDiff line change
@@ -1,126 +1,78 @@
1-
=================================
2-
Backup and Restoration Strategies
3-
=================================
1+
=================
2+
Backup Strategies
3+
=================
44

55
.. default-domain:: mongodb
66

7-
This document describes database backup strategies for
8-
use with MongoDB. This document contains the following sections:
9-
10-
- :ref:`backup-overview` and :ref:`backup-considerations` describe the
11-
approaches for backing up your MongoDB environment.
12-
13-
- :ref:`sharded-cluster-backups` describes considerations specific to
14-
:term:`sharded clusters <sharded cluster>`.
15-
16-
- :ref:`replica-set-backups` describes considerations
17-
specific to :term:`replica sets <replica set>`.
18-
19-
See also:
20-
21-
- :doc:`/tutorial/backup-databases-with-filesystem-snapshots`
22-
23-
- :doc:`/tutorial/backup-databases-with-binary-database-dumps`
24-
25-
.. _backup-overview:
26-
27-
Backup Strategies
28-
-----------------
29-
30-
For MongoDB production systems, you should implement a strategy
31-
for taking and restoring backups. The goal of a backup strategy is to
32-
produce a full and consistent copy of the data to use to
33-
bring up a new or replacement database instance. In some
34-
cases, taking backups is difficult or impossible, given large data
35-
volumes, distributed architectures, and data transmission speeds.
7+
You should have an automated backup system for your MongoDB environment.
8+
The backup system must capture data in a consistent and usable state and
9+
in a way that can be reliably reproduced. The backup system must be
10+
automated and run regularly. And the system must be regularly tested in
11+
practical situations to ensure that your backups are functional. If you
12+
cannot effectively restore your database from the backup, then your
13+
backups are useless. You also should automate tests of backup
14+
restoration.
3615

37-
Nevertheless, with MongoDB, there are two major approaches to backups:
38-
[#replication-as-backups]_
16+
Use one of the following tools for backing up your MongoDB
17+
environment:
3918

40-
- Using system-level tools, like disk image snapshots.
19+
- Use system-level tools that perform block-level backups (also called
20+
disk-image snapshots).
4121

4222
See :doc:`/tutorial/backup-databases-with-filesystem-snapshots`.
4323

44-
- Using various capacities present in the :program:`mongodump` tool.
24+
- Use the :program:`mongodump` tool.
4525

4626
See :doc:`/tutorial/backup-databases-with-binary-database-dumps`.
4727

48-
The methods described in this document operate by copying the data file
49-
on the disk level. If your system does not provide functionality for
50-
this kind of backup, see :doc:`/tutorial/backup-databases-with-binary-database-dumps`.
51-
52-
Ensuring that the state captured by the backup is consistent and usable
53-
is the primary challenge of producing backups of database systems.
54-
Backups that you cannot produce reliably, or restore from feasibly are
55-
worthless.
56-
57-
As you develop your backup system, take into consideration the specific
58-
features of your deployment, your use patterns, and your architecture.
59-
60-
Because every environment is unique it's important to regularly test the
61-
backups that you capture to ensure that your backup system is
62-
practically, and not just theoretically, functional.
63-
64-
.. [#replication-as-backups] In many situations increasing the amount
65-
of replication provides useful assurances with data sets that are
66-
difficult to restore in a timely manner.
28+
In some cases, taking backups is difficult or impossible because of
29+
large data volumes, distributed architectures, and data transmission
30+
speeds. In these situations, increase the amount of replication.
6731

6832
.. _backup-considerations:
6933

70-
Production Considerations for Backup Strategies
71-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
34+
Backup Considerations
35+
---------------------
7236

73-
When evaluating a backup strategy for your MongoDB deployment consider
37+
As you develop a backup strategy for your MongoDB deployment consider
7438
the following factors:
7539

7640
- Geography. Ensure that you move some backups away from the your
77-
primary database infrastructure. It's important to be able to
78-
restore your database if you lose access to a system or site.
41+
primary database infrastructure.
7942

8043
- System errors. Ensure that your backups can survive situations where
8144
hardware failures or disk errors impact the integrity or
8245
availability of your backups.
8346

84-
- Production constraints. Backup operations themselves sometimes
85-
require substantial system resources. It's important to consider the
86-
time of the backup schedule relative to peak usage and maintenance
87-
windows.
47+
- Production constraints. Backup operations themselves sometimes require
48+
substantial system resources. It is important to consider the time of
49+
the backup schedule relative to peak usage and maintenance windows.
8850

89-
- System capabilities. Some of the block-level
90-
snapshot tools requires special support on the operating-system or
91-
infrastructure level.
51+
- System capabilities. Some of the block-level snapshot tools requires
52+
special support on the operating-system or infrastructure level.
9253

9354
- Database configuration. :term:`Replication` and :term:`sharding
94-
<shard>` can affect the process, and impact of the backup implementation.
55+
<shard>` can affect the process and impact of the backup
56+
implementation. See :ref:`sharded-cluster-backups` and
57+
:ref:`replica-set-backups`.
9558

9659
- Actual requirements. You may be able to save time, effort, and space
9760
by including only crucial data in the most frequent backups and
9861
backing up less crucial data less frequently.
9962

100-
With this information in hand you can begin to develop a backup plan
101-
for your database. Remember that all backup plans must be:
102-
103-
- Tested. If you cannot effectively restore your database from the
104-
backup, then your backups are useless. Test backup restoration
105-
regularly in practical situations to ensure that your backup system
106-
provides value.
107-
108-
- Automated. Database backups need to run regularly and
109-
automatically. Also automate tests of backup restoration.
110-
11163
.. _sharded-cluster-backups:
11264

11365
Sharded Cluster Backup Considerations
114-
-------------------------------------
66+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
11567

11668
.. include:: /includes/note-shard-cluster-backup.rst
11769

118-
:term:`Sharded clusters <sharded cluster>` complicate backup operations, as distributed
119-
systems. True point-in-time backups are only possible when stopping all write
120-
activity from the application. To create a precise moment-in-time
121-
snapshot of a cluster, stop all application write activity to the
122-
database, capture a backup, and only allow write operations to the
123-
database after the backup is complete.
70+
:term:`Sharded clusters <sharded cluster>` complicate backup operations,
71+
as distributed systems. True point-in-time backups are only possible
72+
when stopping all write activity from the application. To create a
73+
precise moment-in-time snapshot of a cluster, stop all application write
74+
activity to the database, capture a backup, and allow only write
75+
operations to the database after the backup is complete.
12476

12577
However, you can capture a backup of a cluster that **approximates** a
12678
point-in-time backup by capturing a backup from a secondary member of
@@ -129,7 +81,7 @@ same moment. If you decide to use an approximate-point-in-time backup
12981
method, ensure that your application can operate using a copy of the
13082
data that does not reflect a single moment in time.
13183

132-
The following documents describe all sharded cluster related backup
84+
The following documents describe sharded cluster related backup
13385
procedures:
13486

13587
- :doc:`/tutorial/backup-small-sharded-cluster-with-mongodump`
@@ -142,23 +94,24 @@ procedures:
14294
.. _replica-set-backups:
14395

14496
Replica Set Backup Considerations
145-
---------------------------------
97+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
14698

14799
In most cases, backing up data stored in a :term:`replica set` is
148-
similar to backing up data stored in a single instance. It's possible to
149-
lock a single :term:`secondary` or :term:`slave` database and then
150-
on create a backup from that instance. When you unlock the database, the secondary or
151-
slave will catch up with the :term:`primary` or :term:`master`. You may also
152-
chose to deploy a dedicated :term:`hidden member` for backup purposes.
153-
154-
If you have a :term:`sharded cluster` where each :term:`shard` is itself a replica
155-
set, you can use this method to create a backup of the entire cluster
156-
without disrupting the operation of the node. In these situations you
157-
should still turn off the balancer when you create backups.
158-
159-
For any cluster, using a non-primary/non-master node to create backups is
160-
particularly advantageous in that the backup operation does not
161-
affect the performance of the primary or master. Replication
162-
itself provides some measure of redundancy. Nevertheless, keeping
163-
point-in time backups of your cluster to provide for disaster recovery
164-
and as an additional layer of protection is crucial.
100+
similar to backing up data stored in a single instance. It is possible
101+
to lock a single :term:`secondary` database and then create a backup
102+
from that instance. When you unlock the database, the secondary will
103+
catch up with the :term:`primary`. You may also choose to deploy a
104+
dedicated :term:`hidden member` for backup purposes.
105+
106+
If you have a :term:`sharded cluster` where each :term:`shard` is itself
107+
a replica set, you can use this method to create a backup of the entire
108+
cluster without disrupting the operation of the node. In these
109+
situations you should still turn off the balancer when you create
110+
backups.
111+
112+
For any cluster, using a non-primary node to create backups is
113+
particularly advantageous in that the backup operation does not affect
114+
the performance of the primary. Replication itself provides some measure
115+
of redundancy. Nevertheless, keeping point-in time backups of your
116+
cluster to provide for disaster recovery and as an additional layer of
117+
protection is crucial.

source/administration/production-notes.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ especially in production.
1313
Backups
1414
-------
1515

16-
To make backups of your MongoDB database, please refer to the
17-
:ref:`backups section <backup-overview>`.
16+
To make backups of your MongoDB database, please refer to
17+
:doc:`/administration/backups`.
1818

1919
Networking
2020
----------

0 commit comments

Comments
 (0)