Restore Swarm


  • You must use the same IP as the node from which you made the backup. The command to force the new cluster does not reset the IP in the Swarm data.

  • You must restore the backup on the same Mirantis Container Runtime version.

  • You can locate the list of manager IP addresses in state.json in the zip file.

  • If auto-lock was enabled on the old Swarm, you will need the unlock key to perform the restore.

Perform Swarm restore


Perform the Swarm restore procedure only on the cluster’s one manager node. Be sure, also, to restore the backup on the same node upon which the original backup was made.

  1. Shut down the Mirantis Container Runtime on the node you select for the restore:

    systemctl stop docker
  2. Remove the contents of the /var/lib/docker/swarm directory on the new Swarm, if it exists.

  3. Restore the /var/lib/docker/swarm directory with the contents of the backup.


    The new node uses the same encryption key for on-disk storage as the old one. Currently, it is not possible to change the on-disk storage encryption keys. For a swarm that has auto-lock enabled, the unlock key is the same as on the old swarm and is required to restore the swarm.

  4. Start Docker on the new node. Unlock the swarm, if necessary.

    systemctl start docker
  5. Verify that the state of the swarm is as expected. This can include application-specific tests, or simply checking the output of docker service ls to confirm that all expected services are present.

  6. If you use auto-lock, rotate the unlock key.

  7. Add the manager and worker nodes to the new swarm.

  8. Reinstate your previous backup regimen on the new swarm.

Refer to the Docker documentation, Administer and maintain a swarm of Docker Engines for more information.

See also