Use the viocli recover command to recover nodes or groups of nodes.

Because most OpenStack nodes are stateless, you can recover them without a backup file. However, a backup file is necessary to recover OpenStack database nodes or Swift nodes.

The viocli recover command uses the following syntax.

viocli recover [-d NAME] {-n NODE1... | -r ROLE1... [-n NODE1...]} [-dn BACKUP] [-nfs NFS-VOLUME] [--verbose]
Parameter Mandatory or Optional Description

-d NAME or --deployment NAME

Optional

Name of the deployment to use.

If you do not enter a value, the default deployment is used.

-n, --node NODE

Mandatory unless -r is used.

Recovers one or more nodes. You can specify multiple nodes separated with commas.

To display the nodes in your deployment, use the viocli show command. The values shown in the VM Name column can be used as arguments for this command.

For example, the following command recovers two nodes from the specified NFS backup file.

viocli recover –n VIO-DB-0 VIO-DB-1 –dn vio_os_db_20150830215406 -nfs 10.146.29.123:/backups

-r ROLE or --role ROLE

Mandatory unless -n is used.

Recovers all nodes assigned to the specified role. You can specify multiple roles separated with commas. You can also specify -n or --node in the same command to recover additional nodes that are not assigned to that role.

To display the nodes in your deployment, use the viocli show command. The values shown in the Role column can be used as arguments for this command.

Note: Swift nodes cannot be recovered by role.

For example, the following command recovers the nodes assigned to the DB role from the specified NFS backup file.

viocli recover -r DB -dn vio_os_db_20150830215406 -nfs 10.146.29.123:/backups

-dn BACKUP or --dir-name BACKUP

Mandatory for Swift node or full OpenStack database recovery

Folder containing the OpenStack database or Swift ring backup files.

  • OpenStack database backup folders are in vio_os_db_yyyymmddhhmmss format.
  • Swift ring backup folders are in vio_swift_ring_yyyymmddhhmmss format.

This parameter is mandatory when recovering the following items:

  • For an HA deployment: the DB role or all three database nodes (VIO-DB-0, VIO-DB-1, and VIO-DB-2)
  • For a compact or tiny deployment: the ControlPlane role or the VIO-ControlPlane-0 node
  • Swift nodes

-nfs NFS-VOLUME

Mandatory for Swift node or full OpenStack database recovery

Name or IP address of the target NFS volume and directory in the format remote-host:/remote-dir.

For example: 192.168.1.77:/backups

This parameter is mandatory when recovering the following items:

  • For an HA deployment: the DB role or all three database nodes (VIO-DB-0, VIO-DB-1, and VIO-DB-2)
  • For a compact or tiny deployment: the ControlPlane role or the VIO-ControlPlane-0 node
  • Swift nodes

--verbose

Optional

Displays output in verbose mode.

You can also run viocli recover -h or viocli recover --help to display the parameters for the command.