All Products
Search
Document Center

Elastic Compute Service:RunInstances

Last Updated:Nov 13, 2023

Creates pay-as-you-go or subscription Elastic Compute Service (ECS) instances.

Usage notes

  • Preparations:

    • Cost estimation: Learn about the billing methods of ECS resources. For more information, see Billing overview.

    • Instance type selection: Call the DescribeInstanceTypes operation to query the performance data of instance types, or see Best practices for instance type selection to learn about how to select instance types.

    • Query for available resources: Call the DescribeAvailableResource operation to query resources available in a specific region or zone.

    • Network planning: Make sure that you have security groups available for use. For more information, see CreateSecurityGroup. Before you create an instance of the Virtual Private Cloud (VPC) type, create a VPC in the region where you want to create the instance. For more information, see Create a VPC.

  • Comparison with CreateInstance:

    RunInstances has the following advantages over CreateInstance:

    • You can call the RunInstances operation to create up to 100 instances at a time, instead of repeatedly calling the CreateInstance operation.

    • After an instance is created, the instance enters the Starting state and then transitions to the Running state. You do not need to call the StartInstance operation to start the instance.

    • When you create an instance, you can specify InternetMaxBandwidthOut to assign a public IP address to the instance, without the need to call the AllocatePublicIpAddress operation.

    • You can specify AutoReleaseTime to set the time when to automatically release the instances, without the need to call the ModifyInstanceAutoReleaseTime operation.

    • You can specify LaunchTemplateId and LaunchTemplateVersion to use a launch template. This eliminates the need to configure a large number of parameters every time you create instances.

    • You can specify UniqueSuffix to batch configure sequential names or hostnames for multiple instances for easy management and retrieval.

    • When you call the RunInstances operation to create instances, you can configure the enclave-based confidential computing mode and the trusted system mode for the instances.

    • You can set NetworkOptions.EnableJumboFrame to true to enable the Jumbo Frame feature when you create instances. For more information, see MTUs.

  • Precautions:

    • You can create a maximum of 100 instances at a time.

    • You can use the AutoReleaseTime parameter to set the time when to automatically release the instances.

    • After you create instances and obtain their IDs, you can call the DescribeInstances operation to check the status of the instances.

    • By default, instances automatically start after they are created. Instances are ready for use when they are in the Running (Running) state.

    • Starting from November 27, 2020, the maximum bandwidth value available for you to create ECS instances or to change ECS instance configurations is subject to the throttling policy of your account. To increase the maximum bandwidth value, submit a ticket. The throttling policy imposes the following constraints: Within a single region, the total maximum bandwidth value of all instances that use the pay-by-traffic billing method for network usage cannot exceed 5 Gbit/s and the total maximum bandwidth value of all instances that use the pay-by-bandwidth billing method for network usage cannot exceed 50 Gbit/s.

    • Different from the CreateInstance operation, the RunInstances operation allows the system to assign public IP addresses to the new instances if you set InternetMaxBandwidthOut to a value greater than 0.

    • When you call the RunInstances operation to create an instance, you can use one of the following methods to attach a primary elastic network interface (ENI) to the instance. Note that you can use only one of the methods to configure the primary ENI in each call. Otherwise, the call fails and an error message is returned.

      • Specify parameters such as SecurityGroupId, VSwitchId, PrivateIpAddress, NetworkInterfaceQueueNumber, and Ipv6AddressCount to configure the primary ENI.

      • Specify parameters that start with NetworkInterface.N. to configure the primary and secondary ENIs. If NetworkInterface.N.InstanceType is set to Primary, the configured ENI is the primary ENI. If NetworkInterface.N.InstanceType is set to Secondary or left empty, the configured ENI is a secondary ENI.

    • After you call this operation, an error is returned if a parameter is invalid or if available resources are insufficient. For more information, see the "Error codes" section of this topic.

      • If the maximum number of instances of the specified instance type that can be created within the specified region or the maximum number of vCPUs for all instance types in a zone is exceeded, the QuotaExceed.ElasticQuota error is returned when you call this operation. You can go to the ECS console or Quota Center to request a quota increase.

      • If the capacity of disks that belong to the specified disk category exceeds the quota limit for the specified zone, the QuotaExceed.DiskCapacity error is returned when you call this operation. You can go to the Quota Center to view and increase the disk capacity quota.

  • Best practices:

    • We recommend that you use auto provisioning groups in the following scenarios: Resources are insufficient to create more than 100 instances at a time, you want to quickly create instances regardless of resource configurations such as instance types or zones, or you want to create instances to consume a specific total number of vCPUs regardless of the number of instances. You can call the CreateAutoProvisioningGroup operation to create an auto provisioning group to deploy an instance cluster across different billing methods, instance families, and zones. For more information, see Use auto provisioning group-related API operations to create multiple ECS instances at the same time.

    • You can call the RunInstances operation to batch create instances. To better manage and search for these instances, we recommend that you add tags to the instances by specifying Tag.N.Key and Tag.N.Value. You can also append incremental suffixes (UniqueSuffix) to the hostname (HostName) and to the instance name (InstanceName).

    • A launch template contains parameters required to create an instance so that you do not have to specify these parameters every time you create instances. You can call the CreateLaunchTemplate operation to create a launch template. Then, in your request to call the RunInstances operation, you can specify LaunchTemplateId and LaunchTemplateVersion to use the launch template.

    • When you create an instance in the ECS console, you can view the best practices for calling the RunInstances operation. In the Preview step, click View Open API in the Configurations Selected section. In the dialog box that appears, the left-side API Workflow section shows the operations and request parameters that are related to the RunInstances operation. The right-side section shows SDK examples for the Java and Python programming languages.

Example 1: Create a subscription instance

Use the aliyun_3_x64_20G_alibase_20221102.vhd image to create a one-month subscription instance of the ecs.g7.large instance type in the China (Hangzhou) region, and enable auto-renewal to renew the instance for one month on expiration. The instance uses a 40 GiB enhanced SSD (ESSD) as the system disk and a 100 GiB ESSD as a data disk, and is automatically assigned private and public IP addresses. The outbound public bandwidth of the instance is 10 Mbit/s. The instance name is ECS-test and the logon password of the instance is ECS@test1234.

http(s)://ecs.aliyuncs.com/?Action=RunInstances
&RegionId=cn-hangzhou
&ImageId=aliyun_3_x64_20G_alibase_20221102.vhd
&InstanceType=ecs.g7.large
&SecurityGroupId=sg-bp150uqocpf9jj70****
&VSwitchId=vsw-bp1qo7s91cbch5i4l****
&InstanceChargeType=PrePaid
&SystemDisk.Size=40
&DataDisk.1.Size=100
&DataDisk.1.Category=cloud_essd
&SystemDisk.Category=cloud_essd
&Amount=1
&Period=1
&PeriodUnit=Month
&AutoRenew=true
&AutoRenewPeriod=1
&HostName=ECS-test
&Password=ECS@test1234
&InternetMaxBandwidthOut=10
&<Common request parameters>

Example 2: Create a pay-as-you-go instance

Use the aliyun_3_x64_20G_alibase_20221102.vhd image to create a pay-as-you-go instance of the ecs.g7.large instance type in the China (Hangzhou) region. The instance uses a 40 GiB ESSD as the system disk and a 100 GiB ESSD as a data disk, and is automatically assigned private and public IP addresses. The outbound public bandwidth of the instance is 10 Mbit/s. The instance name is ECS-test and the logon password of the instance is ECS@test1234.

http(s)://ecs.aliyuncs.com/?Action=RunInstances
&RegionId=cn-hangzhou
&ImageId=aliyun_3_x64_20G_alibase_20221102.vhd
&InstanceType=ecs.g7.large
&SecurityGroupId=sg-bp150uqocpf9jj70****
&VSwitchId=vsw-bp1qo7s91cbch5i4l****
&InstanceChargeType=PostPaid
&SystemDisk.Size=40
&DataDisk.1.Size=100
&DataDisk.1.Category=cloud_essd
&SystemDisk.Category=cloud_essd
&HostName=ECS-test
&Password=ECS@test1234
&InternetMaxBandwidthOut=10
&<Common request parameters>

Example 3: Create a preemptible instance

Use the aliyun_3_x64_20G_alibase_20221102.vhd image to create a preemptible instance of the ecs.g7.large instance type that has a 1-hour protection period in the China (Hangzhou) region. The market price of the instance type at the time of purchase is automatically used as the bidding price. The instance uses a 40 GiB ESSD as the system disk and a 100 GiB ESSD as a data disk, and is automatically assigned private and public IP addresses. The outbound public bandwidth of the instance is 10 Mbit/s. The instance name is ECS-test and the logon password of the instance is ECS@test1234.

http(s)://ecs.aliyuncs.com/?Action=RunInstances
&RegionId=cn-hangzhou
&ImageId=aliyun_3_x64_20G_alibase_20221102.vhd
&InstanceType=ecs.g7.large
&SecurityGroupId=sg-bp150uqocpf9jj70****
&VSwitchId=vsw-bp1qo7s91cbch5i4l****
&InstanceChargeType=PostPaid
&SystemDisk.Size=40
&DataDisk.1.Size=100
&DataDisk.1.Category=cloud_essd
&SystemDisk.Category=cloud_essd
&HostName=ECS-test
&Password=ECS@test1234
&InternetMaxBandwidthOut=10
&SpotStrategy=SpotAsPriceGo
&SpotDuration=1
&<Common request parameters>

Example 4: Create a subscription instance on a dedicated host

Use the aliyun_3_x64_20G_alibase_20221102.vhd image to create a one-month subscription instance of the ecs.g7.large instance type on the dh-bp12w10wll9xcjq2 dedicated host. The instance uses a 40 GiB ESSD as the system disk and a 100 GiB ESSD as a data disk, and is automatically assigned private and public IP addresses. The outbound public bandwidth of the instance is 10 Mbit/s. The instance name is ECS-test and the logon password of the instance is ECS@test1234.

http(s)://ecs.aliyuncs.com/?Action=RunInstances
&RegionId=cn-hangzhou
&ImageId=aliyun_3_x64_20G_alibase_20221102.vhd
&InstanceType=ecs.g7.large
&SecurityGroupId=sg-bp150uqocpf9jj70****
&VSwitchId=vsw-bp1qo7s91cbch5i4l****
&InstanceChargeType=PrePaid
&Amount=1
&Period=1
&PeriodUnit=Month
&SystemDisk.Size=40
&DataDisk.1.Size=100
&DataDisk.1.Category=cloud_essd
&SystemDisk.Category=cloud_essd
&HostName=ECS-test
&Password=ECS@test1234
&InternetMaxBandwidthOut=10
&DedicatedHostId=dh-bp12w10wll9xcjq2****
&<Common request parameters>

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter

Type

Required

Example

Description

Action

String

Yes

RunInstances

The operation that you want to perform. Set the value to RunInstances.

RegionId

String

Yes

cn-hangzhou

The ID of the region in which to create the instance. You can call the DescribeRegions operation to query the most recent region list.

ImageId

String

No

aliyun_2_1903_x64_20G_alibase_20200324.vhd

The ID of the image. You can call the DescribeImages operation to query available images. If you do not use LaunchTemplateId or LaunchTemplateName to specify a launch template and do not set ImageFamily to obtain the latest available custom image from the specified image family, you must specify ImageId.

ImageFamily

String

No

hangzhou-daily-update

The name of the image family. You can set this parameter to obtain the latest available custom image within the specified image family to create instances.

  • If you specify ImageId, you cannot specify ImageFamily.

  • If you do not specify ImageId but use the LaunchTemplateId or LaunchTemplateName parameter to specify a launch template that has the ImageId parameter specified, you cannot specify ImageFamily.

  • If you do not specify ImageId but use the LaunchTemplateId or LaunchTemplateName parameter to specify a launch template that does not have the ImageId parameter set, you can specify ImageFamily.

  • If you do not specify ImageId, LaunchTemplateId, or LaunchTemplateName, you can specify ImageFamily.

InstanceType

String

No

ecs.g6.large

The instance type. If you do not use LaunchTemplateId or LaunchTemplateName to specify a launch template, you must specify InstanceType.

SecurityGroupId

String

No

sg-bp15ed6xe1yxeycg7****

The ID of the security group to which to assign the instance. Instances in the same security group can communicate with each other. The maximum number of instances that a security group can contain depends on the type of the security group. For more information, see the "Security group limits" section in Limits.

Note

The network type of the new instance must be the same as that of the security group specified by the SecurityGroupId parameter. For example, if the specified security group is of the VPC type, the new instance is also of the VPC type and you must specify VSwitchId.

If you do not use LaunchTemplateId or LaunchTemplateName to specify a launch template, you must specify SecurityGroupId. Take note of the following items:

  • You can set SecurityGroupId to specify a single security group or set SecurityGroupIds.N to specify one or more security groups. However, you cannot specify both SecurityGroupId and SecurityGroupIds.N.

  • If NetworkInterface.N.InstanceType is set to Primary, you cannot specify SecurityGroupId or SecurityGroupIds.N but can specify NetworkInterface.N.SecurityGroupId or NetworkInterface.N.SecurityGroupIds.N.

VSwitchId

String

No

vsw-bp1s5fnvk4gn2tws0****

The ID of the vSwitch to which to connect to the instance. You must set this parameter when you create an instance of the VPC type. The vSwitch and the security group must belong to the same VPC. You can call the DescribeVSwitches operation to query available vSwitches.

Take note of the following items:

  • If you specify VSwitchId, the zone specified by the ZoneId parameter must be the zone where the specified vSwitch resides. You can also leave the ZoneId parameter empty. Then, the system selects the zone where the specified vSwitch resides.

  • If NetworkInterface.N.InstanceType is set to Primary, you cannot specify VSwitchId but can specify NetworkInterface.N.VSwitchId.

InstanceName

String

No

k8s-node-[1,4]-alibabacloud

The name of the instance. The name must be 2 to 128 characters in length. The name must start with a letter and cannot start with http:// or https://. The name can contain letters, digits, colons (:), underscores (_), periods (.), and hyphens (-). The default value of this parameter is the InstanceId value.

When you batch create instances, you can batch configure sequential names for the instances. For more information, see Batch configure sequential names or hostnames for multiple instances.

Description

String

No

Instance_Description

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

InternetMaxBandwidthIn

Integer

No

10

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

  • When the purchased outbound public bandwidth is less than or equal to 10 Mbit/s, the valid values of this parameter are 1 to 10 and the default value is 10.

  • When the purchased outbound public bandwidth is greater than 10 Mbit/s, the valid values of this parameter are 1 to the InternetMaxBandwidthOut value and the default value is the InternetMaxBandwidthOut value.

InternetMaxBandwidthOut

Integer

No

10

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

Default value: 0.

HostName

String

No

k8s-node-[1,4]-ecshost

The hostname of the instance. Take note of the following items:

  • The hostname cannot start or end with a period (.) or hyphen (-). The hostname cannot contain consecutive periods (.) or hyphens (-).

  • For Windows instances, the hostname must be 2 to 15 characters in length and cannot contain periods (.) or contain only digits. The hostname can contain letters, digits, and hyphens (-).

  • For instances that run other operating systems such as Linux, take note of the following items:

    • The hostname must be 2 to 64 characters in length. You can use periods (.) to separate a hostname into multiple segments. Each segment can contain letters, digits, and hyphens (-).

    • You can use the ${instance_id} placeholder to pass instance IDs into the hostname specified by HostName. For example, if you set HostName to k8s-${instance_id} and the instance is assigned an ID of i-123abc****, the hostname of the instance is k8s-i-123abc****.

When you create multiple instances, you can perform the following operations:

UniqueSuffix

Boolean

No

true

Specifies whether to automatically append incremental suffixes to the hostname specified by the HostName parameter and to the instance name specified by the InstanceName parameter when you batch create instances. The incremental suffixes can range from 001 to 999. Valid values:

  • true: appends incremental suffixes to the hostname and the instance name.

  • false: does not append incremental suffixes to the hostname or the instance name.

Default value: false.

When the HostName or InstanceName value is set in the name_prefix[begin_number,bits] format without a suffix (name_suffix), the UniqueSuffix parameter does not take effect. The names are sorted in the specified sequence.

For more information, see Batch configure sequential names or hostnames for multiple instances.

Password

String

No

EcsV587!

The password of the 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 password can contain the following special characters:

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

For Windows instances, the password cannot start with a forward slash (/).

Note

For security reasons, we recommend that you use HTTPS to send requests if the Password parameter is specified.

PasswordInherit

Boolean

No

false

Specifies whether to use the password preset in the image. Valid values:

  • true

  • false

Default value: false.

Note

If you set this parameter to true, leave Password empty and make sure that the selected image has a password preset.

ZoneId

String

No

cn-hangzhou-g

The ID of the zone in which to create the instance. You can call the DescribeZones operation to query the most recent zone list.

Note

If the VSwitchId parameter is specified, the zone specified by the ZoneId parameter must be the zone where the vSwitch resides. You can also leave ZoneId empty. Then, the system selects the zone where the specified vSwitch resides.

This parameter is empty by default.

InternetChargeType

String

No

PayByTraffic

The billing method for network usage. Valid values:

  • PayByBandwidth

  • PayByTraffic

Default value: PayByTraffic.

Note

When the pay-by-traffic billing method is used for network usage, the maximum inbound and outbound bandwidths are used as upper limits of bandwidths instead of guaranteed performance. In scenarios where demand outstrips resource supplies, the maximum bandwidth values may be limited. If you want guaranteed bandwidths for your instances, use the pay-by-bandwidth billing method for network usage.

SystemDisk.Size

String

No

40

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

  • Basic disks: 20 to 500

  • Other disks: 20 to 2048

The value of this parameter must be at least 20 and greater than or equal to the size of the specified image.

Default value: 40 or the image size, whichever is greater.

SystemDisk.Category

String

No

cloud_ssd

The category of the system disk. Valid values:

  • cloud_efficiency: ultra disk

  • cloud_ssd: standard SSD

  • cloud_essd: enhanced SSD (ESSD)

  • cloud: basic disk

  • cloud_auto: ESSD AutoPL disk

For non-I/O optimized instances of retired instance types, the default value is cloud. For other instances, the default value is cloud_efficiency.

SystemDisk.DiskName

String

No

cloud_ssdSystem

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

SystemDisk.Description

String

No

SystemDisk_Description

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

SystemDisk.PerformanceLevel

String

No

PL0

The performance level of the ESSD to use as the system disk. Valid values:

  • PL0: A single ESSD can deliver up to 10,000 random read/write IOPS.

  • PL1 (default): A single ESSD can deliver up to 50,000 random read/write IOPS.

  • PL2: A single ESSD can deliver up to 100,000 random read/write IOPS.

  • PL3: A single ESSD can deliver up to 1,000,000 random read/write IOPS.

For more information about ESSD performance levels, see ESSDs.

SystemDisk.AutoSnapshotPolicyId

String

No

sp-bp67acfmxazb4p****

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

IoOptimized

String

No

optimized

Specifies whether the instance that you want to create is an I/O optimized instance. For instances of retired instance types, the default value is none. For instances of other instance types, the default value is optimized. Valid values:

  • none: The instance is not I/O optimized.

  • optimized: The instance is I/O optimized.

UserData

String

No

ZWNobyBoZWxsbyBlY3Mh

The user data of the instance. The user data must be encoded in Base64. The raw data can be up to 16 KB in size.

Note

If the instance type supports user data, you can use the UserData parameter to pass in user data. We recommend that you do not pass in confidential information (such as passwords or private keys) in plaintext as user data. This is because the system does not encrypt UserData values when API requests are transmitted. If you must pass in confidential information, we recommend that you encrypt and encode the information in Base64, and then decode and decrypt the information in the same way within the instance.

KeyPairName

String

No

KeyPair_Name

The name of the key pair to bind to the instance.

Note

For Windows instances, this parameter is ignored. This parameter is empty by default. The Password parameter takes effect even if the KeyPairName parameter is specified.

RamRoleName

String

No

RAM_Name

The name of the instance Resource Access Management (RAM) role. You can call the ListRoles operation provided by RAM to query the instance RAM roles that you created.

Amount

Integer

No

3

The number of instances that you want to create. Valid values: 1 to 100.

Default value: 1.

MinAmount

Integer

No

2

The minimum number of instances that can be created. Valid values: 1 to 100.

  • If the number of instances that available resources are sufficient to create is smaller than the MinAmount value, instances cannot be created.

  • If the number of instances that available resources are sufficient to create is greater than or equal to the MinAmount value, instances are created based on the number of available resources.

AutoReleaseTime

String

No

2018-01-01T12:05:00Z

The time when to automatically release the pay-as-you-go instance. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

  • If the value of ss is not 00, the start time is automatically rounded to the nearest minute based on the value of mm.

  • The specified time must be at least 30 minutes later than the current time.

  • The specified time can be at most three years later than the current time.

SpotStrategy

String

No

NoSpot

The bidding policy for the pay-as-you-go instance. This parameter is valid only when InstanceChargeType is set to PostPaid. Valid values:

  • NoSpot: The instance is created as a pay-as-you-go instance.

  • SpotWithPriceLimit: The instance is created as a preemptible instance with a user-defined maximum hourly price.

  • SpotAsPriceGo: The instance is created as a preemptible instance whose bidding price is based on the market price at the time of purchase.

Default value: NoSpot.

SpotDuration

Integer

No

1

The protection period of the preemptible instance. Unit: hours. Valid values: 0, 1, 2, 3, 4, 5, and 6

  • The following protection periods are in invitational preview: 2, 3, 4, 5, and 6 hours. If you want to set this parameter to one of these values, submit a ticket.

  • If this parameter is set to 0, no protection period is configured for the preemptible instance.

Default value: 1.

SpotPriceLimit

Float

No

0.97

The maximum hourly price of the preemptible instance. The value is accurate to three decimal places. This parameter is valid only when SpotStrategy is set to SpotWithPriceLimit.

SpotInterruptionBehavior

String

No

Terminate

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.

SecurityEnhancementStrategy

String

No

Active

Specifies whether to enable security hardening. Valid values:

  • Active: enables security hardening. This value is applicable only to public images.

  • Deactive: does not enable security hardening. This value is applicable to all image types.

ClientToken

String

No

123e4567-e89b-12d3-a456-426655440000

The client token that is used to ensure the idempotence of the request. You can use the client to generate the token, but you must make sure that the token is unique among different requests. The value of ClientToken can contain only ASCII characters and cannot exceed 64 characters in length. For more information, see How to ensure idempotence.

HpcClusterId

String

No

hpc-bp67acfmxazb4p****

The ID of the High Performance Computing (HPC) cluster to which to assign the instance.

This parameter is required when you create instances of a Supper Computing Cluster (SCC) instance type. You can create an HPC cluster. For more information, see CreateHpcCluster.

DryRun

Boolean

No

false

Specifies whether to perform only a dry run, without performing the actual request. Valid values:

  • true: performs only a dry run. The system checks the request for potential issues, including missing parameter values, incorrect request syntax, service limits, and insufficient ECS resources. If the request fails the dry run, an error message is returned. If the request passes the dry run, the DryRunOperation error code is returned.

  • false (default): performs a dry run and performs the actual request. If the request passes the dry run, the operation is performed.

DedicatedHostId

String

No

dh-bp67acfmxazb4p****

The ID of the dedicated host on which to create the instance. If you specify DedicatedHostId, the SpotStrategy and SpotPriceLimit parameters are ignored. This is because preemptible instances cannot be created on dedicated hosts.

You can call the DescribeDedicatedHosts operation to query the IDs of dedicated hosts.

LaunchTemplateId

String

No

lt-bp1apo0bbbkuy0rj****

The ID of the launch template. For more information, see DescribeLaunchTemplates.

To use a launch template to create an instance, you must use the LaunchTemplateId or LaunchTemplateName parameter to specify the launch template.

LaunchTemplateName

String

No

LaunchTemplate_Name

The name of the launch template.

To use a launch template to create an instance, you must use the LaunchTemplateId or LaunchTemplateName parameter to specify the launch template.

LaunchTemplateVersion

Long

No

3

The version of the launch template. If you set LaunchTemplateId or LaunchTemplateName parameter but do not set the version number of the launch template, the default template version is used.

ResourceGroupId

String

No

rg-bp67acfmxazb4p****

The ID of the resource group to which to assign the instance.

Period

Integer

No

1

The subscription period of the instance. The unit is specified by the PeriodUnit parameter. This parameter is valid and required only when InstanceChargeType is set to PrePaid. If the DedicatedHostId parameter is specified, the value of Period must not exceed the subscription period of the specified dedicated host. Valid values:

Valid values when PeriodUnit is set to Month: 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 24, 36, 48, and 60.

PeriodUnit

String

No

Month

The unit of the subscription period. Default value: Month. Valid values:

Month

AutoRenew

Boolean

No

true

Specifies whether to enable auto-renewal for the instance. This parameter is valid only whenInstanceChargeType is set to PrePaid. Valid values:

  • true

  • false

Default value: false.

AutoRenewPeriod

Integer

No

1

The auto-renewal period of the instance. Valid values:

Valid values when PeriodUnit is set to Month: 1, 2, 3, 6, 12, 24, 36, 48, and 60.

Default value: 1.

InstanceChargeType

String

No

PrePaid

The billing method of the instance. Valid values:

  • PrePaid: subscription

  • PostPaid: pay-as-you-go

Default value: PostPaid.

If you set this parameter to PrePaid, make sure that you have sufficient credits in your account. Otherwise, an InvalidPayMethod error is returned.

DeploymentSetId

String

No

ds-bp1brhwhoqinyjd6****

The ID of the deployment set in which to deploy the instance.

DeploymentSetGroupNo

Integer

No

1

The number of the deployment set group to which to deploy the instance. If the deployment set specified by the DeploymentSetId parameter uses the high availability group strategy (AvailabilityGroup), you can use the DeploymentSetGroupNo parameter to specify a deployment set group in the deployment set. Valid values: 1 to 7.

PrivateIpAddress

String

No

10.1.**.**

The private IP address to assign to the instance. To assign a private IP address to an instance that resides in a VPC, make sure that the IP address is an idle IP address within the CIDR block of the vSwitch specified by VSwitchId.

Take note of the following items:

  • If the PrivateIpAddress parameter is specified, take note of the following items:

    • If Amount is set to 1, a single instance is created and the specified private IP address is assigned to the instance.

    • If Amount is set to a numeric value greater than 1, the specified number of instances are created and consecutive private IP addresses starting from the specified one are assigned to the instances. In this case, you cannot specify parameters that start with NetworkInterface.N to attach secondary ENIs to the instances.

  • If NetworkInterface.N.InstanceType is set to Primary, you cannot specify PrivateIpAddress but can specify NetworkInterface.N.PrimaryIpAddress.

CreditSpecification

String

No

Standard

The performance mode of the burstable instance. Valid values:

  • Standard: the standard mode. For more information, see the "Standard mode" section in Burstable instances.

  • Unlimited: the unlimited mode. For more information, see the "Unlimited mode" section in Burstable instances.

Ipv6AddressCount

Integer

No

1

The number of IPv6 addresses to randomly generate for the primary ENI. Valid values: 1 to 10.

Take note of the following items:

  • You cannot specify both Ipv6Addresses.N and Ipv6AddressCount.

  • If NetworkInterface.N.InstanceType is set to Primary, you cannot specify Ipv6Address.N or Ipv6AddressCount but can specify NetworkInterface.N.Ipv6Address.N or NetworkInterface.N.Ipv6AddressCount.

NetworkInterfaceQueueNumber

Integer

No

8

The number of queues supported by the primary ENI. Take note of the following items:

  • The value of this parameter cannot exceed the maximum number of queues per ENI allowed for the instance type.

  • The total number of queues for all ENIs on the instance cannot exceed the queue quota for the instance type. To query the maximum number of queues per ENI and the queue quota for an instance type, you can call the DescribeInstanceTypes operation and check the MaximumQueueNumberPerEni and TotalEniQueueQuantity values in the response.

  • If NetworkInterface.N.InstanceType is set to Primary, you cannot specify NetworkInterfaceQueueNumber but can specify NetworkInterface.N.QueueNumber.

DeletionProtection

Boolean

No

false

Specifies whether to enable release protection for the instance. This parameter determines whether you can use the ECS console or call the DeleteInstance operation to release the instance. Valid values:

  • true

  • false

Default value: false.

Note

This parameter is applicable only to pay-as-you-go instances. It can protect instances against manual releases, but not against automatic releases.

HibernationOptions.Configured

Boolean

No

false

Note

This parameter is in invitational preview and is not publicly available.

Affinity

String

No

default

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

  • default: does not associate the instance with the dedicated host. When you start an instance that was stopped in economical mode, the instance is automatically deployed to another dedicated host in the automatic deployment resource pool if the available resources of the original dedicated host are insufficient.

  • host: associates the instance with the dedicated host. When you start an instance that was stopped in economical mode, the instance remains on the original dedicated host. If the original dedicated host of the instance has insufficient resources, the instance cannot be started.

Default value: default.

Tenancy

String

No

default

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

  • default: creates the instance on a non-dedicated host.

  • host: creates the instance on a dedicated host. If you do not specify DedicatedHostId, Alibaba Cloud selects a dedicated host for the instance.

Default value: default.

StorageSetId

String

No

ss-bp67acfmxazb4p****

The ID of the storage set.

StorageSetPartitionNumber

Integer

No

2

The maximum number of partitions in the storage set. The value must be greater than or equal to 2.

CpuOptions.Core

Integer

No

2

The number of CPU cores. This parameter cannot be specified but only uses its default value.

CpuOptions.ThreadsPerCore

Integer

No

2

The number of threads per CPU core. The following formula is used to calculate the number of vCPUs of the instance: CpuOptions.Core value × CpuOptions.ThreadsPerCore value.

  • If CpuOptionsThreadPerCore is set to 1, hyperthreading is disabled.

  • This parameter is applicable only to specific instance types.

CpuOptions.Numa

String

No

1

This parameter is no longer used.

SecurityOptions.TrustedSystemMode

String

No

vTPM

The trusted system mode. Set the value to vTPM.

The trusted system mode supports the following instance families:

  • g7, c7, and r7

  • Security-enhanced instance families: g7t, c7t, and r7t

When you create instances of the preceding instance families, you must set this parameter. Take note of the following items:

  • To use the Alibaba Cloud trusted system, set this parameter to vTPM. Then, the Alibaba Cloud trusted system performs trust verifications when the instances start.

  • If you do not want to use the Alibaba Cloud trusted system, leave this parameter empty. Take note that if your created instances use an enclave-based confidential computing environment (with SecurityOptions.ConfidentialComputingMode set to Enclave), the Alibaba Cloud trusted system is enabled for the instances.

  • When you use the ECS API to create instances that use the trusted system, you can call only the RunInstances operation. The CreateInstance operation does not support the SecurityOptions.TrustedSystemMode parameter.

    Note

    If you have configured an instance as a trusted one when you created the instance, you can use only an image that supports the trusted system to replace the system disk of the instance.

For more information about the trusted system, see Overview.

SecurityOptions.ConfidentialComputingMode

String

No

Enclave

The confidential computing mode. Set the value to Enclave.

A value of Enclave indicates that an enclave-based confidential computing environment is built on the instance. When you call the RunInstances operation, you can set this parameter only for c7, g7, or r7 instances to use enclave-based confidential computing. Take note of the following items:

  • The confidential computing feature is in invitational preview.

  • When you use the ECS API to create instances that support enclave-based confidential computing, you can call only the RunInstances operation. The CreateInstance operation does not support the SecurityOptions.ConfidentialComputingMode parameter.

  • Enclave-based confidential computing is implemented based on the Alibaba Cloud trusted system (vTPM). When you build a confidential computing environment on an instance by using Enclave, the Alibaba Cloud trusted system is enabled for the instance. If you set SecurityOptions.ConfidentialComputingMode to Enclave when you call this operation, the created instances use enclave-based confidential computing and the Alibaba Cloud trusted system regardless of whether SecurityOptions.TrustedSystemMode is set to vTPM.

For more information about confidential computing, see Build a confidential computing environment by using Enclave.

HttpEndpoint

String

No

enabled

Specifies whether to enable the access channel for instance metadata. Valid values:

  • enabled

  • disabled

Default value: enabled.

Note

For more information about instance metadata, see Overview of ECS instance metadata.

HttpTokens

String

No

optional

Specifies whether to forcefully use the security-enhanced mode (IMDSv2) to access instance metadata. Valid values:

  • optional: does not forcefully use the security-enhanced mode (IMDSv2).

  • required: forcefully uses the security-enhanced mode (IMDSv2). After you set this parameter to required, you cannot access instance metadata in normal mode.

Default value: optional.

Note

For more information about modes of accessing instance metadata, see Access mode of instance metadata.

HttpPutResponseHopLimit

Integer

No

3

The HTTP PUT response hop limit for accessing instance metadata. Valid values: 1 to 64.

Default value: 1.

PrivatePoolOptions.MatchCriteria

String

No

Open

The type of the private pool to use to create the instance. A private pool is generated when an elasticity assurance or a capacity reservation takes effect. You can select a private pool when you create an instance. Valid values:

  • Open: open private pool. The system selects a matching open private pool to create the instance. If no matching open private pools are found, resources in the public pool are used. When you set this parameter to Open, you can leave PrivatePoolOptions.Id empty.

  • Target: specified private pool. The capacity in a specified private pool is used. If the specified private pool is unavailable, the instance cannot be created. If you set this parameter to Target, you must specify PrivatePoolOptions.Id.

  • None: no private pool. The capacity in private pools is not used.

Default value: None.

In the following scenarios, PrivatePoolOptions.MatchCriteria can be set only to None or left empty:

  • Create a preemptible instance.

  • Create an instance in the classic network.

  • Create an instance on a dedicated host.

PrivatePoolOptions.Id

String

No

eap-bp67acfmxazb4****

The ID of the private pool to use to create the instance. The ID of a private pool is the same as that of the elasticity assurance or capacity reservation for which the private pool is generated.

Isp

String

No

null

Note

This parameter is in invitational preview and is not publicly available.

SchedulerOptions.DedicatedHostClusterId

String

No

dc-bp12wlf6am0vz9v2****

The ID of the dedicated host cluster in which to create the instance. After this parameter is specified, the system selects one dedicated host from the specified cluster to create the instance.

Note

This parameter is valid only when Tenancy is set to host.

When you specify both DedicatedHostId and SchedulerOptions.DedicatedHostClusterId, take note of the following items:

  • If the specified dedicated host belongs to the specified dedicated host cluster, the instance is preferentially deployed on the specified dedicated host.

  • If the specified dedicated host does not belong to the specified dedicated host cluster, the instance cannot be created.

You can call the DescribeDedicatedHostClusters operation to query the list of dedicated host cluster IDs.

SecurityGroupIds.N

String

No

sg-bp15ed6xe1yxeycg7****

The ID of security group N to which to assign the instance. The valid values of N vary based on the maximum number of security groups to which an instance can belong. For more information, see the "Security group limits" section in Limits.

Take note of the following items:

  • You cannot specify both SecurityGroupId and SecurityGroupIds.N.

  • If NetworkInterface.N.InstanceType is set to Primary, you cannot specify SecurityGroupId or SecurityGroupIds.N but can specify NetworkInterface.N.SecurityGroupId or NetworkInterface.N.SecurityGroupIds.N.

HostNames.N

String

No

ecs-host-01

The hostname of instance N. You can use this parameter to specify different hostnames for multiple instances. Take note of the following items:

  • The maximum value of N must be the same as the Amount value. For example, if you set Amount to 2, you can use HostNames.1 and HostNames.2 to specify hostnames for the individual instances. Examples: HostNames.1=test1 and HostNames.2=test2.

  • You cannot specify both HostName and HostNames.N.

  • The hostname cannot start or end with a period (.) or hyphen (-). The hostname cannot contain consecutive periods (.) or hyphens (-).

  • For Windows instances, the hostname must be 2 to 15 characters in length and cannot contain periods (.) or contain only digits. The hostname can contain letters, digits, and hyphens (-).

  • For instances that run other operating systems such as Linux, the hostname must be 2 to 64 characters in length. You can use periods (.) to separate a hostname into multiple segments. Each segment can contain letters, digits, and hyphens (-).

DataDisk.N.PerformanceLevel

String

No

PL1

The performance level of the ESSD to use as data disk N. The value of N must be the same as that in DataDisk.N.Category when DataDisk.N.Category is set to cloud_essd. Valid values:

  • PL0: A single ESSD can deliver up to 10,000 random read/write IOPS.

  • PL1 (default): A single ESSD can deliver up to 50,000 random read/write IOPS.

  • PL2: A single ESSD can deliver up to 100,000 random read/write IOPS.

  • PL3: A single ESSD can deliver up to 1,000,000 random read/write IOPS.

For more information about ESSD performance levels, see ESSDs.

DataDisk.N.AutoSnapshotPolicyId

String

No

sp-bp67acfmxazb4p****

The ID of the automatic snapshot policy to apply to data disk N.

DataDisk.N.Encrypted

String

No

false

Specifies whether to encrypt data disk N. Valid values:

  • true

  • false

Default value: false.

DataDisk.N.Description

String

No

DataDisk_Description

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

DataDisk.N.SnapshotId

String

No

s-bp17441ohwka0yuh****

The ID of the snapshot to use to create data disk N. Valid values of N: 1 to 16.

When the DataDisk.N.SnapshotId parameter is specified, the DataDisk.N.Size parameter is ignored. The data disk is created with the size of the specified snapshot. Use snapshots that were created on or after July 15, 2013. Otherwise, an error is returned and your request is rejected.

DataDisk.N.Device

String

No

/dev/xvdb

The mount point of data disk N.

Note

This parameter is applicable to scenarios in which a full image is used to create instances. A full image is an image that contains an operating system, application software, and business data. For these scenarios, you can set this parameter to the mount point of data disk N contained in the full image and modify the DataDisk.N.Size and DataDisk.N.Category parameters to change the category and size of data disk N created based on the image.

DataDisk.N.Size

Integer

No

2000

The size of data disk N. Valid values of N: 1 to 16. Unit: GiB. Valid values:

  • Valid values when DataDisk.N.Category is set to cloud_efficiency: 20 to 32768.

  • Valid values when DataDisk.N.Category is set to cloud_ssd: 20 to 32768.

  • Valid values when DataDisk.N.Category is set to cloud_essd: depends on the value of DataDisk.N.PerformanceLevel.

    • Valid values when DataDisk.N.PerformanceLevel is set to PL0: 40 to 32768.

    • Valid values when the PerformanceLevel parameter is set to PL1: 20 to 32768.

    • Valid values when the PerformanceLevel parameter is set to PL2: 461 to 32768.

    • Valid values when the DataDisk.N.PerformanceLevel parameter is set to PL3: 1261 to 32768.

  • Valid values when DataDisk.N.Category is set to cloud: 5 to 2000.

  • Valid values when DataDisk.N.Category is set to cloud_auto: 40 to 32768.

The value of this parameter must be greater than or equal to the size of the snapshot specified by the SnapshotId parameter.

DataDisk.N.DiskName

String

No

cloud_ssdData

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

DataDisk.N.Category

String

No

cloud_ssd

The category of data disk N. Valid values:

  • cloud_efficiency: ultra disk

  • cloud_ssd: standard SSD

  • cloud_essd: ESSD

  • cloud: basic disk

  • cloud_auto: ESSD AutoPL disk

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

DataDisk.N.EncryptAlgorithm

String

No

null

Note

This parameter is not publicly available.

DataDisk.N.DeleteWithInstance

Boolean

No

true

Specifies whether to release data disk N when the instance is released. Valid values:

  • true

  • false

Default value: true.

DataDisk.N.KMSKeyId

String

No

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

The ID of the Key Management Service (KMS) key to use for data disk N.

DataDisk.N.StorageClusterId

String

No

dbsc-j5e1sf2vaf5he8m2****

The ID of the dedicated block storage cluster. If you want to use a disk in a dedicated block storage cluster as data disk N when you create the instance, you must specify this parameter.

DataDisk.N.ProvisionedIops

Long

No

40000

The provisioned read/write IOPS of the ESSD AutoPL disk to use as data disk N. Valid values: 0 to min{50,000, 1,000 × Capacity - Baseline IOPS}

Baseline IOPS = min{1,800 + 50 × Capacity, 50,000}

Note

This parameter is available only if DataDisk.N.Category is set to cloud_auto. For more information, see ESSD AutoPL disks.

DataDisk.N.BurstingEnabled

Boolean

No

false

Specifies whether to enable the performance burst feature for data disk N. Valid values:

  • true

  • false

Note

This parameter is available only if DataDisk.N.Category is set to cloud_auto. For more information, see ESSD AutoPL disks.

Arn.N.RoleType

String

No

null

This parameter is not publicly available.

Arn.N.Rolearn

String

No

null

This parameter is not publicly available.

Arn.N.AssumeRoleFor

Long

No

0

This parameter is not publicly available.

NetworkInterface.N.VSwitchId

String

No

vsw-bp67acfmxazb4p****

The ID of the vSwitch to which to connect ENI N.

Take note of the following items:

  • Valid values of N: 1 and 2. If the value of N is 1, you can configure a primary or secondary ENI. If the value of N is 2, you must configure a primary ENI and a secondary ENI.

  • If NetworkInterface.N.InstanceType is set to Primary, you must set this parameter. In this case, this parameter is equivalent to VSwitchId. You cannot specify both NetworkInterface.N.VSwitchId and VSwitchId.

  • If NetworkInterface.N.InstanceType is set to Secondary or left empty, this parameter is optional. The default value is the VSwitchId value.

NetworkInterface.N.NetworkInterfaceName

String

No

Network_Name

The name of ENI N.

Take note of the following items:

  • Valid values of N: 1 and 2. If the value of N is 1, you can configure a primary or secondary ENI. If the value of N is 2, you must configure a primary ENI and a secondary ENI.

  • If NetworkInterface.N.InstanceType is set to Primary, you do not need to set this parameter.

NetworkInterface.N.Description

String

No

Network_Description

The description of ENI N.

Take note of the following items:

  • Valid values of N: 1 and 2. If the value of N is 1, you can configure a primary or secondary ENI. If the value of N is 2, you must configure a primary ENI and a secondary ENI.

  • The description must be 2 to 256 characters in length and cannot start with http:// or https://.

  • If NetworkInterface.N.InstanceType is set to Primary, you do not need to set this parameter.

NetworkInterface.N.SecurityGroupId

String

No

sg-bp67acfmxazb4p****

The ID of the security group to which to assign ENI N.

Take note of the following items:

  • Valid values of N: 1 and 2. If the value of N is 1, you can configure a primary or secondary ENI. If the value of N is 2, you must configure a primary ENI and a secondary ENI.

  • If NetworkInterface.N.InstanceType is set to Primary, you must set this parameter. In this case, this parameter is equivalent to SecurityGroupId. You cannot specify SecurityGroupId, SecurityGroupIds.N, or NetworkInterface.N.SecurityGroupIds.N.

  • If NetworkInterface.N.InstanceType is set to Secondary or left empty, this parameter is optional. The default value is the ID of the security group to which the instance belongs.

NetworkInterface.N.PrimaryIpAddress

String

No

172.16.**.**

The primary IP address to assign to ENI N.

Take note of the following items:

  • Valid values of N: 1 and 2.

    • If the value of N is 1, you can configure a primary or secondary ENI. If this parameter is specified, Amount is set to a numeric value greater than 1, and NetworkInterface.N.InstanceType is set to Primary, the specified number of instances are created and consecutive primary IP addresses starting from the specified one are assigned to the instances. In this case, you cannot attach secondary ENIs to the instances.

    • If the value of N is 2, you must configure a primary ENI and a secondary ENI. If this parameter is specified, Amount is set to a numeric value greater than 1, and NetworkInterface.N.InstanceType is set to Primary, you cannot set NetworkInterface.2.InstanceType to Secondary to attach a secondary ENI.

  • If NetworkInterface.N.InstanceType is set to Primary, this parameter is equivalent to PrivateIpAddress and you cannot specify both NetworkInterface.N.PrimaryIpAddress and PrivateIpAddress.

  • If NetworkInterface.N.InstanceType is set to Secondary or left empty, the specified primary IP address is assigned to the secondary ENI. The default value is an IP address that is randomly selected from within the CIDR block of the vSwitch to which to connect the secondary ENI.

Note

You can attach only a single secondary ENI when you create an instance. After the instance is created, you can call the CreateNetworkInterface and AttachNetworkInterface operations to attach more secondary ENIs.

NetworkInterface.N.QueueNumber

Integer

No

8

The number of queues supported by ENI N.

Take note of the following items:

  • Valid values of N: 1 and 2. If the value of N is 1, you can configure a primary or secondary ENI. If the value of N is 2, you must configure a primary ENI and a secondary ENI.

  • The value of this parameter cannot exceed the maximum number of queues per ENI allowed for the instance type.

  • The total number of queues for all ENIs on the instance cannot exceed the queue quota for the instance type. To learn the maximum number of queues per ENI and the queue quota for an instance type, you can call the DescribeInstanceTypes operation to query the MaximumQueueNumberPerEni and TotalEniQueueQuantity values.

  • If this parameter is set and NetworkInterface.N.InstanceType is set to Primary, you cannot specify NetworkInterfaceQueueNumber.

NetworkInterface.N.SecurityGroupIds.N

String

No

sg-bp15ed6xe1yxeycg7****

The ID of security group N to which to assign ENI N.

  • Valid values of the first N: 1 and 2. If the value of N is 1, you can configure a primary or secondary ENI. If the value of N is 2, you must configure a primary ENI and a secondary ENI.

  • The second N indicates that one or more security group IDs can be specified. The valid values of N vary based on the maximum number of security groups to which an instance can belong. For more information, see the "Security group limits" section in Limits.

Take note of the following items:

  • If NetworkInterface.N.InstanceType is set to Primary, you must specify this parameter or NetworkInterface.N.SecurityGroupId. In this case, this parameter is equivalent to SecurityGroupIds.N. You cannot specify SecurityGroupId, SecurityGroupIds.N, or NetworkInterface.N.SecurityGroupId.

  • If NetworkInterface.N.InstanceType is set to Secondary or left empty, this parameter is optional. The default value is the ID of the security group to which to assign the instance.

NetworkInterface.N.NetworkInterfaceTrafficMode

String

No

Standard

The communication mode of ENI N. Valid values:

  • Standard: uses the TCP communication mode.

  • HighPerformance: enables Elastic RDMA Interface (ERI) and uses the remote direct memory access (RDMA) communication mode.

Default value: Standard.

Note

The number of ERIs on an instance cannot exceed the maximum number of ERIs that the instance type supports. For more information, see Overview of instance families.

NetworkInterface.N.QueuePairNumber

Long

No

0

The number of queues supported by the ERI.

NetworkInterface.N.InstanceType

String

No

Secondary

The type of ENI N. Valid values of N: 1 and 2. If the value of N is 1, you can configure a primary or secondary ENI. If the value of N is 2, you must configure a primary ENI and a secondary ENI.

Valid values:

  • Primary

  • Secondary

Default value: Secondary.

NetworkInterface.N.Ipv6AddressCount

Long

No

1

The number of IPv6 addresses to randomly generate for the primary ENI. Valid values: 1 to 10.

Take note of the following items:

  • This parameter is valid only when NetworkInterface.N.InstanceType is set to Primary. If NetworkInterface.N.InstanceType is set to Secondary or left empty, you cannot set this parameter.

  • If this parameter is specified, you cannot specify Ipv6AddressCount, Ipv6Address.N, or NetworkInterface.N.Ipv6Address.N.

NetworkInterface.N.Ipv6Address.N

String

No

2001:db8:1234:1a00::***

IPv6 address N to assign to the primary ENI. Up to 10 IPv6 addresses can be assigned to the primary ENI. Valid values of the second N: 1 to 10.

Example: Ipv6Address.1=2001:db8:1234:1a00::***.

Take note of the following items:

  • This parameter is valid only when NetworkInterface.N.InstanceType is set to Primary. If NetworkInterface.N.InstanceType is set to Secondary or left empty, you cannot set this parameter.

  • If you specify this parameter, you must set Amount to 1 and cannot specify Ipv6AddressCount, Ipv6Address.N, or NetworkInterface.N.Ipv6AddressCount.

NetworkInterface.N.NetworkCardIndex

Integer

No

0

The index of the network card for ENI N.

Take note of the following items:

  • You can specify network card indexes only for instances of specific instance types.

  • When NetworkInterface.N.InstanceType is set to Primary, you can set NetworkInterface.N.NetworkCardIndex only to 0 for instance types that support network cards.

  • When NetworkInterface.N.InstanceType is set to Secondary or left empty, you can set NetworkInterface.N.NetworkCardIndex based on instance types if the instance types support network cards. For more information, see Overview of instance families.

Tag.N.Key

String

No

TestKey

The key of tag N to add to the instance, disks, and primary ENI. 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 acs: or aliyun. It cannot contain http:// or https://.

Tag.N.Value

String

No

TestValue

The value of tag N to add to the instance, disks, and primary ENI. 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: or contain http:// or https://.

Ipv6Address.N

String

No

2001:db8:1234:1a00::***

IPv6 address N to assign to the primary ENI. Valid values of N: 1 to 10.

Example: Ipv6Address.1=2001:db8:1234:1a00::***.

Take note of the following items:

  • If the Ipv6Address.N parameter is specified, you must set Amount to 1 and leave Ipv6AddressCount empty.

  • If NetworkInterface.N.InstanceType is set to Primary, you cannot set Ipv6Addresses.N or Ipv6AddressCount but need to set NetworkInterface.N.Ipv6Addresses.N or NetworkInterface.N.Ipv6AddressCount.

SystemDisk.StorageClusterId

String

No

dbsc-j5e1sf2vaf5he8m2****

The ID of the dedicated block storage cluster. If you want to use disks in a dedicated block storage cluster as system disks when you create instances, you need to specify this parameter.

SystemDisk.ProvisionedIops

Long

No

40000

The provisioned read/write IOPS of the ESSD AutoPL disk to use as the system disk. Valid values: 0 to min{50,000, 1,000 × Capacity - Baseline IOPS}

Baseline IOPS = min{1,800 + 50 × Capacity, 50,000}

Note

This parameter is available only if you set SystemDisk.Category to cloud_auto. For more information, see ESSD AutoPL disks.

SystemDisk.BurstingEnabled

Boolean

No

false

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

  • true

  • false

Note

This parameter is available only if you set SystemDisk.Category to cloud_auto. For more information, see ESSD AutoPL disks.

SystemDisk.Encrypted

String

No

false

Specifies whether to encrypt the system disk. Valid values:

  • true

  • false

Default value: false.

Note

The system disks of instances cannot be encrypted during instance creation in Hong Kong Zone D or Singapore Zone A.

SystemDisk.KMSKeyId

String

No

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

The ID of the KMS key to use for the system disk.

SystemDisk.EncryptAlgorithm

String

No

null

Note

This parameter is not publicly available.

ImageOptions.LoginAsNonRoot

Boolean

No

false

Specifies whether the instance that uses the image supports logons of the ecs-user user. Valid values:

  • true

  • false

NetworkOptions.EnableJumboFrame

Boolean

No

false

Specifies whether to enable the Jumbo Frame feature for the instance. Valid values:

  • false: does not enable the Jumbo Frame feature for the instance. The maximum transmission unit (MTU) value of all ENIs on the instance is set to 1500.

  • true: enables the Jumbo Frame feature for the instance. The MTU value of all ENIs on the instance is set to 8500.

Default value: true.

Note

The Jumbo Frame feature is supported by only 8th-generation or later instance types. For more information, see Set the MTU size of an NIC.

AutoPay

Boolean

No

true

Specifies whether to automatically complete the payment for instance creation. Valid values:

  • true: The payment is automatically completed.

    Note

    Make sure that your account balance is sufficient. Otherwise, your order becomes invalid and is canceled. If your account balance is insufficient, you can set AutoPay to false to generate an unpaid order. Then, you can log on to the ECS console to pay for the order.

  • false: An order is generated but no payment is made.

    Note

    When InstanceChargeType is set to PostPaid, AutoPay cannot be set to false.

Default value: true.

Response parameters

Parameter

Type

Example

Description

RequestId

String

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

The ID of the request.

OrderId

String

123456****

The order ID. This parameter is returned only when InstanceChargeType is set to PrePaid.

TradePrice

Float

0.165

The transaction price.

InstanceIdSets

Array of String

["i-bp67acfmxazb4pd2****", "i-bp1i43l28m7u48p1****", "i-bp12yqg7jdyxl11f****"]

The IDs of the instances (InstanceIdSet).

Examples

Sample requests

http(s)://ecs.aliyuncs.com/?Action=RunInstances
&RegionId=cn-hangzhou
&ImageId=aliyun_2_1903_x64_20G_alibase_20200324.vhd
&InstanceType=ecs.g6.large
&SecurityGroupId=sg-bp67acfmxazb4p****
&VSwitchId=vsw-bp1s5fnvk4gn2tws0****
&SystemDisk.AutoSnapshotPolicyId=sp-bp67acfmxazb4p****
&Amount=3
&<Common request parameters>

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<RunInstancesResponse>
    <RequestId>473469C7-AA6F-4DC5-B3DB-A3DC0DE3****</RequestId>
    <OrderId>123456****</OrderId>
    <TradePrice>0.165</TradePrice>
    <InstanceIdSets>["i-bp67acfmxazb4pd2****", "i-bp1i43l28m7u48p1****", "i-bp12yqg7jdyxl11f****"]</InstanceIdSets>
</RunInstancesResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "RequestId" : "473469C7-AA6F-4DC5-B3DB-A3DC0DE3****",
  "OrderId" : "123456****",
  "TradePrice" : 0.165,
  "InstanceIdSets" : [ "[\"i-bp67acfmxazb4pd2****\", \"i-bp1i43l28m7u48p1****\", \"i-bp12yqg7jdyxl11f****\"]" ]
}

Error codes

HTTP statue code

Error code

Error message

Description

400

LoginAsNonRoot.ImageNotSupport

The specified image does not support login as non-root.

The image does not support logons of non-root users.

400

InsufficientBalance.AgentCredit

Insufficient agent credit. Please contact your agent.

Your credit balance is insufficient. Contact your agent for an adjustment.

400

QuotaExceed.DiskCapacity

The used capacity of disk type has exceeded the quota in the zone, %s.

The capacity of disks that belong to the specified disk category exceeds the quota limit for the zone. You can go to the Quota Center to view and increase the quota.

400

InvalidPeriod.ExceededDedicatedHost

Instance expired date can not exceed dedicated host expired date.

The expiration date of the instance is later than that of the dedicated host.

400

InvalidStorageClusterId.CapacityNotEnough

The remaining capacity of the current dedicated storage cluster is less than the size of disk.

The remaining capacity of the dedicated block storage cluster to which the disk belongs is insufficient.

400

InvalidInstanceType.ValueUnauthorized

The specified InstanceType is not authorized.

You are not authorized to use the instance type.

400

InvalidInstanceType.ValueNotSupported

The specified InstanceType beyond the permitted range.

Invalid InstanceType value.

400

InvalidDescription.Malformed

The specified parameter "Description" is not valid.

Invalid Description format. The description must be 2 to 256 characters in length and cannot start with http:// or https://.

400

InvalidInternetChargeType.ValueNotSupported

The specified InternetChargeType is not valid.

Invalid InternetChargeType value.

400

InvalidPasswordParam.Mismatch

The input password should be null when passwdInherit is true.

Password is not left empty when PasswdInherit is set to true.

400

InvalidDataDiskSize.ValueNotSupported

The specified DataDisk.n.Size beyond the permitted range, or the capacity of snapshot exceeds the size limit of the specified disk category.

The DataDisk.N.Size value is invalid, or the snapshot size exceeds the maximum capacity allowed for the disk category.

400

InvalidInnerIpAddress.Unusable

The specified InnerIpAddress is already used or not found in usable ip range.

The specified internal IP address is unavailable.

400

InvalidParameter.Conflict

The specified image does not support the specified instance type.

The image cannot be used for instances of the instance type.

400

ImageNotSupportCloudInit

The specified image does not support cloud-init.

The specified image does not support cloud-init.

400

InvalidSnapshotId.BasedSnapshotTooOld

The specified snapshot is created before 2013-07-15.

The specified snapshot was created before July 15, 2013.

400

QuotaExceed.AfterpayInstance

Living afterpay instances quota exceeded.

The maximum number of active pay-as-you-go instances is exceeded.

400

InvalidInstanceName.Malformed

The specified parameter "InstanceName" is not valid.

Invalid InstanceName value.

400

InvalidParameter.Conflict

The speicified region and cluster do not match.

The specified region and cluster do not correspond to each other.

400

InvalidParameter.Mismatch

Specified security group and virtual switch are not in the same VPC.

The specified security group and vSwitch do not belong to the same VPC.

400

InvalidPrivateIpAddress

Specified private IP address is not in the CIDR block of virtual switch.

The specified private IP address does not fall within the CIDR block of the specified vSwitch.

400

InvalidPrivateIpAddress.Malformed

Specified private IP address is malformed.

Invalid private IP address.

400

InvalidPrivateIpAddress.Duplicated

Specified private IP address is duplicated.

The specified private IP address is already in use. Try a different IP address.

400

QuotaExceeded

Living instances quota exceeded in this VPC.

The maximum number of active instances is exceeded.

400

IncorrectVSwitchStatus

The current status of virtual switch does not support this operation.

The specified vSwitch is in the Pending state and cannot be deleted.

400

InvalidParameter.Mismatch

Specified virtual switch is not in the specified zone.

The specified vSwitch is not found in the specified zone.

400

ResourceNotAvailable

Resource you requested is not available in this region or zone.

VPC is not supported by the specified region or zone.

400

InvalidPeriod

The specified period is not valid.

Invalid Period value.

400

InstanceDiskCategoryLimitExceed

The specified DataDisk.n.Size beyond the permitted range, or the capacity of snapshot exceeds the size limit of the specified disk category.

The DataDisk.N.Size value is invalid, or the snapshot size exceeds the maximum capacity allowed for the disk category.

400

InvalidInstanceType.ValueNotSupported

InternetMaxBandwidthOut should be set.

InternetMaxBandwidthOut is required.

400

InvalidClientToken.ValueNotSupported

The ClientToken provided is invalid.

Invalid ClientToken value.

400

InvalidIoOptimize.ValueNotSupported

The specified IoOptimize is not valid.

Invalid IoOptimized value.

400

InvalidSecurityGroupId.NotFound

The SecurityGroupId provided does not exist in our records.

The specified security group is not found in this account. Check whether the security group ID is correct.

400

InvalidHostName.Malformed

The specified parameter HostName is not valid.

Invalid HostName format.

400

InvalidInternetMaxBandwidthOut.Malformed

The specified parameter internetMaxBandwidthOut is not valid.

Invalid InternetMaxBandwidthOut value.

400

InvalidInternetMaxBandwidthIn.Malformed

The specified parameter internetMaxBandwidthIn is not valid.

Invalid InternetMaxBandwidthIn value.

400

InvalidSnapshotId.NotFound

The specified parameter SnapshotId is not exist.

The specified snapshot is not found. Check whether the snapshsot ID is correct.

400

InvalidTagKey.Malformed

The specified Tag.n.Key is not valid.

Invalid Tag.N.Key value.

400

InvalidTagValue.Malformed

The specified Tag.n.Value is not valid.

Invalid Tag.N.Value value.

400

InvalidTag.Mismatch

The specified Tag.n.Key and Tag.n.Value are not match.

The Tag.N.Key and Tag.N.Value values do not correspond to each other.

400

InvalidTagCount

The specified tags are beyond the permitted range.

The maximum number of tags is exceeded.

400

InvalidMinAmount.Malformed

The specified parameter MinAmount is not valid.

Invalid MinAmount value.

400

InvalidMaxAmount.Malformed

The specified parameter MaxAmount is not valid.

Invalid MaxAmount value.

400

InvalidPrivateIpAddress.Malformed

The specified parameter PrivateIpAddress is not valid.

Invalid PrivateIpAddress value.

400

InvalidInnerIpAddress.Malformed

The specified parameter InnerIpAddress is not valid.

Invalid internal IP address.

400

OperationDenied.QuotaExceed

The quota of tags on resource is beyond permitted range.

The maximum number of tags is exceeded.

400

Account.Arrearage

Your account has been in arrears.

Your account balance is insufficient. Add funds to your account and try again.

400

InvalidUserData.Base64FormatInvalid

The specified UserData is not valid.

Invalid UserData value.

400

InstanceDiskNumber.LimitExceed

The total number of specified disk in an instance exceeds.

The maximum number of disks for the instance is exceeded.

400

InvalidSpotStrategy

The specified SpotStrategy is not valid.

Invalid SpotStrategy value.

400

InvalidSpotPriceLimit

The specified SpotPriceLimitis not valid.

Invalid SpotPriceLimit value.

400

InvalidSpotDuration

The specified SpotDuration is not valid.

Invalid SpotDuration value.

400

InvalidSpotAuthorized

The specified Spot param is unauthorized.

You are not authorized to set SpotDuration.

400

InvalidSpotPrepaid

The specified Spot type is not support PrePay Instance.

Preemptible instances do not support the subscription billing method.

400

InvalidSpotAliUid

The specified UID is not authorized to use SPOT instance.

You are not authorized to create preemptible instances.

400

InvalidParameter.Bandwidth

%s

Invalid bandwidth. Check the parameter values.

400

InvalidDataDiskCategory.ValueNotSupported

%s

Invalid data disk category. %s is a variable. An error message is dynamically returned based on call conditions.

400

InvalidSystemDiskCategory.ValueNotSupported

%s

The system disk category does not support this operation.

400

InvalidParameter.Conflict

%s

Invalid parameter value. Check whether parameter conflicts exist. %s is a variable. An error message is dynamically returned based on call conditions.

400

InvalidInternetChargeType.ValueNotSupported

%s

Invalid InternetChargeType value.

400

InvalidInstanceType.ValueNotSupported

%s

The instance type does not support this operation.

400

RegionUnauthorized

%s

You are not authorized to perform the operation in the region. %s is a variable. An error message is dynamically returned based on call conditions.

400

Zone.NotOnSale

%s

The requested resources are unavailable in the specified zone. %s is a variable. An error message is dynamically returned based on call conditions.

400

InvalidSystemDiskSize.ValueNotSupported

%s

Invalid SystemDisk.Size value.

400

InvalidDataDiskSize.ValueNotSupported

%s

Invalid data disk size. %s is a variable. An error message is dynamically returned based on call conditions.

400

InvalidInstanceType.ElasticNetworkInterfaceNotSupported

The specified instance type does not support Elastic Network Interface, you can not attach Elastic Network Interface to generation I instances.

The specified instance type does not support ENIs.

400

InvalidParameter.EncryptedIllegal

%s

Invalid parameter value. Check whether your encryption operation is supported. %s is a variable. An error message is dynamically returned based on call conditions.

400

InvalidParameter.EncryptedNotSupported

%s

Disks of this disk category cannot be encrypted.

400

InvalidRelationResource.NotFound

The relation resource has been deleted.

The associated resource has been deleted.

400

IncorrectRecycleBinStatus

The operation is not permitted due to resource status.

This operation cannot be performed on the resource in the current state.

400

InvalidHpcClusterId.Unnecessary

The specified HpcClusterId is unnecessary.

HpcClusterId is not required.

400

InvalidVSwitchId.Necessary

The VSwitchId is necessary.

VSwitchId is required.

400

InvalidHpcClusterId.Necessary

The HpcClusterId is necessary.

HpcClusterId is required.

400

InvalidHpcClusterId.NotFound

The specified HpcClusterId is not found.

The specified HpcClusterId value is not found.

400

InvalidHpcClusterId.Creating

The specified HpcClusterId is creating.

The HPC cluster is being created.

400

InvalidSecurityGroup.NotInDefaultVpc

%s

The security group is not in the default VPC.

400

VpcNotFound

Vpc is not found according to the specified VSwitch or the vpc does not belong to you.

No VPC is found based on the specified vSwitch, or the corresponding VPC does not belong to you.

400

InvalidSystemDiskSize.ImageNotSupportResize

The specified image does not support resize.

The specified image does not support resizing.

400

InvalidSpotInterruptionBehavior

%s

Invalid SpotInterruptionBehavior value.

400

InvalidDeploymentOnHost

%s

The instance cannot be deployed in the specified deployment set.

400

InvalidInstanceChargeType.NotSupport

The Dedicated host not support the specified Instance charge type.

This dedicated host does not support instances that use the specified billing method.

400

InvalidDedicatedHostId.NotFound

The specified DedicatedHostId does not exist.

The specified dedicated host is not found.

400

InvalidDedicatedHostStatus.NotSupport

Operation denied due to dedicated host status.

This operation cannot be performed on the dedicated host in the current state.

400

IncorrectDedicatedHostStatus

The current status of the resource does not support this operation.

This operation cannot be performed on the resource in the current state.

400

ChargeTypeViolation.PostPaidDedicatedHost

Prepaid instance onto postpaid dedicated host is not allowed.

Subscription instances cannot be deployed on pay-as-you-go dedicated hosts.

400

InvalidInstanceType.ValueUnauthorized

The specified InstanceType is not authorize.

You are not authorized to use the instance type.

400

DedicatedHostType.Unmatched

The specified DedicatedHostType doesn?t match the instance type.

The specified dedicated host type does not correspond to the specified instance type.

400

MissingParameter

The input parameter ImageId that is mandatory for processing this request is not supplied.

ImageId is required.

400

MissingParameter

The input parameter InstanceType that is mandatory for processing this request is not supplied.

InstanceType is required.

400

InvalidParam.NetworkInterface

%s

Invalid parameter value. Check whether the parameter corresponds to the operation.

400

InvalidParameter.CreditSpecification

The specified CreditSpecification is not supported in this region.

The specified credit specification is not supported in this region.

400

IncorrectVpcStatus

Current VPC status does not support this operation.

This operation cannot be performed on the VPC in the current state.

400

InvalidInstanceType.NotSupported

The specified instanceType is not supported by the deployment set.

The instance type is not supported by the deployment set. Try another instance type.

400

InvalidVpcZone.NotSupported

The specified operation is not allowed in the zone to which your VPC belongs, please try in other zones.

This operation cannot be performed in the region in which the VPC resides. Try another region.

400

IncorrectDefaultVpcStatus

The status of the default VPC is invalid.

Invalid state of the default VPC.

400

InvalidAutoRenewPeriod.ValueNotSupported

The specified autoRenewPeriod is invalid.

Invalid AutoRenewPeriod value.

400

InvalidMarketImageChargeType.NotSupport

The specified chargeType of marketImage is unsupported.

The billing method of the Alibaba Cloud Marketplace image is not supported.

400

InvalidPeriodType.ValueNotSupported

The specified parameter PeriodType is invalid.

Invalid PeriodType value.

400

OperationDenied

The current user does not support this operation.

Your account does not support this operation.

400

IncorrectImageStatus

The specified image is an Alibaba Cloud Marketplace image. The sale of this image has ended. For more information, contact the image service provider.

The specified image is an Alibaba Cloud Marketplace image. The sale of the image ended. For more information, contact the image service provider.

400

InvalidInstanceType.ValueNotSupported

The specified InstanceType does not exist or beyond the permitted range.

The instance type is not found, or you are not authorized to manage instances of the instance type.

400

InvalidParam.Tenancy

The specified Tenancy is invalid.

Invalid Tenancy value.

400

NoAvaliableDedicatedHost

A dedicated host with sufficient available resources cannot be found.

No available dedicated hosts are found.

400

IncorrectVpcStatus

The current status of vpc does not support this operation.

This operation cannot be performed on the VPC in the current state.

400

InvalidParameter.EncryptedIllegal

The specified parameter Encrypted must be true when kmsKeyId is not empty.

The encryption feature is disabled after a KMS key ID is specified.

400

IoOptimized.NotSupported

The specified instance must be IoOptimized instance when kmsKeyId is not empty.

The specified instance must be an I/O optimized one when KMSKeyId is specified.

400

Duplicate.TagKey

The Tag.N.Key contain duplicate key.

The tag key already exists. Tag keys must be unique.

400

JoinedGroupLimitExceed

%s

The maximum number of security groups to which the specified resource can be assigned is exceeded. For more information, see the return value of the %s placeholder in the error message.

400

IncorrectVSwitchStatus

The current status of vSwitch does not support this operation.

This operation cannot be performed on the vSwitch in the current state.

400

InvalidOperation.EniCountExceeded

The maximum number of eni in a enterprise security group is exceeded.

The maximum number of ENIs in the advanced security group is exceeded.

400

AccountForbidden.ProductCreationLimited

The commodity must be officially operated by Aliyun and in pay-as-you-go billing method.

Internal users purchase only pay-as-you-go ECS instances but cannot purchase third-party products such as Alibaba Cloud Marketplace images. Check parameters. Make sure that all parameters meet the conditions and try again.

400

UnexpectedImageFamily.ImageIdSupplied

The input parameter ImageFamily must be null when image id is set.

ImageFamily must be left empty if an image ID is specified.

400

InvalidHttpEndpoint.NotSupported

The specified HttpEndpoint not supported, you can use enabled(default) or disabled.

Invalid HttpEndpoint value. The valid values of this parameter are enabled and disabled. The default value is enabled.

400

InvalidHttpTokens.NotSupported

The specified HttpTokens not supported, you can use optional(default) or required.

Invalid HttpTokens value. The valid values of this parameter are optional and required. The default value is optional.

400

InvalidHttpPutResponseHopLimit.NotSupported

The specified HttpPutResponseHopLimit not supported, more than 1 and less than 64 is reasonable.

Invalid HttpPutResponseHopLimit value. The valid values of this parameter are 1 to 64.

400

InvalidOperation.VpcHasEnabledAdvancedNetworkFeature

The specified vpc has enabled advanced network feature.

Advanced features are enabled for the VPC. You cannot create ECS instances that have low specifications in the VPC.

400

MissingParameter.PrivatePoolOptionsId

The specified PrivatePoolOptions.Id should not be null.

PrivatePoolOptions.Id is required.

400

Invalid.PrivatePoolOptionsId

The specified PrivatePoolOptions.Id is invalid.

Invalid PrivatePoolOptions.Id value.

400

Invalid.PrivatePoolOptionsId

The parameter PrivatePoolOptions.Id should be null when PrivatePoolOptions.MatchCriteria is not Target.

PrivatePoolOptions.Id must be left empty when PrivatePoolOptions.MatchCriteria is set to a value other than Target.

400

DedicatedHostNotSupported

DedicatedHost is not supported for PrivatePool.

The private pool does not support dedicated hosts.

400

SpotNotSupported

Spot is not supported for PrivatePool.

The private pool does not support preemptible instances.

400

ClassicNetworkNotSupported

Classic network is not supported for PrivatePool.

The private pool does not support instances of the classic network type.

400

Invalid.InstanceId

Instance does not exist.

The instance is not found.

400

Invalid.PrivatePoolOptions.MatchCriteria

Target mode does not support this operation.

This operation cannot be performed when PrivatePoolOptions.MatchCriteria is set to Target.

400

MissingParameter.PrivatePoolOptions.Id

The specified PrivatePoolOptions.Id should not be null.

PrivatePoolOptions.Id is required.

400

Invalid.PrivatePoolOptions.Id

The PrivatePool does not exist.

The private pool is not found.

400

Invalid.InstanceType

The InstanceType does not match the PrivatePool.

The specified instance type does not match the private pool.

400

Invalid.InstanceChargeType

The InstanceChargeType does not match the PrivatePool.

The instance billing method does not match the private pool.

400

Invalid.ZoneId

The ZoneId does not match the PrivatePool.

The zone does not match the private pool.

400

Invalid.PrivatePoolOptions.MatchCriteria

The PrivatePoolOptions.MatchCriteria does not match the PrivatePool.

The PrivatePoolOptions.MatchCriteria value does not match the private pool.

400

InvalidPlatform.ValueNotSupported

The Platform does not match the PrivatePool.

The Platform value does not match the private pool.

400

InvalidAliUid

The PrivatePool does not belong to the user of the Instance.

The private pool does not belong to the user who attempted to create the instance.

400

Invalid.InstanceId

The Instance dose not attached to a PrivatePool.

The instance does not match the private pool.

400

ProvisionedIopsForDiskCategoryUnsupported

The specified disk category does not support provisioned iops.

The disk category does not support provisioned IOPS.

400

BurstingEnabledForDiskCategoryUnsupported

The specified disk category does not support bursting enabled.

The disk category does not support the performance burst feature.

400

BurstingEnabledForMultiAttachDiskUnsupported

The multi attach disk does not support bursting enabled.

Disks for which the multi-attach feature is enabled do not support the performance burst feature.

400

ProvisionedIopsForDiskCategoryRequired

The provisioned iops is required for this disk category.

Provisioned IOPS is required for disks of this disk category.

400

NotSupportSnapshotEncrypted.ShareImage

Shared snapshot creating encrypted disks with native snapshot encrypt is not supported.

When you create encrypted disks based on a shared image, only the encryption key provided by the shared image can be used for these disks and you cannot specify encryption keys for the disks.

400

NotSupportSnapshotEncrypted.ImageOwnerAlias

The specified image category does not support creating encrypted disks with native snapshot encrypt.

Images of the image type cannot be used to create encrypted disks that use a different encryption key type as the images.

400

NotSupportSnapshotEncrypted.DiskCategory

The specified disk category does not support creating encrypted disks with native snapshot encrypt.

Disks of the disk category cannot be created based on encrypted snapshots.

400

NoPermission.SystemTag

The operator is not permission for the system tag.

You are not authorized to manage the system tag.

400

InvalidDiskCategory.NotSupported

The specified disk category is not supported.

The disk category does not support the operation.

400

InvalidInstanceType.NotSupported

The specified instanceType does not support confidential computing mode: %s.

The instance type does not support the confidential computing mode.

400

AccountForbidden.AssociatedWithResellerPartner

Your account is associated with your reseller partner. Your account or your reseller partner's account has been forbidden to create orders, please contact your reseller partner.

Your account is associated with a reseller partner. Your account or the account of the reseller partner is not allowed to create orders. Contact the reseller partner.

400

InvalidDestinationZone.DeploymentSetMismatch

Error happened, %s.

Before you can add the instance to a deployment set that uses the low latency deployment strategy, make sure that the instance resides in the same zone as the instances that are already in the deployment set.

400

InvalidAutoPay.PostPaidUnsupported

The specified parameter AutoPay must be set as true for postpaid instance.

AutoPay must be set to true.

401

InvalidRamRole.NotEcsRole

The specified ram role is not authorized for ecs, please check your role policy.

The specified RAM role is not granted permissions to use ECS. Check your role policies.

403

InvalidParams.InstanceNameExceed

The uniqueSuffix takes three naming places, please shorten your InstanceName.

The instance name must be shortened to make space for the incremental suffix specified by UniqueSuffix. The incremental suffix is three characters in length.

403

InvalidParams.HostnameExceed

The uniqueSuffix takes three naming places, please shorten your Hostname.

The instance hostname must be shortened to make space for the incremental suffix specified by UniqueSuffix. The incremental suffix is three characters in length

403

ImageNotSubscribed

The specified image has not be subscribed.

You did not subscribe to the image in Alibaba Cloud Marketplace.

403

InvalidSystemDiskCategory.ValueUnauthorized

The disk category is not authorized.

You are not authorized to use the disk category.

403

InvalidSnapshotId.NotReady

The specified snapshot has not completed yet.

The specified snapshot is being created.

403

InstanceDiskCategoryLimitExceed

The total size of specified disk category in an instance exceeds.

The maximum disk capacity of the category for an instance is exceeded.

403

InvalidDevice.InUse

The specified device has been occupied.

The specified device is occupied.

403

ImageRemovedInMarket

The specified market image is not available, Or the specified user defined image includes product code because it is based on an image subscribed from marketplace, and that image in marketplace includeing exact the same product code has been removed.

The Alibaba Cloud Marketplace image is unavailable, or the custom image contains the product code of the Alibaba Cloud Marketplace image from which the custom image is derived and the Alibaba Cloud Marketplace image was removed from Alibaba Cloud Marketplace.

403

CategoryNotSupported

The specified zone does not offer the specified disk category.

The specified disk category is unavailable in the specified zone.

403

QuotaExceed.PortableCloudDisk

The quota of portable cloud disk exceeds.

The maximum number of removable disks is exceeded.

403

SecurityGroupInstanceLimitExceed

Exceeding the allowed amount of instances of a security group.

The maximum number of instances in the security group is exceeded.

403

NodeControllerUnavailable

The Node Controller is temporarily unavailable.

The node controller is unavailable.

403

RegionUnauthorized

There is no authority to create instance in the specified region.

You are not authorized to create instances in the specified region.

403

CategoryNotSupported

The specified Zone or cluster does not offer the specified disk category.

The specified disk category is unavailable in the specified zone or cluster.

403

InvalidSnapshotId.NotDataDiskSnapshot

The specified snapshot is system disk snapshot.

The specified snapshot is a system disk snapshot.

403

CategoryNotSupported

The specified cluster does not offer the specified disk category.

The specified disk category is unavailable in the specified cluster.

403

Forbbiden

User not authorized to operate on the specified resource.

You are not authorized to perform operations on the resource.

403

DeleteWithInstance.Conflict

The specified disk is not a portable disk and cannot be set to DeleteWithInstance attribute.

The specified disk is not removable and cannot be released along with the instance.

403

InstanceDiskNumLimitExceed

The number of specified disk in an instance exceeds.

The maximum number of disks for an instance is exceeded.

403

IoOptimized.NotSupported

The specified image is not support IoOptimized Instance.

The image does not support I/O optimized instances.

403

InvalidDiskSize.TooSmall

Specified disk size is less than the size of snapshot.

The specified disk size is smaller than the snapshot size.

403

InvalidDiskCategory.Mismatch

The specified disk categories combination is not supported.

The combination of the disk categories is not supported.

403

IoOptimized.NotSupported

Vpc is not support IoOptimized instance.

The VPC does not support I/O optimized instances.

403

InvalidDiskCategory.NotSupported

The specified disk category is not support the specified instance type.

The specified disk category does not support the instance type.

403

InvalidResourceId.NotSupported

The specified ResourceId does not support tagging.

The specified resource does not support tagging.

403

OperationDenied

The specified RegionId does not support the creation of the network type ECS instance.

Instances of the specified network type cannot be created in the specified region. Check whether instance resources of the network type are available in the region.

403

OperationDenied.ImageNotValid

The specified Image is disabled or is deleted.

The specified image is not found.

403

OperationDenied.SnapshotNotValid

The specified snapshot is not allowed to create disk.

The specified snapshot cannot be used to create disks.

403

OperationDenied.SnapshotNotAllowed

The specified snapshot is not allowed to create disk.

The specified snapshot cannot be used to create disks.

403

OperationDenied.ZoneNotAllowed

The creation of Instance to the specified Zone is not allowed.

Instances cannot be created in the specified zone.

403

OperationDenied.ZoneSystemCategoryNotMatch

The specified Zone or cluster does not offer the specified disk category or the speicified zone and cluster do not match.

The specified disk category is unavailable in the specified zone or cluster, or the specified zone and cluster do not correspond to each other.

403

OperationDenied.ResourceControl

The specified region is in resource control, please try later.

The specified region is under resource control. Try again later.

403

OperationDenied.NoStock

The resource is out of usage.

The instance is not in the Running state. Start the instance or check whether the operation is valid.

403

OperationDenied.SnapshotParamsNotValid

The capacity of snapshot exceeds the size limit of the specified disk category or the specified category is not authorizied.

The maximum snapshot size is exceeded, or you are not authorized to use the specified disk category.

403

Zone.NotOpen

The specified zone is not granted to you to buy resources yet.

You are not authorized to purchase resources in the specified zone.

403

Zone.NotOnSale

The resource in the specified zone is no longer available for sale. Please try other regions and zones.

The specified resource is unavailable in the specified zone. Try another resource type or select another region or zone.

403

InvalidClusterId.NotFound

The specified clusterId does not exist.

The specified cluster ID is not found.

403

OperationDenied.NoStock

The resource is out of stock in the specified zone. Please try other types, or choose other regions and zones.

The specified resource is unavailable in the specified zone. Try another resource type or select another region or zone.

403

InvalidInstanceType.ZoneNotSupported

The specified zone does not support this instancetype.

The specified instance type is not supported in the specified zone.

403

InstanceType.Offline

%s

The operation cannot be performed on the instance while the instance type is retired or while the stock of the instance type is insufficient.

403

DependencyViolation.WindowsInstance

The instance creating is window, cannot use ssh key pair to login.

The specified instance is a Windows instance and does not support logons using SSH key pairs.

403

InvalidUser.PassRoleForbidden

The RAM user does not have the privilege to pass a RAM role.

The RAM user is not authorized to pass a RAM role.

403

Forbidden.RiskControl

This operation is forbidden by Aliyun RiskControl system.

The operation is denied by the Alibaba Cloud Risk Control system.

403

InvalidInstance.UnPaidOrder

The specified Instance has unpaid order.

You have unpaid orders for the specified instance. Pay for the orders and try again.

403

RealNameAuthenticationError

Your account has not passed the real-name authentication yet.

You have not completed real-name verification. Complete real-name verification and try again.

403

InvalidInstanceType.NotSupported

The specified InstanceType is not Supported.

Invalid InstanceType value.

403

InvalidPayMethod

The specified pay method is not valid.

Invalid payment method.

403

InvalidAccountStatus.NotEnoughBalance

Your account does not have enough balance.

The account balance is insufficient. Add funds to your account and try again.

403

ImageNotSupportInstanceType

The specified image does not support the specified InstanceType.

The specified image does not support the specified instance type.

403

OperationDenied.InvalidNetworkType

%s

The network type does not support this operation.

403

InvalidSpotInterruptionBehavior.ClassicNetworkNotSupport

The specified SpotInterruptionBehavior does not support Classic network Instance.

The operation cannot be performed on the instance that resides in the classic network.

403

InvalidSpotInterruptionBehavior.LocalDiskNotSupport

The specified SpotInterruptionBehavior does not support local disk instance.

The operation cannot be performed on the instance that uses local disks.

403

OperationDenied.ImageNotValid

%s

The operation cannot be performed on the image.

403

QuotaExceed.PostPaidDisk

Living postPaid disks quota exceeded.

The maximum number of pay-as-you-go disks is exceeded.

403

InvalidParameter.NotMatch

%s

Invalid parameter value. Check whether parameter conflicts exist.

403

OperationDenied.LocalDiskUnsupported

The configuration change is not allowed when the specified instance has local disks mounted.

The instance types of instances that use local disks cannot be changed.

403

OperationDenied.InconsistentNetwork

The specified security group and vswitch are not in the same vpc.

The specified security group and vSwitch do not belong to the same VPC.

403

OperationDenied

If the network segment of the vswitch is the same as that of its VPC. Therefore, the VPC cannot create other vswitchs across the region.

The VPC and vSwitch have the same CIDR block, and no additional vSwitches can be created in zones of the VPC.

403

DefaultVswitch.Existed

The default vswitch for VPC already exists.

A default vSwitch already exists in the current VPC.

403

OperationDenied.NoStock

The requested resource is sold out in the specified zone; try other types of resources or other regions and zones.

The requested resources are unavailable in the specified zone. Try another instance type or zone. You can call the DescribeZones operation to query available resources.

403

IncorrectInstanceStatus

The current status of the resource does not support this operation.

The operation cannot be performed on the resource in the current state.

403

CategoryViolation

The specified instance does not support this operation because of its disk category.

The configurations of instances that have local disks attached cannot be upgraded or downgraded.

403

ResourcesNotInSameZone

The specified instance and dedicated host are not in the same zone.

The specified instance and dedicated host are not in the same region.

403

InvalidDisk.SystemDiskSize

The specified SystemDiskSize beyond the permitted range.

The maximum system disk size is exceeded.

403

InsufficientBalance

Your account does not have enough balance.

The account balance is insufficient. Add funds to the account and try again.

403

MaxEniIpv6IpsCountExceeded

%s

The maximum number of IPv6 addresses that can be assigned to the ENI is exceeded.

403

InvalidIp.IpRepeated

%s

The IP address already exists.

403

InvalidIp.IpAssigned

%s

The IP address is already assigned.

403

InvalidOperation.Ipv4CountExceeded

%s

The maximum number of IPv4 addresses is exceeded.

403

InvalidOperation.Ipv6CountExceeded

%s

The maximum number of IPv6 addresses is exceeded.

403

InvalidOperation.Ipv6NotSupport

%s

The IPv6 addresses do not support this operation.

403

InvalidVSwitch.Ipv6NotTurnOn

%s

The IPv6 feature is not enabled for your vSwitch. Enable the feature and try again.

403

InvalidParam.Amount

%s

Invalid Amount value.

403

InvalidVSwitchId.IpInvalid

%s

Invalid private IP address.

403

Forbidden.RegionId

%s

The service is unavailable in the current region.

403

InvalidChargeType.ValueNotSupported

Deletion protection is only valid for postPaid instance, not for prePaid or spot instance.

Release protection can be enabled only for pay-as-you-go instances.

403

InvalidRegion.NotSupport

The specified region does not support byok.

The Bring Your Own Key (BYOK) feature is not supported in the specified region.

403

UserNotInTheWhiteList

The user is not in byok white list.

You are not authorized to use the BYOK feature. Try again when you are authorized.

403

InvalidParameter.KMSKeyId.CMKNotEnabled

The CMK needs to be enabled.

The customer master key (CMK) is not enabled when the ID of the CMK is specified for a disk. You can call the DescribeKey operation of KMS to query the information about the CMK.

403

InvalidParameter.KMSKeyId.KMSUnauthorized

ECS service have no right to access your KMS.

ECS is not authorized to access your KMS resources.

403

SecurityRisk.3DVerification

We have detected a security risk with your default credit or debit card. Please proceed with verification via the link in your email.

Risks are detected in your default credit card or debit card. Click the URL in the email for verification.

403

QuotaExceed.Tags

%s

The maximum number of tags is exceeded. %s is a variable. An error message is dynamically returned based on call conditions.

403

OperationDenied.CloudSSDNotSupported

The specified available zone does not offer the cloud_ssd disk, use cloud_essd instead.

Standard SSDs are not supported in the specified zone. Change the parameter value to cloud_essd and try again.

403

QuotaExceed.ElasticQuota

No additional quota is available for the specified ECS instance type.

The maximum number of instances of the specified instance type in the region is exceeded. Try another region or instance type, or reduce the number of instances that you want to create. You can also go to the ECS console or the Quota Center to request a quota increase.

403

QuotaExceed.ElasticQuota

The number of the specified ECS instances has exceeded the quota of the specified instance type.Please sign-on to Alibaba Cloud Console, and submit a quota increase application.

The maximum number of instances of the specified instance type is exceeded. Log on to the Alibaba Cloud Management Console to request a quota increase.

403

QuotaExceed.ElasticQuota

The number of vCPUs assigned to the ECS instances has exceeded the quota in the zone. Please sign-on to Alibaba Cloud Console, and submit a quota increase application.

The maximum number of vCPUs for the instance type is exceeded. Log on to the Alibaba Cloud Management Console to request a quota increase.

403

QuotaExceed.ElasticQuota

The number of the specified ECS instances has exceeded the quota of the specified instance type, or the number of vCPUs assigned to the ECS instances has exceeded the quota in the zone. Please go to submit a quota increase application.

The maximum number of instances or vCPUs for the specified instance type is exceeded. Log on to the Alibaba Cloud Management Console to request a quota increase.

403

QuotaExceeded.PostpaidDataDiskCapacity

The quota of postpaid data disk capacity exceeds.

The capacity of pay-as-you-go data disks exceeds the quota limit.

403

InvalidOperation.ResourceManagedByCloudProduct

%s

The security groups managed by cloud services cannot be modified.

403

InvalidParameter.InvalidEniQueueNumber

%s

Invalid number of queues for an ENI. For more information, see the return value of the %s placeholder in the error message.

403

InvalidOperation.MaxEniQueueNumberExceeded

%s

The maximum number of queues per ENI is exceeded. For more information, see the return value of the %s placeholder in the error message.

403

InvalidOperation.ExceedInstanceTypeQueueNumber

%s

The maximum number of queues for all ENIs on an instance is exceeded. For more information, see the return value of the %s placeholder in the error message.

403

HibernationConfigured.InstanceOperationForbidden

The operation is not permitted due to limit of the hibernation configured instance.

The operation cannot be performed due to the limitations of instances for which the instance hibernation feature is enabled.

403

InvalidInstanceType.NotSupportDiskCategory

The instanceType of the specified instance does not support this disk category.

The specified instance type does not support the disk categories of the instance. Try another instance type. For information about the disk categories supported by instance types, see the instance family documentation.

403

InvalidOperation.ConfidentialComputingModeInInviteOnlyTesting

The specified confidential computing mode is in invite only testing: %s.

The specified confidential computing mode is in invitational preview.

404

InvalidSecurityGroupId

The specified SecurityGroupId is invalid or does not exist.

The specified security group ID is invalid or not found.

404

InvalidClusterId.NotFound

The ClusterId provided does not exist in our records.

The specified cluster ID is not found.

404

InvalidVSwitchId.NotFound

Specified virtual switch does not exist.

The specified vSwitch ID is not found.

404

InvalidVSwitchId.NotFound

%s

The vSwitch ID is not found.

404

InvalidImageId.NotFound

The specified ImageId does not exist.

The image is not found in this account. Check whether the image ID is correct.

404

InvalidInstanceChargeType.NotFound

The InstanceChargeType does not exist in our records.

The instance billing method is not found.

404

DependencyViolation.IoOptimized

The specified instancetype must be IoOptimized instance.

The instance type is not I/O optimized.

404

PaymentMethodNotFound

No payment method has been registered on the account.

You have not configured a payment method for your account.

404

InvalidSystemDiskSize.LessThanImageSize

The specified parameter SystemDisk.Size is less than the image size.

The system disk size is smaller than the image size.

404

InvalidSystemDiskSize.LessThanMinSize

The specified parameter SystemDisk.Size is less than the min size.

The specified system disk size is smaller than the minimum allowable size.

404

InvalidSystemDiskSize.MoreThanMaxSize

The specified parameter SystemDisk.Size is more than the max size.

The maximum system disk size is exceeded.

404

InvalidZoneId.NotFound

The specified zoneId does not exist.

The specified zone ID is not found.

404

InvalidKeyPairName.NotFound

The specified parameter KeyPairName does not exist in our records.

The specified key pair is not found.

404

InvalidResourceGroup.NotFound

The ResourceGroup provided does not exist in our records.

The resource group is not found.

404

InvalidLaunchTemplate.NotFound

%s

The specified launch template is not found. Check whether the parameter value is correct.

404

InvalidLaunchTemplateVersion.NotFound

%s

The specified version of the launch template is not found. Check whether the parameter values are correct.

404

InvalidVSwitchId.NotExist

%s

The vSwitch ID is not found.

404

InvalidMarketImage.NotFound

The specified marketplace image does not exist, please change the imageId and try again.

The Alibaba Cloud Marketplace image is not found. Change the ImageId value and try again.

404

DeploymentSet.NotFound

The specified deployment set does not exist.

The specified deployment set is not found.

404

InvalidParameter.KMSKeyId.NotFound

The specified KMSKeyId does not exist.

The specified KMS key ID is not found

404

InvalidSecurityGroupId.NotFound

%s

The specified security group ID is not found.

404

InvalidDiskIds.NotPortable

The specified DiskId is not portable.

The specified disk is not removable.

500

InternalError

The request processing has failed due to some unknown error.

An internal error occurred. Try again later.

500

InternalError

The request processing has failed due to some unknown error, exception or failure.

An internal error occurred. Try again later.

For a list of error codes, see Service error codes.