This document describes how to create a restore for virtual machine (VM) workloads in Google Distributed Cloud (GDC) air-gapped.
You can create a restore for a backup that was created manually or automatically by a backup plan. The restored VM and its associated disks contain different names based on the value you specify in the restoredResourceName field. All of the VM resources mentioned in the scope of VirtualMachineBackupPlan resource are restored. All the resources that are restored get their name prefixed with the value of the restoredResourceName field.
When a backup is restored, the entire VM is restored. After the resources are created, the restoration of application capability is subject to the VM operating system or image.
This document is for developers in platform administrator or application operator groups that manage VM Backup and restore operations. For more information, see Audiences for GDC air-gapped documentation.
Before you begin
Ensure you have an existing backup available. You can create backups on a schedule using backup plans, or create backups manually.
Request IAM roles
To create a restore, ask your Organization IAM Admin to grant you the
Organization Backup Admin (organization-backup-admin) role. This role lets you
create, get, list, watch, update, patch, and delete VM backup repositories, VM backup plan
templates, VM backup requests, and VM restore requests.
Create a manual VM backup
Create the VirtualMachineRestoreRequest resource using the API:
apiVersion: virtualmachine.gdc.goog/v1
kind: VirtualMachineRestoreRequest
metadata:
name: RESTORE_REQUEST_NAME
namespace: PROJECT_NAME
spec:
virtualMachineBackup: VM_BACKUP_NAME
restoreName: RESTORE_NAME
restoredResourceName: RESTORE_PREFIX
restoredResourceDescription: RESTORED_RESOURCE_DESCRIPTION
targetNamespace: TARGET_NAMESPACE
Replace the following:
VM_BACKUP_NAME: the name of theVirtualMachineBackupresource to restore from.PROJECT_NAME: the name of the GDC project.RESTORE_REQUEST_NAME: the name to give the restore request that is being initiated.RESTORE_NAME: the name to give the restore that is being initiated.RESTORE_PREFIX: the prefix given to newly created VM resources. The restored VM and VM disk names are prefixed withrestoredResourceNamevalue in the restore request.RESTORED_RESOURCE_DESCRIPTION: a description of the restore being performed.TARGET_NAMESPACE: the namespace where the VM is restored. If not provided, the original namespace from the backup is used. Supported only for cluster node VM restorations.