Upgrades the kernel version of a PolarDB for MySQL cluster.

Note
  • You can upgrade the kernel version of a PolarDB for MySQL cluster only to a revision version. For example, you can upgrade the kernel version of a cluster from V8.0.1.1.3 to V8.0.1.1.4.
  • You must use the credentials of your Alibaba Cloud account to upgrade the kernel version of a PolarDB for MySQL cluster. RAM users are not authorized to create scheduled tasks that are used to upgrade kernel versions for PolarDB for MySQL clusters.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes UpgradeDBClusterVersion

The action that you want to perform. Set the value to UpgradeDBClusterVersion.

DBClusterId String Yes pc-****************

The ID of the cluster.

Note You can call the DescribeDBClusters operation to query the information about each cluster that belongs to your Alibaba Cloud account. The returned information includes the ID of each cluster.
UpgradePolicy String No HOT

The upgrade policy. Valid values:

  • HOT: hot upgrade.
  • COLD: cold upgrade. Only PolarDB for MySQL 8.0 clusters support this upgrade policy.
UpgradeLabel String No INNOVATE

The upgrade tag. Set the value to INNOVATE.

Note If you specify this parameter, the UpgradePolicy parameter must be set to COLD.
PlannedStartTime String No 2021-01-14T09:00:00Z

The earliest start time to run the task to upgrade the kernel version of the specified cluster. The task runs within a specified period of time. The value of this parameter must be in the YYYY-MM-DDThh:mm:ssZ UTC format.

Note
  • The earliest start time of the task can be a point in time within the next 24 hours. For example, if the current time is 2021-01-14T09:00:00Z, you can specify a point in the time range from 2021-01-14T09:00:00Z to 2021-01-15T09:00:00Z.
  • If you do not specify this parameter, the kernel upgrade task runs immediately after the request is submitted.
PlannedEndTime String No 2021-01-14T09:30:00Z

The latest start time to run the task. Specify the time in the YYYY-MM-DDThh:mm:ssZ format. The time must be in UTC.

Note
  • The value of this parameter must be at least 30 minutes later than the value of the PlannedStartTime parameter.
  • By default, if you specify the PlannedStartTime parameter but do not specify the PlannedEndTime parameter, the latest start time of the task is set to a value that is calculated by using the following formula: Value of the PlannedEndTime parameter + 30 minutes. For example, if you set the PlannedStartTime parameter to 2021-01-14T09:00:00Z and you do not specify the PlannedEndTime parameter, the latest start time of the task is set to 2021-01-14T09:30:00Z.
FromTimeService Boolean No false

Specifies whether to immediately run the kernel upgrade task. Valid values:

  • false: runs the kernel upgrade task in a scheduled manner.
  • true: immediately runs the kernel upgrade task.
Note This parameter is not required when you call the operation.
UpgradeType String No PROXY

The upgrade type. Default value: ALL. Valid values:

  • PROXY: specifies to upgrade PloarProxy.
  • DB: specifies to upgrade the kernel version.
  • ALL: specifies to upgrade both PloarProxy and kernel version

Response parameters

Parameter Type Example Description
RequestId String CAE6755F-B79A-4861-B227-801FE8******

The ID of the region.

Examples

Sample requests

http(s)://polardb.aliyuncs.com/?Action=UpgradeDBClusterVersion
&DBClusterId=pc-****************
&<Common request parameters>

Sample success response

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<UpgradeDBClusterVersionResponse>
<RequestId>CAE6755F-B79A-4861-B227-801FE8******</RequestId>
</UpgradeDBClusterVersionResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "RequestId" : "CAE6755F-B79A-4861-B227-801FE8******"
}

Error codes

HTTP status code Error code Error message Description
400 ScheduleTaskExist The specified dbCluster already has a scheduled task. The error message returned because the specified instance already has a scheduled task.
400 InvalidUpgradeLabel.Malformed The specified parameter UpgradeLabel is not valid. The error message returned because the specified UpgradeLabel parameter is invalid.
403 OperationDenied.UpgradeType The operation is not permitted due to gdn limit The error message returned because the current upgrade type is not supported due to GDN restrictions.
403 IncorrectGdnStandbyDBVersion Current gdn standby cluster is not the latest db version. The current secondary cluster of the GDN does not run the latest database version.
404 InvalidDBCluster.NotFound The DBClusterId provided does not exist in our records. The error message returned because the specified cluster ID does not exist in the current record.

For a list of error codes, see Service error codes.