Search code examples
dockerbackupdocker-swarm-mode

Backup Docker Swarm - How many Manager Nodes Required


From the official docker doc, there is a statement (as below) looks confusing to me. From my understanding, don't we only need to pick anyone of healthy manager nodes to backup for future restoration purpose?

"You must perform a manual backup on each manager node, because logs contain node IP address information and are not transferable to other nodes. If you do not backup the raft logs, you cannot verify workloads or Swarm resource provisioning after restoring the cluster."

Link: https://docs.docker.com/ee/admin/backup/back-up-swarm/


Solution

  • It depends on how you want to recover. If you want to restore a specific node, you need a backup from that node.

    If you are rebuilding your swarm cluster from an old backup, then you only need one healthy node's backup. See the following guide for performing a backup and restore:

    https://docs.docker.com/engine/swarm/admin_guide/#back-up-the-swarm

    If you restore the cluster from a single node, you will need to reset and join the swarm again on the other managers since you are running a single node cluster. What is restored in that scenario are the services, stacks, and other definitions, but not the nodes.