Modifies the automatic backup policy of a PolarDB cluster.
Operation description
Debugging
Authorization information
The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action
policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:
- Operation: the value that you can use in the Action element to specify the operation on a resource.
- Access level: the access level of each operation. The levels are read, write, and list.
- Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
- The required resource types are displayed in bold characters.
- If the permissions cannot be granted at the resource level,
All Resources
is used in the Resource type column of the operation.
- Condition Key: the condition key that is defined by the cloud service.
- Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
Operation | Access level | Resource type | Condition key | Associated operation |
---|---|---|---|---|
polardb:ModifyBackupPolicy | update |
|
| none |
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
DBClusterId | string | Yes | The ID of the cluster. Note
You can call the DescribeDBClusters operation to query information about all clusters that are deployed in a specified region, such as the cluster ID.
| pc-bp13wz9586voc**** |
PreferredBackupTime | string | No | The time period during which automatic backup for level-1 backup is performed. The format is | 15:00Z-16:00Z |
PreferredBackupPeriod | string | No | The backup cycle. Valid values:
Note
| Monday,Tuesday |
DataLevel1BackupRetentionPeriod | string | No | The retention period of level-1 backups. Valid values: 3 to 14. Unit: days. | 3 |
DataLevel2BackupRetentionPeriod | string | No | The retention period of level-2 backups. Valid values:
Note
The default value of this parameter is 0.
| 0 |
BackupRetentionPolicyOnClusterDeletion | string | No | Specifies whether to retain backups when a cluster is deleted. Valid values:
Note
The default value of the parameter is NONE.
| NONE |
BackupFrequency | string | No | The backup frequency. Default value: Normal. Valid values:
Note
| Normal |
DataLevel1BackupFrequency | string | No | The frequency of level-1 backups. Default value: Normal. Valid values:
Note
| Normal |
DataLevel1BackupTime | string | No | The time period during which automatic backup for level-1 backup is performed. The time period is in the Note
| 15:00Z-16:00Z |
DataLevel1BackupPeriod | string | No | The backup cycle of level-1 backups. Valid values:
Note
| Monday,Tuesday |
DataLevel2BackupPeriod | string | No | The backup cycle of level-2 backups. Valid values:
Note
| Monday,Tuesday |
DataLevel2BackupAnotherRegionRegion | string | No | The region where the cross-region level-2 backup is stored. For information about regions that support the cross-region backup feature, see Overview . | cn-hangzhou |
DataLevel2BackupAnotherRegionRetentionPeriod | string | No | The retention period of cross-region level-2 backups. Valid values:
Note
The default value of the parameter is 0.
| 30 |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "C5A5DF0E-5968-4DC1-882E-AC2FE7******"
}
Error codes
HTTP status code | Error code | Error message | Description |
---|---|---|---|
400 | InvalidDataLevel1BackupRetentionPeriod.Malformed | The specified parameter DataLevel1BackupRetentionPeriod is not valid. | The specified DataLevel1BackupRetentionPeriod parameter is invalid. |
400 | InvalidDataLevel2BackupRetentionPeriod.Malformed | The specified parameter DataLevel2BackupRetentionPeriod is not valid. | The specified DataLevel2BackupRetentionPeriod parameter is invalid. |
400 | InvalidBackupRetentionPeriod.Malformed | The specified parameter BackupRetentionPeriod is not valid. | The specified BackupRetentionPeriod parameter is invalid. |
400 | InvalidBackupFrequency.Malformed | The specified parameter BackupFrequency is not valid. | The specified BackupFrequency parameter is invalid. |
400 | InvalidPreferredBackupPeriod.Malformed | The specified parameter PreferredBackupPeriod is not valid. | The specified PreferredBackupPeriod parameter is invalid. |
400 | InvalidDataLevel2BackupPeriod.Malformed | The specified parameter DataLevel2BackupPeriod is not valid. | The specified DataLevel2BackupPeriod parameter is invalid. |
400 | InvalidDataLevel1BackupPeriod.Malformed | The specified parameter DataLevel1BackupPeriod is not valid. | The specified DataLevel1BackupPeriod parameter is invalid. |
400 | InvalidPreferredBackupTime.Malformed | The specified parameter PreferredBackupTime is not valid. | The specified PreferredBackupTime parameter is invalid. |
400 | InvalidDataLevel1BackupTime.Malformed | The specified parameter DataLevel1BackupTime is not valid. | The specified DataLevel1BackupTime parameter is invalid. |
400 | InvalidDataLevel1BackupFrequency.Malformed | The specified parameter DataLevel1BackupFrequency is not valid. | The specified DataLevel1BackupFrequency parameter is invalid. |
400 | InvalidDataLevel2AnotherRegionRegion.NotFound | The specified parameter DataLevel2BackupAnotherRegionRegion does not found. | The specified DataLevel2BackupAnotherRegionRegion parameter cannot be found. |
400 | InvalidDataLevel2AnotherRegionBackupRetentionPeriod.Malformed | The specified parameter DataLevel2BackupAnotherRegionRetentionPeriod is not valid. | The specified DataLevel2BackupAnotherRegionRetentionPeriod parameter is invalid. |
403 | IncorrectBackupPolicy | Current DB type does not support low frequency backupPolicy operation. | Infrequent access backup operations are not supported by the current database type. |
404 | InvalidDBCluster.NotFound | The DBClusterId provided does not exist in our records. | The specified DBClusterId parameter does not exist in the current record. |
404 | InvalidDBClusterId.NotFound | The DBClusterId provided does not exist in our records. | The specified DBClusterId parameter does not exist in the current record. |
404 | InvalidParam | new archiveBackup policy already exists. dumpretention parameter cannot used alone | An archive backup policy has been created. The dumpretation parameter cannot be used alone. |
404 | InvalidDBClusterId.Malformed | The specified parameter DBClusterId is not valid. | The specified DBClusterId parameter is invalid. |
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation |
---|---|---|
2023-09-12 | The Error code has changed | View Change Details |
2022-07-13 | The Error code has changed | View Change Details |
2022-06-01 | The Error code has changed. The request parameters of the API has changed | View Change Details |
2021-03-02 | The Error code has changed. The request parameters of the API has changed | View Change Details |