You need to enable JavaScript to run this app.
文档中心
弹性伸缩

弹性伸缩

复制全文
下载 pdf
伸缩组
AttachDBInstances - 添加RDS实例
复制全文
下载 pdf
AttachDBInstances - 添加RDS实例
为伸缩组关联一个或多个RDS数据库实例。​
请求参数​
下方仅列出该接口特有的请求参数和部分公共参数。更多信息请见公共参数。​
Action string 必选 示例值:AttachDBInstances​
要执行的操作,取值:AttachDBInstances。​
​
Version string 必选 示例值:2020-01-01​
API的版本,取值:2020-01-01。​
​
ScalingGroupId string 必选 示例值:scg-3ty5i3vde54bwbh****​
伸缩组ID。​
​
DBInstanceIds.N string[] 必选 示例值:rds-mysql-42b38c76****​
RDS实例ID列表。​
  • 参数 - N:表示数据库实例的序号,取值 1 ~ 40。​
  • 多个数据库实例的端口号之间用&分隔。​
​
ForceAttach boolean 可选 示例值:true​
是否把当前伸缩组内实例的私网 IP 全部添加到RDS 实例 IP 白名单中:​
  • true:添加​
  • false(默认):不添加​
​
​
​
返回参数​
下方仅列出本接口特有的返回参数。更多信息请参见返回结构。​
ScalingGroupId string 示例值:scg-3ty5i3vde54bwbh5****​
伸缩组ID。​
​
​
​
请求示例​
​
GET /?Action=AttachDBInstances&DBInstanceIds.1=rds-mysql-42b38c76****&ScalingGroupId=scg-3ty5i3vde54bwbh****&Version=2020-01-01 HTTP/1.1​
Host: auto-scaling.cn-beijing.volcengineapi.com​
X-Date: 20240507T094003Z​
Authorization: HMAC-SHA256 Credential=Adfks******wekfwe/20240507/cn-beijing/auto_scaling/request, SignedHeaders=host;x-date, Signature=47a7d934ff7b37c03938******cd7b8278a40a1057690c401e92246a0e41085f​
​
​
​
返回示例​
​
{​
"ResponseMetadata": {​
"RequestId": "20240507174010025154061064E2B8B9",​
"Version": "2020-01-01",​
"Service": "auto_scaling",​
"Region": "cn-beijing"​
},​
"Result": {​
"ScalingGroupId": "scg-3ty5i3vde54bwbh5****"​
}​
}​
​
错误码​
下表为您列举了该接口与业务逻辑相关的错误码。公共错误码请参见公共错误码文档。​
​
状态码​
错误码​
错误信息​
说明​
400​
InvalidScalingGroup.InvalidStatus​
The specified ScalingGroup is not in the correct status.​
指定的伸缩组当前状态不支持该操作。​
400​
MissingParameter.ScalingGroupId​
The required parameter ScalingGroupId is not supplied.​
伸缩组ID不能为空。​
400​
MissingParameter.DBInstanceIds​
The required parameter DBInstanceIds is not supplied.​
RDS实例ID列表不能为空。​
400​
LimitExceeded.DBInstanceIds​
You've reached the limit on the number of DBInstanceIds that you can attach.​
已达到可关联的RDS数据库数量上限。​
400​
MissingParameter.DBInstanceId​
The required parameter DBInstanceId is empty.​
RDS实例ID不能为空。​
400​
InvalidDBInstanceId.InvalidStatus​
The specified DBInstance [%s] is not in the correct status.​
指定的RDS实例状态错误。​
400​
InvalidDBInstanceID.InvalidVersion​
The specified DBInstance [%s] is not in the correct WhiteList Version.​
指定的RDS实例版本不支持。​
404​
InvalidScalingGroupId.NotFound​
The specified ScalingGroup [%s] does not exist.​
指定的伸缩组不存在。​
404​
InvalidDBInstanceId.NotFound​
The specified DBInstanceId [%s] does not exist.​
指定的RDS实例ID不存在。​
409​
InvalidDBInstanceId.Conflict​
The specified DBInstanceId [%s] already exists.​
指定的RDS实例ID已存在。​
500​
InternalError​
An internal error has occurred.​
内部错误,请重试。如果多次尝试失败,请提交工单。​
​
​
最近更新时间:2025.08.27 19:18:34
这个页面对您有帮助吗?
有用
有用
无用
无用