Upgrades host specifications.

After you create a host in an ApsaraDB for MyBase dedicated cluster, you can modify the specifications of the host based on your business requirements. The host specifications include the CPU and memory resources. For more information, see Upgrade host specifications.

Note If you upgrade the specifications of a host, the host restarts. Then, the database instances that are running on the host restart. For more information about the impacts of a host restart, see Restart a host.


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 No ModifyDedicatedHostClass

The operation that you want to perform. Set the value to ModifyDedicatedHostClass.

DedicatedHostId String Yes ch-bp1fgj3kt7fsb****

The ID of the host. You can call the DescribeDedicatedHosts operation to query the host ID.

RegionId String Yes cn-hangzhou

The region ID of the host. You can call the DescribeDedicatedHostAttribute operation to query the region ID.

SwitchTime String Yes 2021-07-13T07:14:22Z

The time when the specifications of the specified host are upgraded. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

Note You must specify the SwitchTime parameter only if the SwitchTimeMode parameter is set to 2.
TargetClassCode String Yes rds.c6.x4large

The specification code to which you want to upgrade for the specified host. For more information, see Instance types and specifications of hosts.

SwitchTimeMode String No 2

The execution mode to upgrade host specifications. Valid values:

  • 0: This is the default value. Host specifications are immediately upgraded.
  • 2: Host specifications are upgraded at the specified time.
    Note If you set this parameter to 2, you must also configure the SwitchTime parameter.

Response parameters

Parameter Type Example Description
DedicatedHostId String ch-bp1fgj3kt7fsb****

The ID of the host.

RequestId String D6E068C3-25BC-455A-85FE-45F0B22ESD12

The ID of the request.

TaskId String 10254125

The ID of the task.


Sample requests

&<Common request parameters>

Sample success responses

XML format


JSON format

    "DedicatedHostId": "ch-bp1fgj3kt7fsb****",
    "TaskId": "10254125",
    "RequestId": "D6E068C3-25BC-455A-85FE-45F0B22ESD12"

Error codes

HttpCode Error code Error message Description
400 InvalidAction The specified action is not valid. The error message returned because the specified operation is invalid.

For a list of error codes, visit the API Error Center.