You can perform a restore operation for OpenStack from the command line using a saved script or an XML input file.
Before You Begin
You can use an XML file to provide input parameter values for commands. Use one of the following methods to provide XML input:
-
Download the restore_template.xml file, modify it to match your requirements, and include it in the command line as shown in the sample procedure and examples for this topic.
-
Generate a script and XML parameters file from the CommCell Console and save it on the computer where the restore will be performed.
Note
To restore a virtual machine that has the same name (but a different UUID) as an existing virtual machine in OpenStack, add the allowDuplicateNames parameter with a value of true to the XML file.
Procedure
-
To log on to the CommServe computer, run the
qlogincommand. -
On the command line, go to the location where you saved the XML file, and type the following command:
qoperation execute -af restore_template.xml -appName 'Virtual Server' -clientName xxxxx -backupsetName xxxxx -destPath xxxxx -sourceItem xxxxx –subclientName xxxxxwhere:
-
appNameis the name of the application. In this case, it is 'Virtual Server'. -
clientNameis the name of the virtualization client that contains the subclient. -
backupsetNameis the name of the backup set that contains the subclient. -
destPathis the destination path. -
sourceItemis the backup data to be restored in the form'\vm_guid\drive\folder_name'. -
subclientNameis the name of the subclient that contains the content to be restored.Note
Backup data can be identified using the value of the sourceItem parameter in the form
'\vm_guid\drive\folder_name', such as:'\4219f389-9a22-0981-6d20-c93c195134f9\Volume1\FULL|'. If thesourceItemparameter contains a directory path, verify that the path is a valid path for backed up data before you run the command.
-
-
To verify the status of the job, type the following command:
qlist job −j jobID -
After the job completes, to log off from the CommServe host, run the
qlogoutcommand.
Example of Restoring from a Current Backup
qoperation execute -af restore_template.xml -appName 'Virtual Server' -clientName client1 -backupsetName backupset1 -destPath 'C:\test' -sourceItem 'C:\test'Example of Restoring Files to a Point-in-Time (Date)
qoperation execute -af restore_template.xml -appName 'Virtual Server' -clientName client1 -backupsetName backupset1 -destPath 'C:\test' -sourceItem 'C:\test' -toTimeValue 2019-11-28Example of Restoring Files to a Point-in-Time (Date and Time)
qoperation execute -af restore_template.xml -appName 'Virtual Server' -clientName client1 -backupsetName backupset1 -destPath 'C:\test' -sourceItem 'C:\test' -toTimeValue '2019-11-28 15:40:00'