Queries scaling groups.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | DescribeScalingGroups |
The operation that you want to perform. Set the value to DescribeScalingGroups. |
RegionId | String | Yes | cn-qingdao |
The region ID of the scaling group. |
PageNumber | Integer | No | 1 |
The number of the page to return. Pages start from page 1. Default value: 1. |
PageSize | Integer | No | 10 |
The number of entries to return on each page. Maximum value: 50. Default value: 10. |
ScalingGroupName | String | No | scalinggroup**** |
The name of the scaling group. |
ScalingGroupName.1 | String | No | scalinggroup**** |
ScalingGroupName.1 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.2 | String | No | scalinggroup**** |
ScalingGroupName.2 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.3 | String | No | scalinggroup**** |
ScalingGroupName.3 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.4 | String | No | scalinggroup**** |
ScalingGroupName.4 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.5 | String | No | scalinggroup**** |
ScalingGroupName.5 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.6 | String | No | scalinggroup**** |
ScalingGroupName.6 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.7 | String | No | scalinggroup**** |
ScalingGroupName.7 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.8 | String | No | scalinggroup**** |
ScalingGroupName.8 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.9 | String | No | scalinggroup**** |
ScalingGroupName.9 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.10 | String | No | scalinggroup**** |
ScalingGroupName.10 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.11 | String | No | scalinggroup**** |
ScalingGroupName.11 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.12 | String | No | scalinggroup**** |
ScalingGroupName.12 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.13 | String | No | scalinggroup**** |
ScalingGroupName.13 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.14 | String | No | scalinggroup**** |
ScalingGroupName.14 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.15 | String | No | scalinggroup**** |
ScalingGroupName.15 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.16 | String | No | scalinggroup**** |
ScalingGroupName.16 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.17 | String | No | scalinggroup**** |
ScalingGroupName.17 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.18 | String | No | scalinggroup**** |
ScalingGroupName.18 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.19 | String | No | scalinggroup**** |
ScalingGroupName.19 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
ScalingGroupName.20 | String | No | scalinggroup**** |
ScalingGroupName.20 is the name of the scaling group that you want to query. The names of inactive scaling groups are not displayed in the query results, and no error is reported. |
GroupType | String | No | ECS |
The type of instances that are managed by the scaling group. Valid values:
Default value: ECS. |
ScalingGroupId.N | String | No | asg-bp14wlu85wrpchm0**** |
The ID of scaling group N that you want to query. Valid values of N: 1 to 20. The IDs of inactive scaling groups are not displayed in the query results, and no error is reported. |
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
RequestId | String | 473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E |
The ID of the request. |
PageNumber | Integer | 1 |
The page number of the returned page. |
PageSize | Integer | 10 |
The number of entries returned per page. |
TotalCount | Integer | 1 |
The total number of scaling groups. |
ScalingGroups | Array of ScalingGroup |
The details of the scaling groups. |
|
ScalingGroup | |||
VpcId | String | vpc-bp1vwnn14rqpyiczj**** |
The ID of the virtual private cloud (VPC) to which the scaling group belongs. |
CreationTime | String | 2014-08-14T10:58Z |
The time when the scaling group was created. |
TotalInstanceCount | Integer | 1 |
The total number of ECS instances in the scaling group. |
ScalingGroupName | String | dyrSuvBOtO1dEdIlIbp**** |
The name of the scaling group. |
SpotInstancePools | Integer | 5 |
The number of instance types that are available. Auto Scaling creates preemptible instances of multiple instance types that are provided at the lowest cost. Valid values: 0 to 10. |
StoppedCapacity | Integer | 1 |
The number of instances on which the Economical Mode feature is enabled in the scaling group. |
OnDemandPercentageAboveBaseCapacity | Integer | 20 |
The percentage of pay-as-you-go instances among the extra instances that exceed the number specified by OnDemandBaseCapacity. Valid values: 0 to 100. |
ModificationTime | String | 2014-08-14T10:58Z |
The time when the scaling group was modified. |
MinSize | Integer | 1 |
The minimum number of ECS instances in the scaling group. |
ScalingGroupId | String | asg-bp14wlu85wrpchm0**** |
The ID of the scaling group. |
CompensateWithOnDemand | Boolean | true |
Indicates whether pay-as-you-go instances can be automatically created to meet the required number of ECS instances when the expected number of preemptible instances cannot be met. The expected number of preemptible instances may not be met due to reasons such as high costs or insufficient resources. This parameter is valid only when MultiAZPolicy is set to COST_OPTIMIZED. Valid values:
|
ScalingPolicy | String | recycle |
The instance reclaim mode of the scaling group. Valid values:
For more information about how to remove instances, see RemoveInstances. |
RemovingWaitCapacity | Integer | 1 |
The number of ECS instances in the Pending Remove state in the scaling group. |
ActiveCapacity | Integer | 1 |
The number of ECS instances that are added to the scaling group and are running as expected. |
OnDemandBaseCapacity | Integer | 30 |
The minimum number of pay-as-you-go instances required in the scaling group. Valid values: 0 to 1000. If the number of pay-as-you-go instances is less than the value of this parameter, Auto Scaling preferentially creates pay-as-you-go instances. |
ProtectedCapacity | Integer | 1 |
The number of ECS instances that are in the Protected state in the scaling group. |
HealthCheckType | String | ECS |
Indicates whether to perform health checks on ECS instances in the scaling group. Valid values:
|
LifecycleState | String | Active |
The lifecycle status of the scaling group. Valid values:
|
GroupDeletionProtection | Boolean | true |
Indicates whether deletion protection is enabled for the scaling group. Valid values:
|
ActiveScalingConfigurationId | String | asc-bp1et2qekq3ojr33**** |
The ID of the active scaling configuration in the scaling group. |
GroupType | String | ECS |
The type of instances that are managed by the scaling group. |
MultiAZPolicy | String | PRIORITY |
The scaling policy for a multi-zone scaling group that contains ECS instances. Valid values:
|
RemovingCapacity | Integer | 0 |
The number of ECS instances that are being removed from the scaling group. |
PendingWaitCapacity | Integer | 1 |
The number of ECS instances that are in the Pending Add state in the scaling group. |
StandbyCapacity | Integer | 1 |
The number of instances that are in the Standby state in the scaling group. |
PendingCapacity | Integer | 0 |
The number of ECS instances that are being added to the scaling group and are also being configured. |
LaunchTemplateId | String | lt-m5e3ofjr1zn1aw7**** |
The ID of the launch template used by the scaling group. |
TotalCapacity | Integer | 1 |
If an instance type weight is specified for the scaling group, the value of this parameter indicates the total weighted capacity of all ECS instances in the scaling group. If no instance type weight is specified for the scaling group, the value of this parameter indicates the total number of ECS instances in the scaling group. |
DesiredCapacity | Integer | 5 |
The expected number of ECS instances in the scaling group. Auto Scaling automatically maintains the specified number of ECS instances. |
SpotInstanceRemedy | Boolean | true |
Indicates whether to supplement preemptible instances. If this parameter is set to true, Auto Scaling attempts to create an instance to replace a preemptible instance when Auto Scaling receives a system message which indicates that the preemptible instance is to be reclaimed. |
LaunchTemplateVersion | String | Default |
The version of the launch template used by the scaling group. |
RegionId | String | cn-qingdao |
The region ID of the scaling group. |
VSwitchId | String | vsw-bp1whw2u46cn8zubm**** |
The ID of the vSwitch that is associated with the scaling group. |
MaxSize | Integer | 2 |
The maximum number of ECS instances in the scaling group. |
DefaultCooldown | Integer | 60 |
The default cooldown time of the scaling group. During the cooldown time, Auto Scaling executes only the scaling activities that are triggered by event-triggered tasks associated with CloudMonitor. |
VServerGroups | Array of VServerGroup |
The list of backend server groups. |
|
VServerGroup | |||
LoadBalancerId | String | 147b46d767c-cn-qingdao-cm5**** |
The ID of the Server Load Balancer (SLB) instance to which the backend server group belongs. |
VServerGroupAttributes | Array of VServerGroupAttribute | ||
VServerGroupAttribute | |||
VServerGroupId | String | rsp-bp12bjrny**** |
The attributes of the backend server group. |
Weight | Integer | 1 |
The weight of the backend server group. |
Port | Integer | 22 |
The port number used by the SLB instance to provide external services. |
LaunchTemplateOverrides | Array of LaunchTemplateOverride |
The details of the instance type of the extended configurations. |
|
LaunchTemplateOverride | |||
WeightedCapacity | Integer | 4 |
The weight of the instance type. The value of this parameter indicates the capacity of a single instance of this instance type in the scaling group. A greater weight indicates that a smaller number of instances of the specified instance type are required to meet the expected capacity. |
InstanceType | String | ecs.c5.xlarge |
The instance type. The specified instance type overrides the instance type in the launch template. |
AlbServerGroups | Array of AlbServerGroup |
The details of the Application Load Balancer (ALB) server groups. |
|
AlbServerGroup | |||
AlbServerGroupId | String | sgp-ddwb0y0g6y9bjm**** |
The ID of the ALB server group. |
Weight | Integer | 100 |
The weight of the ECS instance as a backend server after the instance is added to the ALB server group. |
Port | Integer | 80 |
The port number used by the ECS instance after the instance is added to the ALB server group. |
RemovalPolicies | Array of String | OldestScalingConfiguration |
The policies that are used to remove ECS instances from the scaling group. Valid values:
|
DBInstanceIds | Array of String | rm-bp15556qzebg1**** |
The IDs of the ApsaraDB RDS instances that are associated with the scaling group. |
LoadBalancerIds | Array of String | lb-bp19byhscefk3x0li**** |
The IDs of the SLB instances that are associated with the scaling group. |
VSwitchIds | Array of String | vsw-bp1whw2u46cn8zubm**** |
The IDs of the vSwitches that are associated with the scaling group. If you configure the VSwitchIds parameter, the VSwitchId parameter is ignored. |
SuspendedProcesses | Array of String | ScaleIn |
The process that is suspended. If no process is suspended, null is returned. Valid values:
|
SystemSuspended | Boolean | true |
Indicates whether Auto Scaling stops executing scaling activities in the scaling group.
|
MonitorGroupId | String | 1497**** |
The ID of the CloudMonitor application group that is associated with the scaling group. |
Examples
Sample requests
http(s)://ess.aliyuncs.com/?Action=DescribeScalingGroups
&RegionId=cn-qingdao
&PageNumber=1
&PageSize=10
&<Common request parameters>
Sample success responses
XML
format
HTTP/1.1 200 OK
Content-Type:application/xml
<DescribeScalingGroupsResponse>
<RequestId>473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E</RequestId>
<PageNumber>1</PageNumber>
<PageSize>10</PageSize>
<TotalCount>1</TotalCount>
<ScalingGroups>
<VpcId>vpc-bp1vwnn14rqpyiczj****</VpcId>
<CreationTime>2014-08-14T10:58Z</CreationTime>
<TotalInstanceCount>1</TotalInstanceCount>
<ScalingGroupName>dyrSuvBOtO1dEdIlIbp****</ScalingGroupName>
<SpotInstancePools>5</SpotInstancePools>
<StoppedCapacity>1</StoppedCapacity>
<OnDemandPercentageAboveBaseCapacity>20</OnDemandPercentageAboveBaseCapacity>
<ModificationTime>2014-08-14T10:58Z</ModificationTime>
<MinSize>1</MinSize>
<ScalingGroupId>asg-bp14wlu85wrpchm0****</ScalingGroupId>
<CompensateWithOnDemand>true</CompensateWithOnDemand>
<ScalingPolicy>recycle</ScalingPolicy>
<RemovingWaitCapacity>1</RemovingWaitCapacity>
<ActiveCapacity>1</ActiveCapacity>
<OnDemandBaseCapacity>30</OnDemandBaseCapacity>
<ProtectedCapacity>1</ProtectedCapacity>
<HealthCheckType>ECS</HealthCheckType>
<LifecycleState>Active</LifecycleState>
<GroupDeletionProtection>true</GroupDeletionProtection>
<ActiveScalingConfigurationId>asc-bp1et2qekq3ojr33****</ActiveScalingConfigurationId>
<GroupType>ECS</GroupType>
<MultiAZPolicy>PRIORITY</MultiAZPolicy>
<RemovingCapacity>0</RemovingCapacity>
<PendingWaitCapacity>1</PendingWaitCapacity>
<StandbyCapacity>1</StandbyCapacity>
<PendingCapacity>0</PendingCapacity>
<LaunchTemplateId>lt-m5e3ofjr1zn1aw7****</LaunchTemplateId>
<TotalCapacity>1</TotalCapacity>
<DesiredCapacity>5</DesiredCapacity>
<SpotInstanceRemedy>true</SpotInstanceRemedy>
<LaunchTemplateVersion>Default</LaunchTemplateVersion>
<RegionId>cn-qingdao</RegionId>
<VSwitchId>vsw-bp1whw2u46cn8zubm****</VSwitchId>
<MaxSize>2</MaxSize>
<DefaultCooldown>60</DefaultCooldown>
<VServerGroups>
<LoadBalancerId>147b46d767c-cn-qingdao-cm5****</LoadBalancerId>
<VServerGroupAttributes>
<VServerGroupId>rsp-bp12bjrny****</VServerGroupId>
<Weight>1</Weight>
<Port>22</Port>
</VServerGroupAttributes>
</VServerGroups>
<LaunchTemplateOverrides>
<WeightedCapacity>4</WeightedCapacity>
<InstanceType>ecs.c5.xlarge</InstanceType>
</LaunchTemplateOverrides>
<AlbServerGroups>
<AlbServerGroupId>sgp-ddwb0y0g6y9bjm****</AlbServerGroupId>
<Weight>100</Weight>
<Port>80</Port>
</AlbServerGroups>
<RemovalPolicies>OldestScalingConfiguration</RemovalPolicies>
<DBInstanceIds>rm-bp15556qzebg1****</DBInstanceIds>
<LoadBalancerIds>lb-bp19byhscefk3x0li****</LoadBalancerIds>
<VSwitchIds>vsw-bp1whw2u46cn8zubm****</VSwitchIds>
<SuspendedProcesses>ScaleIn</SuspendedProcesses>
<SystemSuspended>true</SystemSuspended>
<MonitorGroupId>1497****</MonitorGroupId>
</ScalingGroups>
</DescribeScalingGroupsResponse>
JSON
format
HTTP/1.1 200 OK
Content-Type:application/json
{
"RequestId" : "473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E",
"PageNumber" : 1,
"PageSize" : 10,
"TotalCount" : 1,
"ScalingGroups" : [ {
"VpcId" : "vpc-bp1vwnn14rqpyiczj****",
"CreationTime" : "2014-08-14T10:58Z",
"TotalInstanceCount" : 1,
"ScalingGroupName" : "dyrSuvBOtO1dEdIlIbp****",
"SpotInstancePools" : 5,
"StoppedCapacity" : 1,
"OnDemandPercentageAboveBaseCapacity" : 20,
"ModificationTime" : "2014-08-14T10:58Z",
"MinSize" : 1,
"ScalingGroupId" : "asg-bp14wlu85wrpchm0****",
"CompensateWithOnDemand" : true,
"ScalingPolicy" : "recycle",
"RemovingWaitCapacity" : 1,
"ActiveCapacity" : 1,
"OnDemandBaseCapacity" : 30,
"ProtectedCapacity" : 1,
"HealthCheckType" : "ECS",
"LifecycleState" : "Active",
"GroupDeletionProtection" : true,
"ActiveScalingConfigurationId" : "asc-bp1et2qekq3ojr33****",
"GroupType" : "ECS",
"MultiAZPolicy" : "PRIORITY",
"RemovingCapacity" : 0,
"PendingWaitCapacity" : 1,
"StandbyCapacity" : 1,
"PendingCapacity" : 0,
"LaunchTemplateId" : "lt-m5e3ofjr1zn1aw7****",
"TotalCapacity" : 1,
"DesiredCapacity" : 5,
"SpotInstanceRemedy" : true,
"LaunchTemplateVersion" : "Default",
"RegionId" : "cn-qingdao",
"VSwitchId" : "vsw-bp1whw2u46cn8zubm****",
"MaxSize" : 2,
"DefaultCooldown" : 60,
"VServerGroups" : [ {
"LoadBalancerId" : "147b46d767c-cn-qingdao-cm5****",
"VServerGroupAttributes" : [ {
"VServerGroupId" : "rsp-bp12bjrny****",
"Weight" : 1,
"Port" : 22
} ]
} ],
"LaunchTemplateOverrides" : [ {
"WeightedCapacity" : 4,
"InstanceType" : "ecs.c5.xlarge"
} ],
"AlbServerGroups" : [ {
"AlbServerGroupId" : "sgp-ddwb0y0g6y9bjm****",
"Weight" : 100,
"Port" : 80
} ],
"RemovalPolicies" : [ "OldestScalingConfiguration" ],
"DBInstanceIds" : [ "rm-bp15556qzebg1****" ],
"LoadBalancerIds" : [ "lb-bp19byhscefk3x0li****" ],
"VSwitchIds" : [ "vsw-bp1whw2u46cn8zubm****" ],
"SuspendedProcesses" : [ "ScaleIn" ],
"SystemSuspended" : true,
"MonitorGroupId" : "1497****"
} ]
}
Error codes
For a list of error codes, visit the API Error Center.