All Products
Search
Document Center

Auto Scaling:ModifyScalingConfiguration

更新時間:Nov 11, 2024

Modifies a scaling configuration.

Operation description

  • If you want to change the name of a scaling configuration in a scaling group, make sure that the new name is unique within the scaling group.

  • If you want to bind a primary elastic network interface (ENI) when you call this operation, you must use one of the following methods. If you use the following methods at the same time, the call fails and an error is reported. In addition, if you use one of the following methods to modify the ENI information when you call this operation, the ENI information configured by using the other method is cleared.

    • You can specify SecurityGroupId, SecurityGroupIds, and Ipv6AddressCount to configure ENI-related information.
    • You can specify NetworkInterfaces to configure primary and secondary ENIs. You must use NetworkInterface to specify at least one primary ENI. If you set NetworkInterface.InstanceType to Primary, it specifies that a primary ENI is configured. If you set NetworkInterface.InstanceType to Secondary or leave it empty, it specifies that a secondary ENI is configured.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
ess:ModifyScalingConfigurationupdate
  • ScalingGroup
    acs:ess:{#regionId}:{#accountId}:scalinggroup/{#ScalingGroupId}
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
ScalingConfigurationIdstringYes

The ID of the scaling configuration that you want to modify.

asc-bp16har3jpj6fjbx****
IoOptimizedstringNo

Specifies whether to create I/O optimized instances from the scaling configuration. Valid values:

  • none: creates non-I/O optimized instances from the scaling configuration.
  • optimized: creates I/O optimized instances from the scaling configuration.
none
SpotStrategystringNo

The preemption policy of pay-as-you-go instances. Valid values:

  • NoSpot: The instances are created as regular pay-as-you-go instances.
  • SpotWithPriceLimit: The instances are preemptible instances that have a user-defined maximum hourly price.
  • SpotAsPriceGo: The instances are preemptible instances for which the market price at the time of purchase is automatically used as the bid price.
NoSpot
ScalingConfigurationNamestringNo

The name of the scaling configuration. The name must be 2 to 64 characters in length, and can contain letters, digits, underscores (_), hyphens (-), and periods (.). The name must start with a letter or a digit.

The name of the scaling configuration must be unique in a region. If you do not specify this parameter, the scaling configuration ID is used.

test-modify
InstanceNamestringNo

The name of the Elastic Compute Service (ECS) instance that is automatically created by using the scaling configuration.

inst****
HostNamestringNo

The hostname of the ECS instance. The hostname cannot start or end with a period (.) or a hyphen (-). The hostname cannot contain consecutive periods (.) or hyphens (-). Naming conventions for different types of instances:

  • Windows instances: The hostname must be 2 to 15 characters in length, and can contain letters, digits, and hyphens (-). The hostname cannot contain periods (.) or contain only digits.
  • Other instances, such as Linux instances: The hostname must be 2 to 64 characters in length. Separate a hostname into multiple segments with periods (.). Each segment can contain letters, digits, and hyphens (-).
hos****
ImageIdstringNo

The ID of the image that is used by Auto Scaling to automatically create ECS instances.

Note If the image that is specified in the scaling configuration contains system disks and data disks, the data that is stored in the data disks is cleared after you modify the image.
centos6u5_64_20G_aliaegis_2014****.vhd
ImageNamestringNo

The name of the image. Each image name must be unique in a region. If you specify ImageId, ImageName is ignored.

You cannot use ImageName to specify images from Alibaba Cloud Marketplace.

suse11sp3_64_20G_aliaegis_2015****.vhd
CpuintegerNo

The number of vCPUs.

You can specify the number of vCPUs and the memory size to determine the range of instance types. For example, you can set Cpu to 2 and Memory to 16 to specify instance types that have 2 vCPUs and 16 GiB of memory. If you specify Cpu and Memory, Auto Scaling determines the available instance types based on factors such as I/O optimization requirements and zones. Then, Auto Scaling preferentially creates instances by using the lowest-priced instance type.

Note You can specify CPU and Memory to determine the range of instance types only if you set Scaling Policy to Cost Optimization Policy and you do not specify an instance type in the scaling configuration.
2
MemoryintegerNo

The memory size. Unit: GiB.

You can specify the number of vCPUs and the memory size to determine the range of instance types. For example, you can set Cpu to 2 and Memory to 16 to specify instance types that have 2 vCPUs and 16 GiB of memory. If you specify Cpu and Memory, Auto Scaling determines the available instance types based on factors such as I/O optimization requirements and zones. Then, Auto Scaling preferentially creates instances by using the lowest-priced instance type.

Note You can specify CPU and Memory to determine the range of instance types only if you set Scaling Policy to Cost Optimization Policy and you do not specify an instance type in the scaling configuration.
16
InternetChargeTypestringNo

The billing method for network usage. Valid values:

  • PayByBandwidth: pay-by-bandwidth. You are charged for the bandwidth specified by InternetMaxBandwidthOut.
  • PayByTraffic: pay-by-traffic. You are charged for the actual traffic generated. InternetMaxBandwidthOut specifies only the maximum available bandwidth.
PayByBandwidth
InternetMaxBandwidthOutintegerNo

The maximum outbound public bandwidth. Unit: Mbit/s. Valid values:

  • If you set InternetChargeType to PayByBandwidth: 0 to 100. If you leave this parameter empty, this parameter is automatically set to 0.
  • If you set InternetChargeType to PayByTraffic: 0 to 100. If you leave this parameter empty, an error is returned.
50
SystemDisk.CategorystringNo

The category of the system disk. Valid values:

  • cloud: basic disk.
  • cloud_efficiency: ultra disk.
  • cloud_ssd: standard SSD.
  • cloud_essd: Enterprise SSD (ESSD).
  • ephemeral_ssd: local SSD.

If you specify SystemDisk.Category, you cannot specify SystemDiskCategories. If you do not specify SystemDisk.Category or SystemDiskCategories, the default value of SystemDisk.Category is used. The default value for non-I/O optimized instances of Generation I instance families is cloud. The default value for other instances is cloud_efficiency.

cloud_efficiency
SystemDisk.SizeintegerNo

The size of the system disk. Unit: GiB. Valid values:

  • If you set SystemDisk.Category to cloud: 20 to 500.
  • If you set SystemDisk.Category to cloud_efficiency: 20 to 500.
  • If you set SystemDisk.Category to cloud_ssd: 20 to 500.
  • If you set SystemDisk.Category to cloud_essd: 20 to 500.
  • If you set SystemDisk.Category to ephemeral_ssd: 20 to 500.

The value of SystemDisk.Size must be greater than or equal to max{20, ImageSize}.

50
SystemDisk.DiskNamestringNo

The name of the system disk. The name must be 2 to 128 characters in length, and can contain letters, digits, colons (:), underscores (_), and hyphens (-). The name must start with a letter but cannot start with http:// or https://.

Default value: null.

cloud_ssdSystem
SystemDisk.DescriptionstringNo

The description of the system disk. The description must be 2 to 256 characters in length. The description can contain letters but cannot start with http:// or https://.

Test system disk.
SystemDisk.AutoSnapshotPolicyIdstringNo

The ID of the automatic snapshot policy that you want to apply to the system disk.

sp-bp12m37ccmxvbmi5****
SystemDisk.PerformanceLevelstringNo

The performance level (PL) of the system disk that is an ESSD. Valid values:

  • PL0: An ESSD can provide up to 10,000 random read/write IOPS.
  • PL1: An ESSD can provide up to 50,000 random read/write IOPS.
  • PL2: An ESSD can provide up to 100,000 random read/write IOPS.
  • PL3: An ESSD can provide up to 1,000,000 random read/write IOPS.
Note For more information about how to select ESSD PLs, see ESSDs .
PL0
LoadBalancerWeightintegerNo

The weight of an ECS instance as a backend server. Valid values: 1 to 100.

50
UserDatastringNo

The user data of the Elastic Compute Service (ECS) instance. The user data must be encoded in Base64 format. The size of raw data before Base64 encoding cannot exceed 32 KB.

echo hello ecs!
KeyPairNamestringNo

The name of the key pair that you can use to log on to an ECS instance.

  • Windows instances do not support this parameter.
  • By default, the username and password authentication method is disabled for Linux instances.
KeyPair_Name
RamRoleNamestringNo

The name of the RAM role that you want to attach to the ECS instance. The name is provided and maintained by Resource Access Management (RAM). You can call the ListRoles operation to query the available RAM roles. You can call the CreateRole operation to create RAM roles.

RamRoleTest
PasswordInheritbooleanNo

Specifies whether to use the password that is preconfigured in the image. Before you use this parameter, make sure that a password is configured in the image.

false
TagsstringNo

The tags of the ECS instance. Specify the tags as key-value pairs. You can specify up to 20 tags. When you specify tag keys and tag values, take note of the following items:

  • A tag key can be up to 64 characters in length. The key cannot start with acs: or aliyun, and cannot contain http:// or https://. The tag key cannot be an empty string.
  • A tag value can be up to 128 characters in length. The value cannot start with acs: or aliyun, and cannot contain http:// or https://. The tag value can be an empty string.
{"key1":"value1","key2":"value2", ... "key5":"value5"}
DeploymentSetIdstringNo

The ID of the deployment set of the ECS instances that are created by using the scaling configuration.

ds-bp13v7bjnj9gis****
SecurityGroupIdstringNo

The ID of the security group with which ECS instances are associated. The ECS instances that are associated with the same security group can access each other.

sg-F876F****
OverridebooleanNo

Specifies whether to override existing data. Valid values:

  • true
  • false
true
ResourceGroupIdstringNo

The ID of the resource group to which the ECS instances belong.

abcd1234abcd****
HpcClusterIdstringNo

The ID of the Elastic High Performance Computing (E-HPC) cluster to which the ECS instances belong.

hpc-clusterid
InstanceDescriptionstringNo

The description of the ECS instance. The description must be 2 to 256 characters in length. The description can contain letters but cannot start with http:// or https://.

Test instance.
Ipv6AddressCountintegerNo

The number of randomly generated IPv6 addresses that you want to allocate to the elastic network interface (ENI).

1
CreditSpecificationstringNo

The performance mode of burstable instances. Valid values:

Standard
ImageFamilystringNo

The name of the image family. If you specify this parameter, the latest custom images that are available in the specified image family are returned. Then, you can use the images to create instances. If you specify ImageId, you cannot specify ImageFamily.

hangzhou-daily-update
ZoneIdstringNo

The zone ID of the ECS instances that are created by using the scaling configuration.

cn-hangzhou-g
DedicatedHostIdstringNo

The ID of the dedicated host on which you want to create ECS instances. You cannot create preemptible instances on dedicated hosts. If you specify DedicatedHostId, SpotStrategy and SpotPriceLimit are ignored.

You can call the DescribeDedicatedHosts operation to query the most recent list of dedicated host IDs.

dh-bp67acfmxazb4p****
AffinitystringNo

Specifies whether to associate the instance on a dedicated host with the dedicated host. Valid values:

  • default: does not associate the instance on the dedicated host with the dedicated host. If you restart an instance that was stopped in Economical Mode and the original dedicated host of the instance has insufficient resources, the instance is automatically deployed to another dedicated host in the automatic deployment resource pool.
  • host: associates the instance on a dedicated host with the dedicated host. If you restart an instance that was stopped in Economical Mode, the instance remains on the original dedicated host. If the original dedicated host has insufficient resources, the instance cannot be started.
default
TenancystringNo

Specifies whether to create ECS instances on dedicated hosts. Valid values:

  • default: creates ECS instances on non-dedicated hosts.
  • host: creates ECS instances on dedicated hosts. If you do not specify DedicatedHostId, the system randomly selects a dedicated host for an ECS instance.
default
SchedulerOptionsobjectNo

The scheduler options.

["testManagedPrivateSpaceId****"]
PrivatePoolOptions.MatchCriteriastringNo

The type of the private pool that you want to use to start ECS instances. A private pool is generated when an elasticity assurance or a capacity reservation takes effect. You can specify a private pool for Auto Scaling to start ECS instances. Valid values:

  • Open: open private pool. Auto Scaling selects a matching open private pool to start ECS instances. If no matching open private pools exist, the resources in the public pool are used. In this case, you do not need to specify PrivatePoolOptions.Id.
  • Target: specified private pool. Auto Scaling uses the resources in the specified private pool to start ECS instances. If the specified private pool does not exist, Auto Scaling cannot start ECS instances. If you set this parameter to Target, you must specify PrivatePoolOptions.Id.
  • None: no private pool. Auto Scaling does not use the resources of private pools to start ECS instances.
Open
PrivatePoolOptions.IdstringNo

The ID of the private pool. The ID of a private pool is the same as the ID of the elasticity assurance or capacity reservation for which the private pool is generated.

eap-bp67acfmxazb4****
SpotDurationintegerNo

The protection period of preemptible instances. Unit: hours. Valid values:

  • 1: After a preemptible instance is created, Alibaba Cloud ensures that the instance is not automatically released within 1 hour. After the 1-hour protection period ends, Alibaba Cloud compares the bidding price with the market price and checks the resource inventory to determine whether to release the instance.
  • 0: After a preemptible instance is created, Alibaba Cloud does not ensure that the instance is not automatically released within 1 hour. Alibaba Cloud compares the biding price with the market price and checks the resource inventory to determine whether to release the instance.
Note Alibaba Cloud notifies you of ECS system events 5 minutes before an instance is released. Preemptible instances are billed by second. We recommend that you specify a protection period based on your business requirements.

Default value: 1.

1
SpotInterruptionBehaviorstringNo

The interruption mode of the preemptible instance. Default value: Terminate. Set the value to Terminate. This value specifies that the preemptible instance is to be released.

Terminate
DataDisksarray<object>No

The data disks.

objectNo

The data disk.

PerformanceLevelstringNo

The PL of the data disk that is an ESSD. Valid values:

  • PL0: An ESSD can provide up to 10,000 random read/write IOPS.
  • PL1: An ESSD can provide up to 50,000 random read/write IOPS.
  • PL2: An ESSD can provide up to 100,000 random read/write IOPS.
  • PL3: An ESSD can provide up to 1,000,000 random read/write IOPS.
Note For more information about how to select ESSD PLs, see ESSDs .
PL1
AutoSnapshotPolicyIdstringNo

The ID of the automatic snapshot policy that you want to apply to the data disk.

sp-bp19nq9enxqkomib****
EncryptedstringNo

Specifies whether to encrypt the system disk. Valid values:

  • true
  • false
false
DescriptionstringNo

The description of the system disk. The description must be 2 to 256 characters in length, and cannot start with http:// or https://.

Test data disk.
SnapshotIdstringNo

The ID of the snapshot that you want to use to create data disks. If you specify this parameter, DataDisk.Size is ignored. The size of the data disk created by using the snapshot is the same as the size of the snapshot.

If the snapshot was created on or before July 15, 2013, the API request is rejected and the InvalidSnapshot.TooOld message is returned.

s-snapshot****
CategoriesarrayNo

The categories of data disks. Valid values:

  • cloud: basic disk. The DeleteWithInstance attribute of a basic disk created along with each ECS instance is set to true.
  • cloud_efficiency: ultra disk.
  • cloud_ssd: standard SSD.
  • cloud_essd: ESSD.
Note If you specify this parameter, you cannot specify DataDisk.Category.
stringNo

The category of the data disk. If Auto Scaling cannot create instances by using the disk whose category has the highest priority, Auto Scaling creates instances by using the disk whose category has the next highest priority. Valid values:

  • cloud: basic disk. The DeleteWithInstance attribute of a basic disk created along with each ECS instance is set to true.
  • cloud_efficiency: ultra disk.
  • cloud_ssd: standard SSD.
  • cloud_essd: ESSD.
Note If you specify this parameter, you cannot specify DataDisk.Category.
cloud
SizeintegerNo

The size of the data disk. Unit: GB. Valid values:

  • 5 to 2000 if you set DataDisk.Category to cloud.
  • 20 to 32768 if you set DataDisk.Category to cloud_efficiency.
  • 20 to 32768 if you set DataDisk.Category to cloud_ssd.
  • 20 to 32768 if you set DataDisk.Category to cloud_essd.
  • 5 to 800 if you set DataDisk.Category to ephemeral_ssd.

Set Size to a value that is greater than or equal to the size of the snapshot specified by SnapshotId.

100
DevicestringNo

The mount target of the data disk. If you do not specify this parameter, the system automatically assigns a mount target when Auto Scaling creates an ECS instance. Valid values: /dev/xvdb to /dev/xvdz.

/dev/xvdd
DiskNamestringNo

The name of the system disk. The name must be 2 to 128 characters in length, and can contain letters, digits, colons (:), underscores (_), and hyphens (-). The name must start with a letter but cannot start with http:// or https://.

cloud_ssdData
CategorystringNo

The category of the data disk. Valid values:

  • cloud: basic disk. The DeleteWithInstance attribute of a basic disk created along with each ECS instance is set to true.
  • cloud_efficiency: ultra disk.
  • cloud_ssd: standard SSD.
  • ephemeral_ssd: local SSD.
  • cloud_essd: ESSD.

If you specify this parameter, you cannot specify DataDisk.Categories. If you leave this parameter and DataDisk.Categories empty at the same time, the default value of this parameter is used.

  • For I/O optimized instances, the default value is cloud_efficiency.
  • For non-I/O optimized instances, the default value is cloud.
cloud_ssd
DeleteWithInstancebooleanNo

Specifies whether to release the data disk if the instance to which the data disk is attached is released. Valid values:

  • true
  • false

If you set DataDisk.Category to cloud, cloud_efficiency, cloud_ssd, cloud_essd, or cloud_auto, you can specify this parameter. If you specify this parameter for data disks of other categories, an error is returned.

true
KMSKeyIdstringNo

The ID of the Key Management Service (KMS) key that you want to apply to the data disk.

0e478b7a-4262-4802-b8cb-00d3fb40****
ProvisionedIopslongNo

The provisioned IOPS of the data disk.

Note IOPS measures the number of read and write operations that an Elastic Block Storage (EBS) device can process per second.
100
BurstingEnabledbooleanNo

Specifies whether to enable the Burst feature for the system disk. Valid values:

  • true
  • false
Note If you set SystemDisk.Category to cloud_auto, you can specify this parameter.
false
SpotPriceLimitsarray<object>No

The preemptible instance types.

objectNo

The preemptible instance type.

PriceLimitfloatNo

The price limit of the preemptible instance. This parameter takes effect only if you set SpotStrategy to SpotWithPriceLimit.

0.125
InstanceTypestringNo

The instance type of the preemptible instance. This parameter takes effect only if you set SpotStrategy to SpotWithPriceLimit.

ecs.g6.large
InstanceTypesarrayNo

The instance type. If you specify InstanceTypes, InstanceType is ignored.

Auto Scaling creates instances based on the priorities of instance types. If Auto Scaling cannot create instances by using the instance type that has the highest priority, Auto Scaling creates instances by using the instance type that has the next highest priority.

stringNo

The instance type. If you specify InstanceTypes, InstanceType is ignored.

Auto Scaling creates instances based on the priorities of instance types. If Auto Scaling cannot create instances by using the instance type that has the highest priority, Auto Scaling creates instances by using the instance type that has the next highest priority.

ecs.g6.large
InstanceTypeOverridesarray<object>No

The instance types.

objectNo

The instance type.

InstanceTypestringNo

The instance type. If you want to specify the capacity of instance types in the scaling configuration, specify InstanceType and WeightedCapacity at the same time.

You can use InstanceType to specify multiple instance types and WeightedCapacity to specify the weights of the instance types.

Note If you specify InstanceType, you cannot specify InstanceTypes.

You can use InstanceType to specify only instance types that are available for purchase.

ecs.c5.xlarge
WeightedCapacityintegerNo

The weight of the instance type. The weight specifies the capacity of an instance of the specified instance type in the scaling group. If you want Auto Scaling to scale instances in the scaling group based on the weighted capacity of the instances, specify WeightedCapacity after you specify InstanceType.

A higher weight specifies that a smaller number of instances of the specified instance type are required to meet the expected capacity requirement.

Performance metrics, such as the number of vCPUs and the memory size of each instance type, may vary. You can specify different weights for different instance types based on your business requirements.

Example:

  • Current capacity: 0
  • Expected capacity: 6
  • Capacity of ecs.c5.xlarge: 4

To meet the expected capacity requirement, Auto Scaling must create and add two ecs.c5.xlarge instances.

Note The capacity of the scaling group cannot exceed the sum of the maximum number of instances that is specified by MaxSize and the maximum weight of the instance types.

Valid values of WeightedCapacity: 1 to 500.

4
SecurityGroupIdsarrayNo

The IDs of the security groups.

stringNo

The ID of the security group.

sg-bp18kz60mefs****
InstancePatternInfosarray<object>No

The information about the intelligent configuration settings, which determine the available instance types.

objectNo

The information about the intelligent configuration setting, which determines the available instance types.

CoresintegerNo

The number of vCPUs per instance type in intelligent configuration mode. You can specify this parameter to filter the available instance types. For more information, see Overview of instance families.

Before you specify this parameter, take note of the following items:

  • You can specify InstancePatternInfo only if your scaling group resides in a virtual private cloud (VPC).
  • If you specify InstancePatternInfo, you must also specify InstancePatternInfo.Cores and InstancePatternInfo.Memory.
  • Auto Scaling preferentially uses the instance type specified by InstanceType or InstanceTypes to create instances. If the specified instance type does not have sufficient inventory, Auto Scaling selects the lowest-priced instance type specified by InstancePatternInfo to create instances.
2
InstanceFamilyLevelstringNo

The level of the instance family. You can specify this parameter to filter the available instance types. This parameter takes effect only if you set CostOptimization to true. Valid values:

  • EntryLevel: entry level (shared instance type). Instance types of this level are the most cost-effective but may not provide stable computing performance. Instance types of this level are suitable for scenarios in which the CPU utilization is low. For more information, see Shared instance families.
  • EnterpriseLevel: enterprise level. Instance types of this level provide stable performance and dedicated resources, and are suitable for business scenarios in which high stability is required. For more information, see Overview of instance families.
  • CreditEntryLevel: credit-based entry level (burstable instance types). CPU credits are used to ensure computing performance. Instance types of this level are suitable for scenarios in which the CPU utilization is low but may fluctuate in specific cases. For more information, see Overview of burstable instances.
EnterpriseLevel
MaxPricefloatNo

The maximum hourly price of pay-as-you-go or preemptible instances in intelligent configuration mode. You can specify this parameter to filter the available instance types.

Note If you set SpotStrategy to SpotWithPriceLimit, you must specify this parameter. In other cases, this parameter is optional.
2
MemoryfloatNo

The memory size per instance type in intelligent configuration mode. Unit: GiB. You can specify this parameter to filter the available instance types.

4
ArchitecturesarrayNo

The architectures of instance types. Valid values:

  • X86: x86.
  • Heterogeneous: heterogeneous computing, such as GPU-accelerated or FPGA-accelerated.
  • BareMetal: ECS Bare Metal Instance.
  • Arm: Arm.
  • SuperComputeCluster: Super Computing Cluster.

By default, all values are included.

stringNo

The architecture of the instance type. Valid values:

  • X86: x86.
  • Heterogeneous: heterogeneous computing, such as GPU-accelerated or FPGA-accelerated.
  • BareMetal: ECS Bare Metal Instance.
  • Arm: Arm.
  • SuperComputeCluster: Super Computing Cluster.

By default, all values are included.

X86
BurstablePerformancestringNo

Specifies whether to include burstable instance types. Valid values:

  • Exclude: does not include burstable instance types.
  • Include: includes burstable instance types.
  • Required: includes only burstable instance types.

Default value: Include.

Include
ExcludedInstanceTypesarrayNo

The instance types that you want to exclude. You can use wildcard characters, such as an asterisk (*), to exclude an instance type or an instance family. Examples:

  • ecs.c6.large: excludes the ecs.c6.large instance type.
  • ecs.c6.*: excludes the c6 instance family.
stringNo

The instance type that you want to exclude. You can use wildcard characters, such as an asterisk (*), to exclude an instance type or an instance family. Examples:

  • ecs.c6.large: excludes the ecs.c6.large instance type.
  • ecs.c6.*: excludes the c6 instance family.
ecs.n1.small/ecs.n1.*/*7*
InstanceTypeFamiliesarrayNo

The instance families that you want to specify. You can specify up to 10 instance families in each call.

stringNo

The instance family that you want to specify. You can specify 1 to 10 instance families in each call.

ecs.g6
MinimumCpuCoreCountintegerNo

The minimum number of vCPUs per instance type.

2
MaximumCpuCoreCountintegerNo

The maximum number of vCPUs per instance type.

Note The value of MaximumCpuCoreCount cannot exceed four times the value of MinimumCpuCoreCount.
4
GpuSpecsarrayNo

The GPU models.

stringNo

The GPU model.

NVIDIA V100
InstanceCategoriesarrayNo

The categories of instance types. Valid values:

  • General-purpose
  • Compute-optimized
  • Memory-optimized
  • Big data
  • Local SSDs
  • High Clock Speed
  • Enhanced
  • Shared
  • Compute-optimized with GPU
  • Visual Compute-optimized
  • Heterogeneous Service
  • Compute-optimized with FPGA
  • Compute-optimized with NPU
  • ECS Bare Metal
  • Super Computing Cluster
  • High Performance Compute
stringNo

The category of the instance type. Valid values:

  • General-purpose
  • Compute-optimized
  • Memory-optimized
  • Big data
  • Local SSDs
  • High Clock Speed
  • Enhanced
  • Shared
  • Compute-optimized with GPU
  • Visual Compute-optimized
  • Heterogeneous Service
  • Compute-optimized with FPGA
  • Compute-optimized with NPU
  • ECS Bare Metal
  • Super Computing Cluster
  • High Performance Compute
Compute-optimized with GPU
CpuArchitecturesarrayNo

The CPU architectures of instance types. Valid values:

Note You can specify up to two CPU architectures.
  • x86
  • Arm
stringNo

The CPU architecture of the instance type. Valid values:

Note You can specify up to two CPU architectures.
  • x86
  • Arm
X86
PhysicalProcessorModelsarrayNo

The processor models of instance types. You can specify up to 10 processor models.

stringNo

The processor model of the instance type. You can specify up to 10 processor models.

Intel Xeon(Ice Lake) Platinum 8369B
MinimumEniQuantityintegerNo

The minimum number of elastic network interfaces (ENIs) per instance.

2
MinimumEniPrivateIpAddressQuantityintegerNo

The minimum number of IPv4 addresses per ENI.

2
MinimumEniIpv6AddressQuantityintegerNo

The minimum number of IPv6 addresses per ENI.

1
MinimumInitialCreditintegerNo

The initial vCPU credits per t5 or t6 burstable instance.

12
MinimumBaselineCreditintegerNo

The baseline vCPU computing performance (overall baseline performance of all vCPUs) per t5 or t6 burstable instance.

12
MinimumMemorySizefloatNo

The minimum memory size per instance. Unit: GiB.

4
MaximumMemorySizefloatNo

The maximum memory size per instance. Unit: GiB.

4
MinimumGpuAmountintegerNo

The minimum number of GPUs per instance. The value must be a positive integer.

2
MaximumGpuAmountintegerNo

The maximum number of GPUs per instance. The value must be a positive integer.

2
SystemDiskCategoriesarrayNo

The categories of the system disks. If Auto Scaling cannot create disks by using the disk category of the highest priority, Auto Scaling creates disks by using the disk category of the next highest priority. Valid values:

  • cloud: basic disk.
  • cloud_efficiency: ultra disk.
  • cloud_ssd: standard SSD.
  • cloud_essd: ESSD.
Note If you specify this parameter, you cannot specify SystemDisk.Category.
stringNo

The category of the system disk. If Auto Scaling cannot create disks by using the disk category of the highest priority, Auto Scaling creates disks by using the disk category of the next highest priority. Valid values:

  • cloud: basic disk.
  • cloud_efficiency: ultra disk.
  • cloud_ssd: standard SSD.
  • cloud_essd: ESSD.
Note If you specify this parameter, you cannot specify SystemDisk.Category.
cloud
PasswordstringNo

The password of the ECS instance. The password must be 8 to 30 characters in length and contain at least three of the following character types: uppercase letters, lowercase letters, digits, and special characters. The following special characters are supported:

`()~!@#$%^&*-_+=|{}[]:;'<>,.?/

The password of a Windows instance cannot start with a forward slash (/).

Note We recommend that you use HTTPS to send requests if you specify Password to avoid password leakage.
123abc****
SystemDisk.EncryptedbooleanNo

Specifies whether to encrypt the system disk. Valid values:

  • true
  • false

Default value: false.

false
SystemDisk.KMSKeyIdstringNo

The ID of the KMS key that you want to use to encrypt the system disk.

0e478b7a-4262-4802-b8cb-00d3fb40****
SystemDisk.EncryptAlgorithmstringNo

The encryption algorithm of the system disk. Valid values:

  • AES-256
  • SM4-128

Default value: AES-256.

AES-256
SystemDisk.ProvisionedIopslongNo

The IOPS metric that is preconfigured for the system disk.

Note IOPS measures the number of read and write operations that an EBS device can process per second.
100
SystemDisk.BurstingEnabledbooleanNo

Specifies whether to enable the Burst feature for the system disk. Valid values:

  • true
  • false
Note If you set SystemDisk.Category to cloud_auto, you can specify this parameter.
false
ImageOptions.LoginAsNonRootbooleanNo

Specifies whether to use ecs-user to log on to an ECS instance created from the scaling configuration. For information about logon usernames, see Manage the logon username of an instance. Valid values:

true

false

false
DeletionProtectionbooleanNo

Specifies whether to enable the Release Protection feature for ECS instances. If you enable this feature, you cannot directly release the ECS instances in the ECS console or by calling the DeleteInstance operation. Valid values:

  • true: enables the Release Protection feature. In this case, you cannot directly release the ECS instances in the ECS console or by calling the DeleteInstance operation.
  • false: disables the Release Protection feature. In this case, you can directly release the ECS instances in the ECS console or by calling the DeleteInstance operation.
Note You can enable the Release Protection feature only for pay-as-you-go instances to prevent accidental instance deletion. The Release Protection feature does not affect normal scaling activities. An instance that meets the criteria of scale-in policies can be removed from a scaling group during a scale-in event, regardless of whether you enabled the Release Protection feature for the instance.
false
CustomPrioritiesarray<object>No

The priority of the custom ECS instance type + vSwitch combination.

Note This setting is valid only if the scaling policy of the scaling group is a priority policy.

If Auto Scaling cannot create ECS instances by using the custom ECS instance type + vSwitch combination of the highest priority, Auto Scaling creates ECS instances by using the custom ECS instance type + vSwitch combination of the next highest priority.

Note If you specify the priorities of only a part of custom ECS instance type + vSwitch combinations, Auto Scaling preferentially creates ECS instances by using the custom combinations that have the specified priorities. If the custom combinations that have the specified priorities do not provide sufficient resources, Auto Scaling creates ECS instances by using the custom combinations that do not have the specified priorities based on the specified orders of vSwitches and instance types.
  • Example: The specified order of vSwitches for your scaling group is vsw1 and vsw2, and the specified order of instance types in your scaling configuration is type1 and type 2. In addition, you use CustomPriorities to specify ["vsw2+type2", "vsw1+type2"]. In this example, the vsw2+type2 combination has the highest priority and the vsw2+type1 combination has the lowest priority. The vsw1+type2 combination has a higher priority than the vsw1+type1 combination.
objectNo
InstanceTypestringNo

The ECS instance type.

Note The ECS instance type must be included in the instance types specified in the scaling configuration.
ecs.c6a.4xlarge
VswitchIdstringNo

The vSwitch ID.

Note The vSwitch must be included in the vSwitch list of the scaling group.
vsw-bp14zolna43z266bq****
NetworkInterfacesarray<object>No

The ENIs.

objectNo

The ENI.

InstanceTypestringNo

The ENI type. If you specify this parameter, you must use NetworkInterfaces to specify a primary ENI. In addition, you cannot specify SecurityGroupId or SecurityGroupIds. Valid values:

  • Primary: the primary ENI.
  • Secondary: the secondary ENI.

Default value: Secondary.

Primary
NetworkInterfaceTrafficModestringNo

The communication mode of the ENI. Valid values:

  • Standard: uses the TCP communication mode.
  • HighPerformance: uses the remote direct memory access (RDMA) communication mode with Elastic RDMA Interface (ERI) enabled.

Default value: Standard.

Note The number of ERIs on an instance cannot exceed the maximum number of ERIs supported by the instance type. For more information, see Overview of instance families.
HighPerformance
Ipv6AddressCountintegerNo

The number of randomly generated IPv6 addresses that you want to allocate to the primary ENI. Before you specify this parameter, take note of the following items:

This parameter takes effect only if you set NetworkInterface.InstanceType to Primary. If you set NetworkInterface.InstanceType to Secondary or leave it empty, you cannot specify this parameter.

After you specify this parameter, you can no longer specify Ipv6AddressCount.

1
SecurityGroupIdsarrayNo

The IDs of the security groups to which you want to assign the ENI.

stringNo

The ID of the security group to which you want to assign the ENI. Before you specify this parameter, take note of the following items:

  • If you set NetworkInterface.InstanceType to Primary, you must also specify this parameter. This parameter has the same effect as SecurityGroupIds. You can specify only SecurityGroupId or SecurityGroupIds.
  • If you set NetworkInterface.InstanceType to Secondary or leave it empty, this parameter is optional. By default, the primary ENI and the ECS instances created from the scaling configuration share the same security group.
sg-2ze55shrxxxxx
DedicatedHostClusterIdstringNo

The ID of the dedicated host cluster.

dc-zm04u8r3lohsq****
SecurityOptionsobjectNo
ConfidentialComputingModestringNo

The confidential computing mode. Valid values:

TDX

Response parameters

ParameterTypeDescriptionExample
object

The information that is returned.

RequestIdstring

The ID of the request.

473469C7-AA6F-4DC5-B3DB-A3DC0DE3****

Examples

Sample success responses

JSONformat

{
  "RequestId": "473469C7-AA6F-4DC5-B3DB-A3DC0DE3****"
}

Error codes

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
2024-11-08The request parameters of the API has changedView Change Details
2024-10-10The request parameters of the API has changedView Change Details
2024-06-12The internal configuration of the API is changed, but the call is not affectedView Change Details
2024-04-23The request parameters of the API has changedView Change Details
2024-03-20The request parameters of the API has changedView Change Details
2024-01-29The request parameters of the API has changedView Change Details
2023-11-24The request parameters of the API has changedView Change Details
2023-08-23The request parameters of the API has changedView Change Details
2023-04-12The request parameters of the API has changedView Change Details