When you restore a virtual machine (VM) from a backup, you can choose to restore the VM as a Google Cloud Platform instance.
You can convert VMs to Google Cloud Platform from the following hypervisors:
-
Amazon streaming backups or IntelliSnap backup copies
-
Azure Resource Manager streaming backups or IntelliSnap backup copies
-
VMware streaming backups or IntelliSnap backup copies
Before You Begin
-
Make any necessary changes to the source VM. For more information, see Preparing VMs for Conversion to Google Cloud Platform.
-
Back up the VM that you plan to convert.
-
Create a Google Cloud Platform hypervisor.
-
When restoring an Azure VM, do the following:
-
For Windows computers: enable the pagefile on the C: drive of the source VM. This will prevent you from receiving an error message when you reboot the destination VM.
-
For Linux computers: Verify that the fstab entry of the source disk should be based on disk UUID and not disk name. If it is not based on disk UUID, then the restored VM will not boot up.
-
Start the Restore Wizard
-
From the Command Center navigation pane, go to Protect > Virtualization.
The Overview page appears.
-
Click the VM groups tab.
The VM group page appears.
-
On the VM groups tab, in the row for the VM group, click the action button, and then click Restore.
The Select restore type page appears.
-
To convert the full virtual machine, select Full virtual machine.
The Full virtual machine page appears.
-
Select the instances to restore, and then click Restore.
The restore wizard appears.
Specify the Restore Destination
-
For Type, select Out of place.
-
For Restore as, select Google Cloud Platform.
-
For Destination, select the hypervisor to restore the instances to.
-
For Access node, select Automatic, an access node, or an access node group.
If you are restoring multiple instances, select Automatic to distribute the workload across the access nodes that are assigned for the destination hypervisor. First, the instances are assigned to access nodes that are in the same zone. Then, instances are assigned to access nodes that are in the same region. If no access nodes are available in the same zone or region, then the instances are assigned to access nodes using the round-robin method. The Automatic option is available for full restore and conversion operations from both streaming backups and IntelliSnap backup copies.
If you select an access node group to restore instances, the Commvault software distributes the workload across the access nodes that are available in the access node group.
-
Click Next.
The Virtual Machines page appears.
Specify the Virtual Machines and Settings
-
Select the virtual machines to restore.
-
To modify the restore settings, click Edit, and then specify the following:
-
VM display name: Enter a name for the restored virtual machine.
-
Project ID/Zone: Select the destination zone for the restored virtual machine.
-
Machine type: Select the machine type for the restored virtual machine.
-
Service account: Select the service account for the restored virtual machine.
-
Network settings: To modify the network settings, click the action button, select Edit, and then specify the following:
-
Virtual network/subnet: Select a different virtual network.
-
To use an internal IP address, leave the External IP toggle key turned off, and then select one of the following:
-
Ephemeral (Custom): Enter a custom ephemeral IP address.
-
Ephemeral (Automatic): GCP automatically assigns an ephemeral IP address.
-
Reserved static IP: Select from a user-defined set of available, reserved IP addresses.
-
-
To use an external IP address, move the External IP toggle key to the right, and then select one of the following:
-
Ephemeral: GCP automatically assigns an ephemeral IP address.
-
Reserved static IP: Select from a user-defined set of available, reserved IP addresses.
-
-
-
Advanced options:
-
Sole-tenant nodes: Select the nodes or node groups that you want to associate with the restored virtual machines.
Note
The Node afinity dialog boxlists all available node groups. However, you can select only node groups that are supported for the specified machine type.
For information about sole-tenant nodes, go to the Google Cloud documentation website, and search for "sole-tenant nodes".
-
Custom metadata: Enter the custom or predefined key-value pairs for the scripts that you want to run when the virtual machine is restored.
The replicated virtual machine will have the key-value pairs in the Custom metadata section on the VM instance details page on the destination VM.
For more information about predefined key-value pairs, see the following:
-
Linux: Using startup scripts on Linux VMs on the Google Cloud documentation website.
-
Windows: Using startup scripts on Windows VMs on the Google Cloud documentation website.
-
-
-
-
Click Next.
The Restore Options page appears.
Specify the Restore Options
Specify the following settings:
-
Power on VMs after restore: Automatically restart virtual machines after they are restored.
The power state of the virtual machine does not affect subsequent backups. If the virtual machine is powered on during backups, by default, the virtual machine is powered on again after the restore completes (unless you clear this check box).
-
Unconditionally overwrite if it already exists: Delete an existing virtual machine and replace it with the restored virtual machine.
Note
If an existing virtual machine with the same name exists on the destination host and you do not select Unconditionally overwrite if it already exists, the restore job fails.
-
Reuse existing VM client: Reuse the existing virtual machine and map its information, such as client name, host name, and client ID, to the source virtual machine.
-
Notify user on job completion: Receive an email notification that the restore is complete.
The Summary page appears.
Review the Summary and Start the Restore
-
Review the summary to verify the settings.
-
Click Submit to start the restore.
What to Do Next
-
If a Linux instance does not boot up after conversion, check the grub configuration file (/etc/default/grub) and the fstab file (/etc/fstab). In these files, if a partition is identified by the device name (/dev/sda1), replace it with the partition’s UUID.
-
If a Linux instance boots up but is not available through ssh username/password login, then do the following:
-
Edit the /etc/ssh/sshd_config file.
-
Change PasswordAuthentication and ChallengeResponseAuthentication to yes.
-
Restart ssh by running the following command:
systemctl restart sshd
-