Restoring through the command line
Although the same vzdump
command can be used to back up both KVM and OpenVZ VMs, there are separate commands to restore each of them:
qmrestore
: This is to restore a KVM-based VMvzrestore
: This is to restore OpenVZ containers
How to do it...
The following command will restore KVM VMs through a command line:
# qmrestore <backup_file> <vmid> [options]
These options can be used with the qmrestore
command:
Option |
Function |
---|---|
|
This has a boolean value of 0 or 1 to allow the overwriting of an existing VM. |
|
This has a boolean value of 0 or 1 to assign a unique random Ethernet address. |
|
This is the name of the pool to add the VM to. |
|
This is the storage ID of the destination storage where a VM's disk image will be restored. |
This command will restore OpenVZ containers through a command line:
# vzrestore <backup_file> <vmid> [options]
The following options can be used with the vzrestore
command:
Option... |
---|