Connecting a Linux VM with OS Login to Cloud Backup
You can back up Compute Cloud VMs with supported Linux-based operating systems and OS Login.
For the Cloud Backup agent to run properly, VMs must meet the minimum requirements.
Warning
To connect a VM to Cloud Backup, make sure its service account, public IP, and security group are set up correctly. For more information, see Connecting Compute Cloud VMs to Cloud Backup.
If you have deleted a VM with OS Login from Cloud Backup and want to reconnect it, follow the steps below.
To connect a Linux VM with OS Login to Cloud Backup:
-
Connect the previously created service account to the VM.
-
Set up network access for your VM.
-
Install the Cloud Backup agent:
Yandex Cloud CLI-
If you do not have the Yandex Cloud command line interface yet, install and initialize it.
-
See the description of the CLI command to install the Cloud Backup agent:
yc backup agent install --help
-
Run this command:
yc backup agent install \ --id <VM_ID> \ --policy-ids <policy1_ID>[,<policy2_ID>]
Where:
id
: VM unique ID. This is a required parameter.policy-ids
: IDs of the backup policies to attach to the VM after installing the agent. This is an optional parameter. Attaching a policy to a VM is an asynchronous operation which may take several minutes.
After running the command, you will see a warning about installing the backup agent:
This command will launch commands on specified instance to install backup agent via oslogin. Do you confirm this actions to be executed? [Yes/no][y/N]
. Confirm the installation: in the terminal, typeyes
and pressEnter
. The agent installation will start. It will take some time.Result:
... Agent registered with id D9CA44FC-716A-4B3B-A702-C6**********
-
(Optional) To view the Cloud Backup agent installation logs, run this command:
yc backup agent debug-info \ --id <VM_ID>
-
To connect an existing VM to Cloud Backup, you can also take snapshots of the VM disks and create a new VM based on those snapshots by selecting the backup option.