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.
|
-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.
|
-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.
This parameter is mandatory when recovering the following items:
|
-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: This parameter is mandatory when recovering the following items:
|
--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.