Cloud Backup integrates with the Alibaba Cloud snapshot service and provides an agentless way to back up ECS instances and disks. You can create crash-consistent backups for all disks of an ECS instance, including the system disk and data disks. You can use these backups to restore an entire ECS instance, a single ECS disk, or clone the entire instance to create a new ECS instance.
Prerequisites
You have activated the Alibaba Cloud Cloud Backup service. Although activating Cloud Backup is free of charge, Cloud Backup charges software usage fees for ECS instance backups. For more information, see Cloud Backup pricing.
You have activated the Elastic Computing Service (ECS) snapshot service.
To create a crash-consistent backup of an entire instance, all disks of the ECS instance must be Enhanced SSDs (ESSDs). Otherwise, Cloud Backup creates crash-consistent backups for individual disks.
Background information
The ECS instance backup feature uses periodic disk backup policies to protect entire ECS instances or specific disks, providing a low-cost protection solution.
From an ECS instance backup, you can restore the original ECS instance, clone a new ECS instance, or clone a new disk. For more information about the differences, see What are the differences between an ECS instance backup and a snapshot?.
Notes
If the snapshot service is not enabled, Cloud Backup automatically enables it the first time you use the ECS instance backup feature. You are charged for using ECS snapshots. Cloud Backup also charges a software usage fee for ECS instance backups. For more information, see Cloud Backup pricing.
ECS instance backup is a backup orchestration service provided by Cloud Backup that is based on the ECS snapshot feature. ECS charges for the snapshot size used by this feature, the snapshot size in the destination region that is generated when you enable Replication to Other Region, and the cross-region traffic. For more information, see Snapshot billing.
When you create a backup plan or attach a backup policy for the first time, Cloud Backup automatically creates a service-linked role to obtain permissions to access the required resources.
ECS instance backup does not support backing up and restoring local disks.
Storing data on local disks can result in data loss. You can use ECS File Backup to protect files on your local disks, or use Database Backup to protect databases deployed on your local disks.
When you edit a previously created backup plan, if your region supports backup policies, Cloud Backup converts your backup plan into a backup policy by default. This operation does not affect your backup parameters.
You can attach only one backup policy to an ECS instance. You do not need to create a backup vault for ECS instance backups. You can set the backup interval, retention period, and other parameters in the backup policy. For more information about the parameters in a backup policy, see Manage backup policies.
To avoid conflicts in snapshot execution times, do not use both the Cloud Backup instance backup service and the disk snapshot service for the same disk. You should choose one backup method as needed.
Back up an ECS instance
Backup policies are not available in all regions. To view the list of supported regions, click Policy Center in the navigation pane on the left.
Log on to the Cloud Backup console.
In the navigation pane on the left, choose .
In the top navigation bar, select a region.
In the upper-left corner, click Add ECS Backup.
In the Add ECS Backup panel, you can configure the following parameters.
Select the backup objects and click Next.
ImportantSelect the ECS instances that you want to back up. By default, all disks are backed up. You can click All Disks and specify the disks to back up in the Backup Object dialog box.
By default, the Protect All Disks switch is enabled to protect all disks attached to the ECS instance, including any disks that are attached later. You can disable the Protect All Disks switch to select only specific disks to protect.
You can create ECS instance backups in batches. You can create up to 99 backups at a time.
Cloud Backup automatically checks whether the selected ECS instances support consistent snapshot groups. If they do, a consistent snapshot group is created by default. If the check fails, crash-consistent backups are created for individual disks. For more information about snapshot consistency limitations, see Notes on creating a consistent snapshot group.
Configure the backup options and click OK.
You can set the backup method by selecting Manual Backup or Associate Backup Policy. The following table describes the parameters.
After the backup plan is created, Cloud Backup starts the backup job at the specified time and interval.
Backup successful
At the scheduled time, Cloud Backup starts the backup job. The backup is complete when the Backup Status is Successful. You can view and manage backup points in the backup history. Backup points can be used for recovery and cloning. If a backup point is created by a backup policy with backup lock enabled, the backup point cannot be deleted before it expires.
View backup size details
The ECS Instance Backup console displays the backup size, which is the total snapshot size of all disks managed by Cloud Backup. The displayed size may be delayed by up to 24 hours.
The backup size is calculated based on the total size of the snapshot chain generated by the protected ECS instance. To view the snapshot size of a specific ECS instance or disk, go to the Snapshot console. For more information, see How do I view the size of a snapshot?.
Snapshot retention period
Snapshots created using the ECS instance backup feature are displayed in the Snapshot list in the ECS console. They are identified as "Cloud Backup Service" in the Snapshot Source column. The Retention Time of the snapshot is the same as the Retention Period configured in the ECS instance backup policy. Due to a technical limitation, when you use the DescribeSnapshots API operation to view the snapshot's retention time, the time is displayed as permanent. You can disregard this information. For more information about how to extend the retention period of an ECS instance backup point, see Extend the retention period of a backup point.
Snapshots created by Cloud Backup can be managed only through the Cloud Backup service before their retention period expires.
Before the retention period of an ECS instance backup point expires, if the backup policy associated with the target ECS instance does not have the Backup Lock feature enabled and is not configured to retain at least one backup, you can delete the corresponding snapshot. For more information, see How do I delete a disk snapshot created by an ECS instance backup? or call the DeleteSnapshot - Delete a backup snapshot API operation. This also applies to scenarios that involve only snapshots of individual disks.
When the retention period of an ECS instance backup point expires, the Cloud Backup service automatically removes the backup point and deletes all its associated snapshots.
If the snapshot has been used to create a disk or an image, Cloud Backup no longer manages the lifecycle of that snapshot. You can go to the ECS console - Snapshot page or call the DeleteSnapshot - Delete a snapshot API operation to manually delete the snapshot.
Snapshots generated from ECS instance backups can be used for snapshot sharing. You should check the retention period of the shared snapshot in the ECS console or the Cloud Backup console. This is to prevent the shared snapshot from becoming invalid due to automatic deletion after the retention period expires.
Extend the retention period of a backup point
To retain historical data from an ECS instance backup for a longer period, you can extend the retention period of the backup point. The snapshots corresponding to the backup point with an extended retention period cannot be deleted before they expire. When the retention period of the ECS instance backup point expires, the system automatically deletes the backup point and its associated snapshots.
The retention period of a backup point can only be extended, not shortened.
ECS instance backup supports three scopes: consistent group backup, instance backup, and disk backup. You can extend the retention period only for the historical data of instance backups.
You can only extend the retention period by an integer number of days. The maximum allowed extension is 65,536 days. The new retention period is synchronized to the snapshot's retention time.
On the Backed-up ECS Instances tab, click the
icon next to the target ECS instance.
On the Instance Protection tab, click the backup point whose retention period you want to extend, and then set a new retention period.
Click Save.
After the configuration is complete, the new expiration time appears in the Expiration Time column. This retention period is then synchronized to the snapshot.
View all associated policies
If an ECS instance is associated with multiple backup policies, you can select the target instance from the Backed-up ECS list and click View All Associated Policies. In the View All Associated Policies panel, you can perform the following operations for each backup policy:
In the Actions column, click Execute Plan Immediately to manually trigger the backup job.
Edit Plan: In the Actions column, choose
to modify the policy's backup plan.Delete a backup plan: In the Actions column, click
.Pause Plan: In the Actions column, choose
to prevent the backup plan from running automatically.
Restore an ECS instance
For more information, see ECS instance recovery.
Restore an ECS disk
For more information, see Disk recovery.
Cross-region replication and recovery
Enable cross-region replication
After you enable the cross-region replication feature in a backup plan, backups are automatically replicated to the specified Destination Region. You can click the link for the backup plan to Modify the destination region.
After the backup is replicated to the destination region, if the source ECS instance is infected by a virus or its data is accidentally deleted, you can use the backup in the destination region to create a new instance and recover the data.
Cross-region replication completed
On the Jobs tab, a Remote Replication Status of Completed indicates that your backup data has been replicated to another region.
Restore an ECS instance (disaster recovery failover)
For example, if the destination region for cross-region replication is Shanghai and the source ECS instance is infected by a virus or its data is accidentally deleted, you can perform a disaster recovery failover in Shanghai to create a new ECS instance and recover the data.
Log on to the Cloud Backup console.
In the navigation pane on the left, choose
.In the upper-left corner of the top menu bar, select a region. For example, China (Shanghai).
On the Backed-up ECS Instances tab, you can find the cross-region replicated ECS instance.
Select a backup point from the appropriate time range and click Disaster Recovery.
In the Disaster Recovery panel, configure the network, security group, and instance type. Then, click OK to create a pay-as-you-go ECS instance.
ImportantCreating a new ECS instance incurs fees based on ECS billing rules. For more information, see Pay-as-you-go for ECS.
After the job is created, you can view the recovery progress in the Job List. When the recovery is complete, you can click the ECS instance link to access the instance.
Troubleshooting
The following sections describe common errors that may occur when you create or run an ECS instance backup plan and how to resolve them.
How to resolve the Retention Period cannot be set to Permanent for ECS instance backup. error
What to do if the error No destination region is specified. is reported?
How to handle the This ECS instance has been released. error
Error: The backup plan has been suspended.. What should I do?
An error is reported: Failed-Failed to synchronize metadata.. How do I resolve it?
Related operations
ECS instance backup provides the following features to help you manage related tasks:
Tab | Description | Related operations |
Backed-up ECS Instances | Displays the tasks for your protected ECS instances. |
|
Jobs | Displays the status of executed tasks. | For a task that is in progress, you can cancel its execution. |
What to do next
References
Cloud Backup provides resource plans for various backup scenarios. These plans offer discounts to help you save costs. For more information, see Purchase a resource plan.
Cloud Backup supports backing up one or more disks. From a backup, you can restore the original disk or create a new disk at any time. For more information, see Create a disk backup.
Cloud Backup supports backing up directories and files on ECS instances. You can view and restore data at any time. For more information, see Back up ECS files.
Cloud Backup supports backing up directories and files from local servers to the cloud. You can view and restore data at any time. For more information, see Back up local files.
To learn more about the product, see What is Cloud Backup?.