Backup and Restore Sharded Clusters备份和恢复分片群集

The following tutorials describe backup and restoration for sharded clusters:以下教程介绍了分片群集的备份和恢复:

Tip

mongodump and mongorestore cannot be part of a backup strategy for 4.2+ sharded clusters that have sharded transactions in progress, as backups created with mongodump do not maintain the atomicity guarantees of transactions across shards.mongodumpmongorestore不能作为正在进行分片事务的4.2+分片群集的备份策略的一部分,因为使用mongodump创建的备份无法维持跨分片事务的原子性保证。

For 4.2+ sharded clusters with in-progress sharded transactions, use one of the following coordinated backup and restore processes which do maintain the atomicity guarantees of transactions across shards:对于具有进行中分片事务的4.2+分片群集,请使用以下协调的备份和恢复过程之一,这些过程确实维护了跨分片事务的原子性保证:

Back Up a Sharded Cluster with File System Snapshots使用文件系统快照备份分片群集
Use file system snapshots back up each component in the sharded cluster individually. 使用文件系统快照分别备份分片集群中的每个组件。The procedure involves stopping the cluster balancer. 该过程包括停止群集平衡器。If your system configuration allows file system backups, this might be more efficient than using MongoDB tools.如果您的系统配置允许文件系统备份,这可能比使用MongoDB工具更有效。
Back Up a Sharded Cluster with Database Dumps用数据库转储备份分片群集
Create backups using mongodump to back up each component in the cluster individually.使用mongodump创建备份,分别备份集群中的每个组件。
Schedule Backup Window for Sharded Clusters为分片群集安排备份窗口
Limit the operation of the cluster balancer to provide a window for regular backup operations.限制群集平衡器的操作,为常规备份操作提供一个窗口。
Restore a Sharded Cluster恢复分片群集
An outline of the procedure and consideration for restoring an entire sharded cluster from backup.概述从备份中恢复整个分片群集的过程和考虑事项。