Creates an auto provisioning group.
Operation description
Auto provisioning is a solution that uses spot instances and pay-as-you-go instances to quickly deploy instance clusters. It supports one-click deployment of instance clusters across billing methods, zones, and instance families. For more information, see Use the auto provisioning group API to create ECS instances in batches.
Auto provisioning uses provisioning groups to schedule and maintain compute resources. You can use an auto provisioning group to steadily provide computing power and mitigate the instability caused by the reclaim mechanism of spot instances.
Auto provisioning is a free feature, but you are charged for the instance resources created by the auto provisioning group. For more information, see Spot instance billing and Pay-as-you-go.
If you specify both a launch template (
LaunchTemplateId) and launch configuration information (LaunchConfiguration.*), the launch template takes precedence.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
ecs:CreateAutoProvisioningGroup |
create |
*All Resource
|
None |
|
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| RegionId |
string |
Yes |
The ID of the region in which the auto provisioning group resides. You can invoke DescribeRegions to query the most recent region list. |
cn-hangzhou |
| ResourceGroupId |
string |
No |
The ID of the resource group to which the auto provisioning group belongs. |
rg-bp67acfmxazb4p**** |
| AutoProvisioningGroupName |
string |
No |
The name of the auto provisioning group. The name must be 2 to 128 characters in length. It must start with a letter or a Chinese character and cannot start with |
apg-test |
| AutoProvisioningGroupType |
string |
No |
The delivery type of the auto provisioning group. Valid values:
Default value: maintain. |
maintain |
| SpotAllocationStrategy |
string |
No |
The policy for creating spot instances. Valid values:
Default value: lowest-price. |
diversified |
| SpotInstanceInterruptionBehavior |
string |
No |
The action to take when a spot instance is interrupted. Valid values:
Default value: terminate. |
terminate |
| SpotInstancePoolsToUseCount |
integer |
No |
Takes effect when Valid values: less than the value of N in |
2 |
| PayAsYouGoAllocationStrategy |
string |
No |
The policy for creating pay-as-you-go instances. Valid values:
Default value: lowest-price. |
prioritized |
| ExcessCapacityTerminationPolicy |
string |
No |
Specifies whether to release instances when the real-time capacity of the auto provisioning group exceeds the target capacity and a scale-in event is triggered. Valid values:
Default value: no-termination. |
termination |
| ValidFrom |
string |
No |
The time when the auto provisioning group is started. Used together with Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC+0. Default value: the UNIX timestamp at which the request takes effect immediately. |
2019-04-01T15:10:20Z |
| ValidUntil |
string |
No |
The time when the auto provisioning group expires. Used together with Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC+0. Default value: 2099-12-31T23:59:59Z. |
2019-06-01T15:10:20Z |
| TerminateInstancesWithExpiration |
boolean |
No |
Specifies whether to release instances auto provisioning group when the auto-provisioning group expires. Valid values:
Default value: false. |
true |
| TerminateInstances |
boolean |
No |
Specifies whether to release instances auto provisioning group when the auto-provisioning group is deleted. Valid values:
Default value: false. |
true |
| MaxSpotPrice |
number |
No |
The maximum price for spot instances in the auto provisioning group. Note
If both |
2 |
| TotalTargetCapacity |
string |
Yes |
The total target capacity of the auto provisioning group. Valid values: positive integers. The total capacity must be greater than or equal to the sum of |
60 |
| PayAsYouGoTargetCapacity |
string |
No |
The target capacity of pay-as-you-go instances in the auto provisioning group. Valid values: less than or equal to the parameter value of |
30 |
| SpotTargetCapacity |
string |
No |
The target capacity of spot instances in the auto provisioning group. Valid values: less than or equal to the parameter value of |
20 |
| DefaultTargetCapacityType |
string |
No |
The billing method for the capacity difference when the sum of
Default value: Spot. |
Spot |
| LaunchTemplateId |
string |
No |
The ID of the instance launch template associated with the auto provisioning group. You can invoke DescribeLaunchTemplates to query active instance launch templates. If you specify both a launch template and launch configuration information ( |
lt-bp1fgzds4bdogu03**** |
| LaunchTemplateVersion |
string |
No |
The version of the instance launch template associated with the auto provisioning group. You can invoke DescribeLaunchTemplateVersions to query active instance launch template versions. Default value: the default version of the launch template. |
1 |
| Description |
string |
No |
The description of the auto provisioning group. |
testDescription |
| ClientToken |
string |
No |
The client token that is used to ensure the idempotence of the request. You can use the client to generate the token, but make sure that the token is unique among different requests. The token can contain only ASCII characters and cannot exceed 64 characters in length. For more information, see How to ensure idempotence. |
0c593ea1-3bea-11e9-b96b-88e9fe637760 |
| LaunchConfiguration.ImageId |
string |
No |
The ID of the image used to launch instances. You can call DescribeImages to query available image resources. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
m-bp1g7004ksh0oeuc**** |
| LaunchConfiguration.SecurityGroupId |
string |
No |
The ID of the security group to which the instance belongs. If both a launch template and launch configuration information are specified, the launch template takes precedence. |
sg-bp15ed6xe1yxeycg**** |
| LaunchConfiguration.IoOptimized |
string |
No |
Specifies whether the instance is an I/O optimized instance. Valid values:
For retired instance types, the default value is none. For other instance types, the default value is optimized. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
optimized |
| LaunchConfiguration.InternetChargeType |
string |
No |
The billing method for network usage. Valid values:
Note
In pay-by-traffic mode, the peak inbound and outbound bandwidths are used as upper limits of bandwidths instead of guaranteed performance metrics. When resources are contended, the peak bandwidths may be limited. If you require guaranteed bandwidth, use pay-by-bandwidth. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
PayByTraffic |
| LaunchConfiguration.InternetMaxBandwidthIn |
integer |
No |
The maximum inbound public bandwidth. Unit: Mbit/s. Valid values:
If you specify both a launch template and launch configuration information, the launch template takes precedence. |
10 |
| LaunchConfiguration.InternetMaxBandwidthOut |
integer |
No |
The maximum outbound public bandwidth. Unit: Mbit/s. Valid values: 0 to 100. Default value: 0. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
10 |
| LaunchConfiguration.InstanceName |
string |
No |
The name of the instance. The name must be 2 to 128 characters in length. It must start with a letter or a Chinese character and cannot start with Default value: the When you create multiple ECS instances, you can batch configure sequential instance names. For more information, see Batch configure sequential names or hostnames for multiple instances. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
k8s-node-[1,4]-alibabacloud |
| LaunchConfiguration.HostName |
string |
No |
The hostname of the instance. The following limits apply:
|
k8s-node-[1,4]-ecshost |
| LaunchConfiguration.InstanceDescription |
string |
No |
The description of the instance. The description must be 2 to 256 characters in length and cannot start with |
Instance_Description |
| LaunchConfiguration.KeyPairName |
string |
No |
The name of the key pair.
If you specify both a launch template and launch configuration information, the launch template takes precedence. |
KeyPair_Name |
| LaunchConfiguration.RamRoleName |
string |
No |
The name of the instance RAM role. You can call the RAM API ListRoles to query the instance RAM roles that you have created. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
RAM_Name |
| LaunchConfiguration.SecurityEnhancementStrategy |
string |
No |
Specifies whether to enable security hardening. Valid values:
If you specify both a launch template and launch configuration information, the launch template takes precedence. |
Active |
| LaunchConfiguration.UserData |
string |
No |
Instance user data of the instance. Instance user data must be Base64-encoded. The maximum size of the raw data is 32 KB. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
ZWNobyBoZWxsbyBlY3Mh |
| LaunchConfiguration.SystemDiskCategory |
string |
No |
The category of the system disk. Valid values:
For retired instance types that are non-I/O optimization instances, the default value is cloud. For other instance types, the default value is cloud_efficiency. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
cloud_ssd |
| LaunchConfiguration.SystemDiskSize |
integer |
No |
The size of the system disk. Unit: GiB. Valid values: 20 to 500. The value of this parameter must be greater than or equal to max{20, size of the image specified by LaunchConfiguration.ImageId}. Default value: max{40, size of the image specified by LaunchConfiguration.ImageId}. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
40 |
| LaunchConfiguration.SystemDiskName |
string |
No |
The name of the system disk. The name must be 2 to 128 characters in length. It must start with a letter or a Chinese character and cannot start with Default value: empty. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
cloud_ssdSystem |
| LaunchConfiguration.SystemDiskDescription |
string |
No |
The description of the system disk. The description must be 2 to 256 characters in length and cannot start with If you specify both a launch template and launch configuration information, the launch template takes precedence. |
SystemDisk_Description |
| LaunchConfiguration.SystemDiskPerformanceLevel |
string |
No |
The performance level (PL) of the enterprise SSD used as the system disk. Valid values:
For information about how to select an ESSD performance level, see ESSDs. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
PL0 |
| LaunchConfiguration.PasswordInherit |
boolean |
No |
Specifies whether to use the password preset in the image. Valid values:
If you specify both a launch template and launch configuration information, the launch template takes precedence. |
true |
| LaunchConfiguration.ResourceGroupId |
string |
No |
The ID of the resource group to which the instance belongs. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
rg-bp67acfmxazb4p**** |
| LaunchConfiguration.CreditSpecification |
string |
No |
The running mode of the burstable instance. Valid values:
Default value: none. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
Standard |
| LaunchConfiguration.Password |
string |
No |
The password of the instance. The password must be 8 to 30 characters in length and must contain at least three of the following character types: uppercase letters, lowercase letters, digits, and special characters. The following special characters are supported:
For Windows instances, the password cannot start with a forward slash (/). If you specify both a launch template and launch configuration information, the launch template takes precedence. |
EcsV587! |
| LaunchConfiguration.DeploymentSetId |
string |
No |
The ID of the deployment set. |
ds-bp1frxuzdg87zh4p**** |
| LaunchTemplateConfig |
array<object> |
No |
The list of extended launch templates. |
|
|
object |
No |
The extended launch template information. |
||
| VSwitchId |
string |
No |
The ID of the vSwitch to which the ECS instance in the extended launch template is connected. The zone of the ECS instance created from the extended template is determined by the vSwitch. Note
If you specify LaunchTemplateConfig, LaunchTemplateConfig.N.VSwitchId is required. |
vsw-sn5bsitu4lfzgc5o7**** |
| MaxPrice |
number |
No |
The maximum price for spot instances in the extended launch template. Note
After you set |
3 |
| Priority |
integer |
No |
The priority of the extended launch template. A value of 0 indicates the highest priority. Valid values: 0 to +∞. |
1 |
| InstanceType |
string |
No |
The instance type in the extended launch template. Valid values of N: 1 to 20. For valid values, see Instance families. |
ecs.g5.large |
| WeightedCapacity |
number |
No |
The weight of the instance type in the extended launch template. A higher value indicates that a single instance can meet more computing power requirements, which reduces the number of instances required. Valid values: greater than 0. You can calculate the weight based on the computing power of the specified instance type and the minimum computing power of a single node in the cluster. For example, if the minimum computing power of a single node is 8 vCPUs and 60 GiB:
|
2 |
| MaxQuantity |
integer |
No |
Note
This parameter is in invitational preview and is not available for use. |
false |
| Cores |
array |
No |
The list of vCPU core counts for instance types. |
|
|
integer |
No |
The number of vCPU cores for the instance type, used to filter instance types that meet the requirements. For more information, see Instance families. Valid values of N: 1 to 10. |
2 |
|
| Memories |
array |
No |
The list of memory sizes for instance types. |
|
|
number |
No |
The memory size of the instance type. Unit: GiB. Used to filter instance types that meet the requirements. For more information, see Instance families. Valid values of N: 1 to 10. |
4 |
|
| InstanceFamilyLevel |
string |
No |
The level of the instance family, used to filter instance types that meet the requirements. Valid values:
Valid values of N: 1 to 10. |
EnterpriseLevel |
| ExcludedInstanceTypes |
array |
No |
The list of instance types to exclude. |
|
|
string |
No |
The instance type to exclude. You can use wildcards (*) to exclude a single instance type or an entire instance family. Examples:
|
ecs.n1.small/ecs.n1.*/*7* |
|
| Architectures |
array |
No |
The list of architecture types for instance types. |
|
|
string |
No |
The architecture type of the instance type. Valid values:
Default value: includes all architecture types. |
X86 |
|
| BurstablePerformance |
string |
No |
Specifies whether to include burstable instance types. Valid values:
Default value: Include. |
Include |
| ImageId |
string |
No |
The image ID. You can use this parameter to set the image for the current resource pool. If not set, the image specified in |
aliyun_3_x64_20G_alibase_20210425.vhd |
| LaunchConfiguration.DataDisk |
array<object> |
No |
The list of data disk configurations in the launch configuration. |
|
|
object |
No |
The data disk configuration information in the launch configuration. |
||
| PerformanceLevel |
string |
No |
The performance level of the enterprise SSD used as a data disk. The value of N must be consistent with the N in
For information about how to select an ESSD performance level, see ESSDs. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
PL1 |
| KmsKeyId |
string |
No |
The ID of the KMS key for the data disk. If both a launch template and launch configuration are specified, the launch template takes precedence. |
0e478b7a-4262-4802-b8cb-00d3fb40**** |
| Description |
string |
No |
The description of the data disk. The description must be 2 to 256 characters in length and cannot start with |
DataDisk_Description |
| SnapshotId |
string |
No |
The ID of the snapshot used to create data disk N. Valid values of N: 1 to 16. After you specify this parameter, the If you specify both a launch template and launch configuration information, the launch template takes precedence. |
s-bp17441ohwka0yuh**** |
| Size |
integer |
No |
The size of data disk N. Valid values of N: 1 to 16. Unit: GiB. Valid values:
Note
The value of this parameter must be greater than or equal to the size of the snapshot specified by If you specify both a launch template and launch configuration information, the launch template takes precedence. |
20 |
| Device |
string |
No |
The mount point of the data disk. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
/dev/vd1 |
| DiskName |
string |
No |
The name of the data disk. The name must be 2 to 128 characters in length. It must start with a letter or a Chinese character and cannot start with Default value: empty. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
cloud_ssdData |
| Category |
string |
No |
The category of data disk N. Valid values of N: 1 to 16. Valid values:
For I/O optimized instances, the default value is cloud_efficiency. For non-I/O optimized instances, the default value is cloud. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
cloud_ssd |
| DeleteWithInstance |
boolean |
No |
Specifies whether the data disk is released when the instance is released. Valid values:
Default value: true. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
true |
| Encrypted |
boolean |
No |
Specifies whether data disk N is encrypted. Valid values:
Default value: false. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
false |
| EncryptAlgorithm |
string |
No |
Note
This parameter is not publicly available. |
null |
| ProvisionedIops |
integer |
No |
The provisioned read/write IOPS of the ESSD AutoPL disk. Valid values: 0 to min{50,000, 1000 × capacity - baseline performance}. Baseline performance = min{1,800 + 50 × capacity, 50,000}. Note
This parameter is supported only when DiskCategory is set to cloud_auto. For more information, see ESSD AutoPL disks. |
40000 |
| BurstingEnabled |
boolean |
No |
Specifies whether to enable the performance burst feature. Valid values:
Note
This parameter is supported only when DiskCategory is set to cloud_auto. For more information, see ESSD AutoPL disks. |
false |
| AutoSnapshotPolicyId |
string |
No |
The ID of the automatic snapshot policy applied to the data disk. Note:
|
sp-bp67acfmxazb4p**** |
| LaunchConfiguration.Tag |
array<object> |
No |
The list of tags in the launch configuration. |
|
|
object |
No |
The tag information in the launch configuration. |
||
| Key |
string |
No |
The tag key of the instance. Valid values of N: 1 to 20. The tag key cannot be an empty string. It can be up to 128 characters in length and cannot start with aliyun or acs:. It cannot contain |
TestKey |
| Value |
string |
No |
The tag value of the instance. Valid values of N: 1 to 20. The tag value can be an empty string. It can be up to 128 characters in length and cannot start with acs:. It cannot contain |
TestValue |
| SystemDiskConfig |
array<object> |
No |
The list of system disk configurations. |
|
|
object |
No |
The system disk configuration information. |
||
| DiskCategory |
string |
No |
The category of the system disk. You can specify multiple candidate disk categories. The specified order determines the priority of each disk category. When a disk category is unavailable, the system automatically switches to the next category. Valid values:
|
cloud_ssd |
| DataDiskConfig |
array<object> |
No |
The list of data disk configurations. |
|
|
object |
No |
The data disk configuration information. |
||
| DiskCategory |
string |
No |
The category of the data disk. You can specify multiple candidate disk categories. The specified order determines the priority of each disk category. When a disk category is unavailable, the system automatically switches to the next category. Valid values:
|
cloud_efficiency |
| LaunchConfiguration.HostNames |
array |
No |
The list of hostnames for one or more instances. The following limits apply:
|
ecs-host-01 |
|
string |
No |
The hostname. The following limits apply:
|
ecs-host-01 |
|
| MinTargetCapacity |
string |
No |
The minimum target capacity of the auto provisioning group. Valid values |
20 |
| LaunchConfiguration.SecurityGroupIds |
array |
No |
The list of security groups to which the instance belongs. |
|
|
string |
No |
The ID of the security group to which the instance belongs. If both a launch template and launch configuration information are specified, the launch template takes precedence. |
sg-bp15ed6xe1yxeycg**** |
|
| LaunchConfiguration.SystemDisk |
object |
No |
The system disk information of the instance. If you specify both a launch template and launch configuration information, the launch template takes precedence. |
|
| Encrypted |
string |
No |
Specifies whether the system disk is encrypted. Valid values:
Default value: false. If you specify both. |
false |
| KMSKeyId |
string |
No |
The KMS key ID of the system disk. When both a launch template and launch configuration information are specified, the launch template takes precedence. |
0e478b7a-4262-4802-b8cb-00d3fb40**** |
| EncryptAlgorithm |
string |
No |
The encryption algorithm for the system disk. Valid values:
Default value: aes-256. If you specify both a launch template and launch configuration information, the launch template takes precedence. Note
This parameter is not publicly available. |
aes-256 |
| ProvisionedIops |
integer |
No |
The provisioned read/write IOPS of the ESSD AutoPL disk. Valid values: 0 to min{50,000, 1000 × Capacity - Baseline performance}. Baseline performance = min{1,800 + 50 × Capacity, 50,000}. Note
This parameter is supported only when SystemDisk.Category is set to cloud_auto. For more information, see ESSD AutoPL disk. |
40000 |
| BurstingEnabled |
boolean |
No |
Specifies whether to enable the performance burst feature. Valid values:
Note
This parameter is supported only when |
false |
| AutoSnapshotPolicyId |
string |
No |
The ID of the automatic snapshot policy to apply to the system disk. After you set this parameter, note the following items:
|
sp-bp67acfmxazb4p**** |
| LaunchConfiguration.Arn |
array<object> |
No |
Note
This parameter is in invitational preview and is not available for use. |
|
|
object |
No |
Note
This parameter is in invitational preview and is not available for use. |
||
| Rolearn |
string |
No |
Note
This parameter is in invitational preview and is not available for use. |
acs:ram::123456789012****:role/adminrole |
| RoleType |
string |
No |
Note
This parameter is in invitational preview and is not available for use. |
34458433936495****:alice |
| AssumeRoleFor |
integer |
No |
Note
This parameter is in invitational preview and is not available for use. |
123456789012**** |
| HibernationOptionsConfigured |
boolean |
No |
Note
This parameter is in invitational preview and is not publicly available. |
false |
| LaunchConfiguration.AutoReleaseTime |
string |
No |
The automatic release time of the pay-as-you-go instance. Specify the time in the ISO 8601 standard in the
|
2018-01-01T12:05:00Z |
| LaunchConfiguration.ImageFamily |
string |
No |
The name of the image family. The name must be 2 to 128 characters in length. The name must start with a letter and cannot start with |
hangzhou-daily-update |
| Tag |
array<object> |
No |
The tags to attach to the auto provisioning group. |
|
|
object |
No |
The tag to attach to the auto provisioning group. |
||
| Key |
string |
No |
The tag key of the auto provisioning group. Valid values of N: 1 to 20. The tag key cannot be an empty string. The tag key can be up to 128 characters in length and cannot start with aliyun or acs:. The tag key cannot contain http:// or https://. |
TestKey |
| Value |
string |
No |
The tag value of the auto provisioning group. Valid values of N: 1 to 20. The tag value can be an empty string. The tag value can be up to 128 characters in length and cannot contain http:// or https://. |
TestValue |
| ResourcePoolOptions |
object |
No |
The resource pool policy used to create instances. After you set this parameter, note the following items:
|
|
| Strategy |
string |
No |
Resource pools include private pools generated after Elasticity Assurance or Capacity Reservation takes effect, and public pools for instance startup. Valid values:
Default value: PublicPoolOnly. |
PrivatePoolFirst |
| PrivatePoolIds |
array |
No |
The list of private pool IDs. Valid values: 1 to 20. |
|
|
string |
No |
The private pool ID, which is the Elasticity Assurance ID or Capacity Reservation ID. Only Target-mode private pool IDs can be specified. |
eap-bp67acfmxazb4**** |
|
| LaunchConfiguration |
object |
No |
The launch configuration parameters. |
|
| Period |
integer |
No |
The subscription duration of the resource. Unit: specified by If PeriodUnit is set to Month, valid values of Period: 1, 2, 3, 6, and 12. |
1 |
| PeriodUnit |
string |
No |
The unit of the subscription billable methods duration. Valid values: Month (default). |
Month |
| AutoRenew |
boolean |
No |
Specifies whether to enable auto-renewal. This parameter takes effect when you create subscription instances. Valid values:
|
true |
| AutoRenewPeriod |
integer |
No |
The auto-renewal period. Valid values: If PeriodUnit is set to Month: 1, 2, 3, 6, 12, 24, 36, 48, and 60. Default value: 1. |
1 |
| SpotDuration |
integer |
No |
The protection period of the spot instance. Unit: hours. Default value: 1. Valid values:
Alibaba Cloud sends an ECS system event notification 5 minutes before the instance is released. Spot instances are billed by second. Select an appropriate protection period based on the expected task execution duration. After you set this parameter, note the following items:
|
1 |
| SpotInterruptionBehavior |
string |
No |
The spot instance break mode. Valid values:
For more information about economical mode, see Economical mode. Default value: Terminate. After you set this parameter, note the following items:
|
Terminate |
| ImageOptions |
object |
No |
The image-related property information. After you set this parameter, note the following items:
|
|
| LoginAsNonRoot |
boolean |
No |
Specifies whether the instance that uses this image supports logon as the ecs-user user. Valid values:
|
false |
| SchedulerOptions |
object |
No |
||
| DedicatedHostId |
string |
No |
||
| DedicatedHostClusterId |
string |
No |
||
| SecurityOptions |
object |
No |
||
| TrustedSystemMode |
string |
No |
||
| CpuOptions |
object |
No |
The CPU-related configurations. |
|
| Core |
integer |
No |
The number of CPU cores. Default value: see Specify and view CPU options. |
2 |
| ThreadsPerCore |
integer |
No |
The number of threads per CPU core. The number of vCPUs of the ECS instance = CpuOptions.Core value × CpuOptions.ThreadsPerCore value. If CpuOptions.ThreadsPerCore is set to 1, CPU hyper-threading is disabled. Only specific instance types support custom CPU thread counts. For valid values and default values, see Specify and view CPU options. |
2 |
| PrePaidOptions |
object |
No |
The detailed capacity configuration for subscription instances. |
|
| SpecifyCapacityDistribution |
array<object> |
No |
The minimum capacity set for different instance types. This parameter is supported only when |
|
|
object |
No |
The minimum capacity for an instance type. |
||
| InstanceTypes |
array |
No |
The set of instance types. Duplicate values are not allowed, and the instance types must be within the range of LaunchTemplateConfig.InstanceType. |
|
|
string |
No |
The instance type. |
ecs.c6.large |
|
| MinTargetCapacity |
integer |
No |
The minimum number of instances to deliver within the Note
The sum of all MinTargetCapacity values ( |
5 |
| ExecutionMode |
string |
No |
||
| CandidateOptions |
object |
No |
||
| TimeoutMinutes |
integer |
No |
60 |
|
| Evaluate |
boolean |
No |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| AutoProvisioningGroupId |
string |
The ID of the auto provisioning group. |
apg-sn54avj8htgvtyh8**** |
| RequestId |
string |
The request ID. |
745CEC9F-0DD7-4451-9FE7-8B752F39**** |
| LaunchResults |
object |
||
| LaunchResult |
array<object> |
The set of instances created by the auto provisioning group. This value is returned only when the delivery type of the auto provisioning group is one-time synchronization delivery ( |
|
|
array<object> |
The information about the instances created by the auto provisioning group. |
||
| ZoneId |
string |
The zone ID of the instance. |
cn-hangzhou-g |
| ErrorMsg |
string |
The error message returned when instance creation fails. |
Specific parameter is not valid. |
| InstanceType |
string |
The instance type. |
ecs.g5.large |
| ErrorCode |
string |
The error code returned when instance creation fails. |
InvalidParameter |
| SpotStrategy |
string |
The spot strategy for pay-as-you-go instances. Valid values:
|
NoSpot |
| Amount |
integer |
The number of instances in the successfully created instance ID list. |
1 |
| InstanceIds |
object |
||
| InstanceId |
array |
The list of successfully created instance IDs. |
|
|
string |
The list of successfully created instance IDs. |
["i-bp67acfmxazb4p****"] |
|
| CandidateEvaluateLevel |
string |
Low |
Examples
Success response
JSON format
{
"AutoProvisioningGroupId": "apg-sn54avj8htgvtyh8****",
"RequestId": "745CEC9F-0DD7-4451-9FE7-8B752F39****",
"LaunchResults": {
"LaunchResult": [
{
"ZoneId": "cn-hangzhou-g",
"ErrorMsg": "Specific parameter is not valid.",
"InstanceType": "ecs.g5.large",
"ErrorCode": "InvalidParameter",
"SpotStrategy": "NoSpot",
"Amount": 1,
"InstanceIds": {
"InstanceId": [
"[\"i-bp67acfmxazb4p****\"]"
]
},
"CandidateEvaluateLevel": "Low"
}
]
}
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | InvalidParameter | %s | The specified parameter is invalid. |
| 400 | InvalidAutoProvisioningGroupName.Malformed | The specified parameter "AutoProvisioningGroupName" is not valid. | The specified elastic provisioning group name AutoProvisioningGroupName is invalid. |
| 400 | InvalidAutoProvisioningGroupType.ValueNotSupported | The specified parameter "AutoProvisioningGroupType" is not supported. | |
| 400 | InvalidFleetExcessCapacityTerminationPolicy.ValueNotSupported | The specified parameter "ExcessCapacityTerminationPolicy" is not supported. | |
| 400 | InvalidDefaultTargetCapacityType.ValueNotSupported | The specified parameter "DefaultTargetCapacityType" is not supported. | |
| 400 | InvalidSpotAllocationStrategy.ValueNotSupported | The specified parameter "SpotAllocationStrategy" is not supported. | |
| 400 | InvalidSpotInstanceInterruptionBehavior.ValueNotSupported | The specified parameter "SpotInstanceInterruptionBehavior" is not supported. | |
| 400 | InvalidPayAsYouGoAllocationStrategy.ValueNotSupported | The specified parameter "PayAsYouGoAllocationStrategy" is not supported. | |
| 400 | MissingParameter.SpotAllocationStrategy | The specified parameter "SpotAllocationStrategy" is empty. | |
| 400 | MissingParameter.LaunchTemplateConfigs | The specified parameter "LaunchTemplateConfigs" is empty. | The specified LaunchTemplateConfigs parameter is empty |
| 400 | InvalidValidTime.MalFormed | The specified parameter "ValidTime" is not supported. | |
| 400 | InvalidLaunchTemplateVersion.ValueNotSupported | The specified parameter "LaunchTemplateVersion" is not valid. | |
| 400 | MissingParameter | The specified parameter "AutoProvisioningGroup" should not be null. | |
| 400 | InvalidRegion.ValueNotSupported | The specified Region does not exist. | |
| 400 | InvalidDescription.ValueNotSupported | The specified description is illegal. | |
| 400 | InvalidLaunchTemplate.ValueNotSupported | The SecurityGroupId or imageId in LaunchTemplate is not exists. | The security group ID or image ID in the launch template does not exist. |
| 400 | InvalidCapacity.ValueNotSupported | The Capacity is illegal, or the TargetCapacity is large than SpotCapacity + PayAsYouGoCapacity. | |
| 400 | InvalidInstanceType.ValueNotSupported | The instanceType is illegal. | |
| 400 | InternalError | The request processing has failed due to some unknown error. | An internal error has occurred. Try again later. |
| 400 | InvalidLaunchTemplateConfigs.SizeExceed | The size of LaunchTemplateConfigs exceeds limit. | The number of LaunchTemplateConfig in the elastic supply group exceeds the limit. |
| 400 | InvalidParameter.SpotInstancePoolsToUseCount | The specified parameter "SpotInstancePoolsToUseCount" is not valid. | |
| 400 | InvalidParameter.ResourceGroupId | The specified parameter "ResourceGroupId" is not valid. | |
| 400 | InvalidParameter.TargetCapacity | The Capacity is illegal, TotalTargetCapacity, PayAsYouGoTargetCapacity, SpotTargetCapacity must be specified, meanwhile, the TargetCapacity must be larger than or equal to the sum of SpotCapacity and OnDemandCapacity. | |
| 400 | MissingParameter.WeightedCapacity | The WeightedCapacity of LaunchTemplateConfig should not be empty. | |
| 400 | InvalidParameter.WeightedCapacityBeyondRange | The WeightedCaTpacity of LaunchTemplateConfig beyond permitted range. | |
| 400 | InvalidParameter.MaxPrice | The specified parameter "MaxSpotPrice" or "MaxPrice" of LaunchTemplateConfig is not valid. | |
| 400 | NoPermission | %s | |
| 400 | Duplicate.DiskCategory | The specified disk configs contains duplicate DiskCategory. | |
| 400 | InvalidImageFamily.Confict | The specified parameter ImageFamily should be empty when the parameter ImageId is specified. | The specified parameter ImageFamily should be empty when the parameter ImageId is specified. |
| 400 | Invalid.ResourcePoolOptions.PrivatePoolIds | The zone or instancetype of the ResourcePoolOptions.PrivatePoolIds does not match the LaunchTemplateConfig. | The zone or instancetype of the ResourcePoolOptions.PrivatePoolIds does not match the LaunchTemplateConfig. |
| 400 | Invalid.ResourcePoolOptions.Strategy | The specified ResourcePoolOptions.Strategy is invalid. | The specified ResourcePoolOptions.Strategy is invalid. |
| 400 | Invalid.ResourcePoolOptionsPrivatePoolIds.SizeExceed | The size of ResourcePoolOptions.PrivatePoolIds exceeds limit. | The size of ResourcePoolOptions.PrivatePoolIds exceeds limit. |
| 400 | MissingParameter.ResourcePoolOptions.PrivatePoolIds | The specified ResourcePoolOptions.PrivatePoolIds should not be null when ResourcePoolOptions.Strategy is PrivatePoolOnly. | The specified ResourcePoolOptions.PrivatePoolIds should not be null when ResourcePoolOptions.Strategy is PrivatePoolOnly. |
| 400 | InvalidSpotDuration | The specified SpotDuration is not valid. | The specified SpotDuration parameter is invalid. |
| 400 | InvalidSpotInterruptionBehavior | %s | The specified SpotInterruptionBehavior parameter is not supported. |
| 400 | InvalidParameter.SecurityGroupIdRepeated | The SecurityGroupId is repeated. | Duplicate security group. |
| 400 | VpcMismatch.SecurityGroupAndVSwitch | Specified security group and virtual switch are not in the same VPC. | The specified security group is not in the same VPC as the VSwitch. |
| 400 | InvalidMinTargetCapacity.NotSatisfied | The inventory of specified InstanceType does not meet the MinTargetCapacity. | The inventory of specified InstanceType does not meet the MinTargetCapacity. |
| 400 | InvalidParameterRange.MinTargetCapacity | The MinTargetCapacity exceeds the limit[0-TotalTargetCapacity]. | |
| 400 | InvalidUserData.Base64FormatInvalid | The specified parameter UserData must be base64 encoded. | The specified parameter UserData must be base64-encoded. |
| 400 | InvalidUserData.SizeExceeded | The specified parameter UserData exceeds the size. | The size of user data specified by the UserData parameter exceeds the upper limit. |
| 400 | InvalidAutoReleaseTime.Malformed | The specified parameter AutoReleaseTime is not valid. | The specified automatic release time AutoReleaseTime is invalid. |
| 400 | QuotaExceeded.AutoProvisioningGroup | The count of AutoProvisioningGroup exceeds the limit. | The count of AutoProvisioningGroup exceeds the limit. |
| 400 | Invalid.PrivatePoolOptions.status | The PrivatePool status is not valid. | The specified private pool state is incorrect. |
| 500 | InternalError | The request processing has failed due to some unknown error. | |
| 403 | TotalTargetCapacityLimitExceed | The TotalTargetCapacity exceeds the limit[0-2000]. | The TotalTargetCapacity value exceeds the limit [0~2000]. |
| 403 | SpotTargetCapacityLimitExceed | The SpotTargetCapacity exceeds the limit[0-2000]. | SpotTargetCapacity exceeds limit [0-2000]. |
| 403 | PayAsYouGoTargetCapacityLimitExceed | The PayAsYouGoTargetCapacity exceeds the limit[0-2000]. | PayAsYouGoTargetCapacity capacity exceeds limit [0~2000]. |
| 403 | OperationDenied.NoStock | The resource is out of stock in the specified zone. Please try other types, or choose other regions and zones. | The requested resources are unavailable in the specified zone. Try a different resource type or select a different region or zone. |
| 403 | CandidateDenied.NoStock | The resource is out of stock and there are no candidate resources in the specified zone. Please try other types, or choose other regions and zones. | The resources of the current instance type have been sold out and there are no candidate resources in the near future. Please select another instance type or zone as required. |
| 404 | InvalidResourcePoolOptionsPrivatePoolIds.NotFound | The ResourcePoolOptions.PrivatePoolIds do not exist. | The ResourcePoolOptions.PrivatePoolIds do not exist. |
| 404 | InvalidSecurityGroupId.NotFound | The SecurityGroupId %s provided does not exist in our records. | The security group provided does not exist. |
| 404 | InvalidVSwitchId.NotFound | The specified virtual switch %s does not exist. | The specified switch does not exist. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.