Create an ETCD backup policy
The ETCD component on the cluster is a distributed data storage component responsible for storing the configuration information of the cluster.ETCD is deployed on all the control nodes of the cluster.Since all the control nodes of the cluster share the same configuration, you only need to backup the ETCD data on one of the control nodes when you perform an ETCD backup.
The backup policy configures the backup data source (control node, backup path), backup data storage location, backup method and other information. Every time you perform a backup based on the policy, you can generate a new backup record, which is convenient for you to automatically back up the configuration of the cluster at any time or periodically.
Precautions
In some extreme cases, if your cluster is configured with three master nodes, you may experience the simultaneous downtime of all three master nodes. In this case, to ensure that you are able to fully recover your cluster in such situations, it is recommended that you refer to the S2 scenario in Customer Portal, Recovery Scenario for 3 master nodes of a business cluster, which provides recovery guidance for such extreme cases.
Prerequisites
If you need to back up the clustered ETCD data in external storage, please prepare the docking information of the external storage in advance. Currently, only S3 (Simple Storage Service) compatible object storage is supported, such as Amazon S3, MinIO, Tencent Cloud Object Storage COS, Ali Cloud Object Storage OSS, and so on.
Basic Information
-
In the left navigation bar, click Clusters > Backup & recovery. 2.
-
Switch to the Backup Manage tab. 3.
-
Click Create Backup Policy and select ETCD Backup. 4.
-
Enter Name and click Next.
Storage Configuration
-
Refer to the following instructions on the Storage Configuration page to configure the relevant parameters.
Parameters Description Backup node Control node in the cluster. Backup Path The path where ETCD data is stored on the node. External memory Whether to use an external storage service to store backup data。
- Turning off the switch causes the backup to be performed with the data backed up under the backup path of the selected backup node.
- Turn on the switch and configure the external storage service, when performing backup, the ETCD data will be backed up locally at the same time and synchronized to the external storage, double backup to ensure data security. Please select the backup repository that passes the connectivity check, or click Create Backup Repository 。
Hint: When you are finished creating a backup repository, you can click OK and Create ETCD Backup to return to this page to continue creating; or click Create to return to the Backup Repositories list page to view the backup repositories you have created. -
To create a backup repository, click Create.
Method
Configure a time policy for backing up data.
-
Backup only once: A backup will be performed immediately after the policy is created. After configuring the Backup retention time, backup files exceeding the retention time will be automatically cleaned up by the system.
-
Scheduled backups: Set up scheduled backup rules to automatically execute backup policy to backup data periodically, support input Crontab expression. For details, please refer to [How to set a timed trigger rule?] (/en/platform-faq/00crontab/). After configuring Backup retention time, backup files exceeding the retention time will be automatically cleaned up by the system.
Hint: Click the input box to expand the platform’s preset Backup Rule Templates, select a suitable template and simply modify it to quickly set up backup rules.
Relevant operations
Perform the backup policy manually
Manually executes created backup policies (including those with timed backup rules set) for data backup. Each execution generates a new backup record.
-
In the left navigation bar, click Clusters > Backup & recovery. 2.
-
Switch to the Backup Manage tab. 2.
-
Click
> Perform Backup and confirm.
Export the backup task log
Supports manual export of backup task logs under a specified backup policy.
Hint: Log export is not supported when the backup task is running.
Procedure of operation 1.
-
In the left navigation bar, click Clusters > Backup & recovery. 2.
-
Switch to the Backup Manage tab. 2.
-
Click the Backup Policy Name of the backup task log to be exported.
-
In the Backup Logs area, click the right of the backup log.
> Export Log。