Yandex Cloud
Search
Contact UsGet started
  • Blog
  • Pricing
  • Documentation
  • All Services
  • System Status
    • Featured
    • Infrastructure & Network
    • Data Platform
    • Containers
    • Developer tools
    • Serverless
    • Security
    • Monitoring & Resources
    • ML & AI
    • Business tools
  • All Solutions
    • By industry
    • By use case
    • Economics and Pricing
    • Security
    • Technical Support
    • Customer Stories
    • Cloud credits to scale your IT product
    • Gateway to Russia
    • Cloud for Startups
    • Education and Science
    • Yandex Cloud Partner program
  • Blog
  • Pricing
  • Documentation
© 2025 Direct Cursus Technology L.L.C.
Yandex Cloud Backup
  • Getting started
    • All guides
    • Activating the service
      • Creating and connecting a Linux VM
      • Creating and connecting a Windows VM
      • Connecting a Linux VM
      • Connecting a Linux VM with OS Login
      • Connecting a Windows VM
      • Updating a VM connection to Cloud Backup
      • Updating or restoring a Cloud Backup agent
      • Updating a Linux VM connection with OS Login
      • Viewing VM connection settings
      • Viewing backup log
      • Deleting a VM from Cloud Backup
    • Viewing operations with resources
    • Viewing backup statistics
  • Access management
  • Terraform reference
  • Monitoring metrics
  • Audit Trails events
  • Release notes
  • Troubleshooting
  1. Step-by-step guides
  2. VM in Cloud Backup
  3. Connecting a Linux VM with OS Login

Connecting a Linux VM with OS Login to Cloud Backup

Written by
Yandex Cloud
Updated at April 18, 2025

You can back up Compute Cloud VMs with supported Linux-based operating systems and OS Login.

For the Cloud Backup agent to work correctly, the VM 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 and Yandex BareMetal servers 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:

  1. Create a service account with the backup.editor role.

  2. Connect the previously created service account to the VM.

  3. Set up network access for your VM.

  4. Install the Cloud Backup agent:

    Yandex Cloud CLI
    1. If you do not have the Yandex Cloud CLI yet, install and initialize it.

    2. See the description of the CLI command to install the Cloud Backup agent:

      yc backup agent install --help
      
    3. 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 for attaching to the VM after installing the Cloud Backup agent. This is an optional parameter. Attaching a policy to a VM is an asynchronous operation which may take several minutes.

      Once you execute the command, you will get the Cloud Backup agent installation warning: 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, type yes and press Enter. The Cloud Backup agent installation will start. It will take some time.

      Result:

      ...
      Agent registered with id D9CA44FC-716A-4B3B-A702-C6**********
      
    4. (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.

See alsoSee also

  • Creating a Linux VM with a connection to Cloud Backup
  • Linking a VM to a backup policy
  • Creating a backup policy
  • Restoring a VM or Yandex BareMetal server from a backup

Was the article helpful?

Previous
Connecting a Linux VM
Next
Connecting a Windows VM
© 2025 Direct Cursus Technology L.L.C.