Disassociates one or more ApsaraDB RDS instances from a scaling group.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | DetachDBInstances |
The operation that you want to perform. Set the value to DetachDBInstances. |
ScalingGroupId | String | Yes | asg-bp1igpak5ft1flyp**** |
The ID of the scaling group. |
ForceDetach | Boolean | No | false |
Specifies whether to remove the private IP addresses of instances in the scaling group from the whitelist that manages access to the ApsaraDB RDS instance with which the scaling group is associated. Valid values:
Default value: false. |
ClientToken | String | No | 123e4567-e89b-12d3-a456-42665544**** |
The client token that is used to ensure the idempotence of the request. You can use the client to generate the value, but you must ensure that it is unique among different requests. The token can only contain ASCII characters and cannot exceed 64 characters in length. For more information, see How to ensure idempotence. |
RegionId | String | No | cn-qingdao |
The ID of the region where the scaling group resides. |
DBInstance.N | String | Yes | rm-bp12cy3**** |
The ID of ApsaraDB RDS instance N. You can disassociate up to five ApsaraDB RDS instances from a scaling group at a time. |
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
RequestId | String | 473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E |
The ID of the request. |
Examples
Sample requests
http(s)://ess.aliyuncs.com/?Action=DetachDBInstances
&ScalingGroupId=asg-bp1igpak5ft1flyp****
&ForceDetach=false
&ClientToken=123e4567-e89b-12d3-a456-42665544****
&DBInstance=["rm-bp12cy3****"]
&RegionId=cn-qingdao
&<Common request parameters>
Sample success responses
XML
format
HTTP/1.1 200 OK
Content-Type:application/xml
<DetachDBInstancesResponse>
<RequestId>473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E</RequestId>
</DetachDBInstancesResponse>
JSON
format
HTTP/1.1 200 OK
Content-Type:application/json
{
"RequestId" : "473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E"
}
Error codes
For a list of error codes, visit the API Error Center.
HTTP status code |
Error code |
Error message |
Description |
---|---|---|---|
404 |
InvalidScalingGroupId.NotFound |
The specified scaling group does not exist. |
The error message returned because the scaling group does not exist within the Alibaba Cloud account. |
400 |
InvalidDBInstanceId.NotFound |
DB instance "%s" does not exist. |
The error message returned because the ApsaraDB RDS instance does not exist. |