All Products
Search
Document Center

Elastic High Performance Computing:SetAutoScaleConfig

Last Updated:Apr 09, 2024

Configures the auto scaling settings of a cluster.

Operation description

Usage notes

If the settings in the Queue Configuration section are different from the settings in the Global Configurations section, the former prevails.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

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

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

Request parameters

ParameterTypeRequiredDescriptionExample
ClusterIdstringYes

The cluster ID.

ehpc-hz-FYUr32****
EnableAutoGrowbooleanNo

Specifies whether to enable auto scale-out. Valid values:

  • true: enables auto scale-out.
  • false: disables auto scale-out.

Default value: false.

false
EnableAutoShrinkbooleanNo

Specifies whether to enable auto scale-in. Valid values:

  • true: enables auto scale-in.
  • false: disables auto scale-in.

Default value: false.

false
GrowIntervalInMinutesintegerNo

The interval between two consecutive rounds of scale-out. Unit: minutes.

Valid values: 2 to 10.

Default value: 2.

Note An interval may exist during multiple rounds of a scale-out task or between two consecutive scale-out tasks.
2
ShrinkIntervalInMinutesintegerNo

The interval between two consecutive rounds of scale-in. Unit: minutes.

Valid values: 2 to 10.

Default value: 2.

2
ShrinkIdleTimesintegerNo

The number of consecutive times that a compute node is idle during the resource scale-in check.

Valid values: 2 to 5.

Default value: 3.

If the parameter is set to 3, a compute node is idle more than three consecutive times. In this case, the node is released. If a compute node is idle for longer than 6 minutes continuously, it is released by default. This is because the default value of the ShrinkIntervalInMinutes parameter is 2.

3
GrowTimeoutInMinutesintegerNo

The scale-out timeout period. Unit: minutes.

Valid values: 10 to 60.

Default value: 20.

If the scale-out timeout period has been reached but the scale-out nodes still do not reach the Running state, the system releases them.

20
ExtraNodesGrowRatiointegerNo

The percentage of extra compute nodes. Valid values: 0 to 100.

Default value: 0.

If you need to add 100 compute nodes and the value of the ExtraNodesGrowRatio parameter is 2, 102 compute nodes are added.

0
GrowRatiointegerNo

The percentage of each round of a scale-out task. Valid values: 1 to 100.

Default value: 100.

If you set GrowRatio to 50, the scale-out has two rounds. Each round completes half of the scale-out.

50
MaxNodesInClusterintegerYes

The maximum number of compute nodes that can be added to the cluster. Valid values: 0 to 500.

Default value: 100.

100
ExcludeNodesstringNo

The compute nodes that are excluded from auto scaling tasks. Separate multiple compute nodes with commas (,).

If you want to retain a compute node, you can specify the node as an additional node to retain the node when it is idle.

i-bp19lgqwxb4206t5****,i-bp1g4hvzs9pywrhb****
SpotStrategystringNo

The preemption policy of the compute nodes. Valid values:

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

Default value: NoSpot.

SpotWithPriceLimit
SpotPriceLimitfloatNo

The maximum hourly price of the compute nodes. The value can be accurate to three decimal places. The parameter takes effect only when SpotStrategy is set to SpotWithPriceLimit.

0.062
ImageIdstringNo

The IDs of the images.

Note
  • If both Queues.N.QueueImageId and ImageId are specified, Queues.N.QueueImageId prevails.

  • If you set Queues.N.QueueImageId or ImageId, the parameter that you set takes effect.

  • If you leave both Queues.N.QueueImageId and ImageId empty, the image that was specified when you created the cluster or the last time you scaled out the cluster is used by default.

centos_7_03_64_20G_alibase_201708****
Queuesobject []No

The information about the queue.

QueueImageIdstringNo

The image ID of the queue where the scale-out is performed. Valid values of N: 1 to 8.

Note
  • If you set both Queues.N.QueueImageId and ImageId, Queues.N.QueueImageId prevails.

  • If you set Queues.N.QueueImageId or ImageId, the parameter that you set takes effect.

  • If you leave both Queues.N.QueueImageId and ImageId empty, the image that was specified when you created the cluster or the last time when you scaled out the cluster is used by default.

centos_7_03_64_20G_alibase_201708****
SystemDiskCategorystringNo

The category of the system disk specified for the compute nodes that are added to the queue. Valid values:

  • cloud_efficiency: ultra disk.
  • cloud_ssd: standard SSD.
  • cloud_essd: enhanced SSD (ESSD).
  • cloud: basic disk. Disks of this type are retired.

Valid values of N: 1 to 8.

Default value: cloud_efficiency.

cloud_efficiency
InstanceTypestringNo

The instance type of the compute nodes that are automatically added to the queue. Valid values of N: 1 to 8.

ecs.n1.medium
HostNameSuffixstringNo

The hostname suffix of the host that is used to perform scale-out for the queue. You can manage nodes that have a specified hostname suffix.

Valid values of N: 1 to 8.

000
SpotStrategystringNo

The preemption policy of the compute node that is automatically added to the queue. Valid values of N: 1 to 8.

Valid values:

  • NoSpot: The compute node is created as a pay-as-you-go instance.
  • SpotWithPriceLimit: The compute node is created as a preemptible instance that has a user-defined maximum hourly price.
  • SpotAsPriceGo: The compute node is created as a preemptible instance for which the market price at the time of purchase is used as the bid price.

Default value: NoSpot.

NoSpot
HostNamePrefixstringNo

The hostname prefix of the host that is used to perform scale-out for the queue. You can manage compute nodes that have a specified hostname prefix.

Valid values of N: 1 to 8.

compute
MinNodesInQueueintegerNo

The minimum number of compute nodes that can be removed from the queue. Valid values: 0 to 50.

Valid values of N: 1 to 8.

Default value: 0.

0
SystemDiskSizeintegerNo

The size of the system disk specified for the compute nodes that are added to the queue. Unit: GB.

Valid values: 40 to 500.

Valid values of N: 1 to 8.

Default value: 40.

40
MaxNodesInQueueintegerNo

The maximum number of compute nodes that can be added to the queue. Valid values: 0 to 500.

Valid values of N: 1 to 8.

Default value: 100.

30
EnableAutoShrinkbooleanNo

Specifies whether the queue enables auto scale-in. Valid values:

  • true: enables auto scale-in.
  • false: disables auto scale-in.

Valid values of N: 1 to 8.

Default value: false.

false
QueueNamestringNo

The name of the queue. You can specify 1 to 8 names.

cluster1
EnableAutoGrowbooleanNo

Specifies whether the queue enables auto scale-out. Valid values:

  • true: enables auto scale-out.
  • false: disables auto scale-out.

Valid values of N: 1 to 8.

Default value: false.

false
SystemDiskLevelstringNo

The performance level of the system disk specified for the compute nodes that are added to the queue. Valid values:

  • PL0: An ESSD can deliver up to 10,000 random read/write IOPS.
  • PL1: An ESSD can deliver up to 50,000 random read/write IOPS.
  • PL2: An ESSD can deliver up to 100,000 random read/write IOPS.
  • PL3: An ESSD can deliver up to 1,000,000 random read/write IOPS.

Valid values of N: 1 to 8.

Default value: PL1.

PL1
SpotPriceLimitfloatNo

The maximum hourly price of the compute nodes that are automatically added to the queue. The value can be accurate to three decimal places. The parameter takes effect only when Queues.N.SpotStrategy is set to SpotWithPriceLimit.

Valid values of N: 1 to 8.

0.662
InstanceTypesobject []No

The instance types of the nodes in the queue.

VSwitchIdstringNo

The vSwitch ID of the compute nodes that are automatically added to the queue.

You can specify 1 to 8 IDs.

The vSwitch IDs of N compute nodes in the queue can be set at the same time when auto scaling is performed in the queue. Valid values of N: 0 to 500.

vsw-bp1lfcjbfb099rrjn****
ZoneIdstringNo

The ID of the zone that compute nodes automatically added to the queue belong.

You can specify 1 to 8 IDs.

The zone IDs of N compute nodes in the queue can be set at the same time when auto scaling is performed in the queue. Valid values of N: 0 to 500.

cn-hangzhou-b
SpotPriceLimitfloatNo

The maximum hourly price of the compute nodes that are automatically added to the queue. The value can be accurate to three decimal places. The parameter takes effect only when Queues.N.InstanceTypes.N.SpotStrategy is set to SpotWithPriceLimit.

You can specify the maximum hourly price for 1 to 8 compute nodes.

The maximum hourly prices of N compute nodes in the queue can be set at the same time when auto scaling is performed in the queue. Valid values of N: 0 to 500.

0.660
InstanceTypestringNo

The instance type of the compute nodes that are automatically added to the queue.

You can specify the specification for 1 to 8 nodes.

The instance types of N compute nodes in the queue can be set at the same time when auto scaling is performed in the queue. Valid values of N: 0 to 500.

ecs.n1.tiny
SpotStrategystringNo

The preemption policy for the compute node that is automatically added to the queue. Valid values:

  • NoSpot: The compute node is created as a pay-as-you-go instance.
  • SpotWithPriceLimit: The compute node is created as a preemptible instance that has a user-defined maximum hourly price.
  • SpotAsPriceGo: The compute node is created as a preemptible instance for which the market price at the time of purchase is used as the bid price.

Default value: NoSpot.

You can specify the preemption policy for 1 to 8 compute nodes.

The preemption policies of N compute nodes in the queue can be set at the same time when auto scaling is performed in the queue. Valid values of N: 0 to 500.

SpotWithPriceLimit
SpotDurationintegerNo

The protection period of the preemptible instance. Unit: hours. Valid values: 0 to 1. A value of 0 means that no protection period is specified. Default value: 1.

0
SpotInterruptionBehaviorstringNo

The interruption mode of the preemptible instance. The value can only be Terminate, which indicates that the instance is released.

Terminate
DataDisksobject []No

The list of data disks.

DataDiskSizeintegerNo

The size of the data disk. Unit: GB.

Valid values: 40 to 500.

Default value: 40.

Valid values of N: 0 to 16.

40
DataDiskCategorystringNo

The category of the data disk. Valid values:

  • cloud_efficiency: ultra disk.
  • cloud_ssd: standard SSD.
  • cloud_essd: ESSD.
  • cloud: basic disk.

Default value: cloud_efficiency.

Valid values of N: 0 to 16.

cloud_efficiency
DataDiskDeleteWithInstancebooleanNo

Specifies whether the data disk is released when the node is released. Valid values:

  • true
  • false

Default value: true.

Valid values of N: 0 to 16.

true
DataDiskPerformanceLevelstringNo

The performance level of the ESSD used as the data disk. The parameter takes effect only when the Queues.N.DataDisks.N.DataDiskCategory parameter is set to cloud_essd. Valid values:

  • PL0: An ESSD can deliver up to 10,000 random read/write IOPS.
  • PL1: An ESSD can deliver up to 50,000 random read/write IOPS.
  • PL2: An ESSD can deliver up to 100,000 random read/write IOPS.
  • PL3: An ESSD can deliver up to 1,000,000 random read/write IOPS.

Default value: PL1.

Valid values of N: 0 to 16.

PL1
DataDiskEncryptedbooleanNo

Specifies whether to encrypt the data disk. Valid values:

  • true
  • false

Default value: false.

Valid values of N: 0 to 16.

false
DataDiskKMSKeyIdstringNo

The Key Management Service (KMS) key ID of the data disk.

Valid values of N: 0 to 16.

0e478b7a-4262-4802-b8cb-00d3fb40826X
MaxNodesPerCyclelongNo

The maximum number of compute nodes that can be added in each round of scale-out. Valid values: 0 to 99.

Default value: 0.

20
MinNodesPerCyclelongNo

The minimum number of compute nodes that can be added in each round of scale-out. Valid values: 1 to 99

Default value: 1.

If the number of compute nodes that you want to add in a round is less than the value of this property, the system automatically changes the value of this property to the number of compute nodes that you want to add in a round. This helps ensure that compute nodes can be added as expected.

Note The configuration takes effect only for the minimum compute nodes that can be added in the current round.
5
AutoMinNodesPerCyclebooleanNo

Specifies whether to automatically specify the minimum number of compute nodes that can be added in each round of scale-out. If you set this parameter to true, the minimum number of nodes for each scale-out is equal to the number of nodes required by the job. The maximum number is 99.

false
SortedByInventorybooleanNo

Specifies whether the instances are unordered. Valid values:

  • true
  • false
Note If you set this parameter to true, the system selects instance types in descending order of the number of instances in stock during auto scaling.
false
ComputeEnableHtbooleanNo

Specifies whether to enable hyper-threading for the ECS instance that is used as the compute node.

Note You can only disable hyper-threading for some instance types. The hyper-threading is enabled for ECS instances by default. For more information, see Specify and view CPU options.
true
DnsConfigstringNo

The configurations of DNS.

"{\"DnsType\":\"PrivateZone\",\"DnsName\":\"xxxxx\"}"

Response parameters

ParameterTypeDescriptionExample
object
RequestIdstring

The request ID.

04F0F334-13358736C-A1D7-6C044FE7****

Examples

Sample success responses

JSONformat

{
  "RequestId": "04F0F334-13358736C-A1D7-6C044FE7****"
}

Error codes

HTTP status codeError codeError messageDescription
400InvalidParamsThe specified parameter %s is invalid.The specified parameter %s is invalid.
403InvalidOptThe specified operation is invalid. Please try again later. If the problem still exists, submit a ticket.-
403TooManyComputesThe number of computing nodes exceeds the quota.The number of computing nodes exceeds the quota.
404ClusterNotFoundThe specified cluster does not exist.The specified instance does not exist.
404ImageNotFoundThe specified image does not exist.The specified image does not exist. Please verify the parameter.
406DbErrorA database service error occurred.Database request failed.
407NotAuthorizedYou are not authorized by RAM for this request.The request is not authorized by RAM.
500UnknownErrorAn unknown error occurred.An unknown error occurred.
503ServiceUnavailableThe request has failed due to a temporary failure of the serverThe request has failed due to a temporary failure of the server.

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

Change history

Change timeSummary of changesOperation
2023-08-11The Error code has changedsee changesets
Change itemChange content
Error CodesThe Error code has changed.
    delete Error Codes: 400
    delete Error Codes: 403
    delete Error Codes: 404
    delete Error Codes: 406
    delete Error Codes: 407
    delete Error Codes: 500
    delete Error Codes: 503
2023-07-13The Error code has changed. The request parameters of the API has changedsee changesets
Change itemChange content
Error CodesThe Error code has changed.
    delete Error Codes: 400
    delete Error Codes: 403
    delete Error Codes: 404
    delete Error Codes: 406
    delete Error Codes: 407
    delete Error Codes: 500
    delete Error Codes: 503
Input ParametersThe request parameters of the API has changed.
    Added Input Parameters: DnsConfig
2023-05-23The Error code has changedsee changesets
Change itemChange content
Error CodesThe Error code has changed.
    delete Error Codes: 400
    delete Error Codes: 403
    delete Error Codes: 404
    delete Error Codes: 406
    delete Error Codes: 407
    delete Error Codes: 500
    delete Error Codes: 503
2023-03-28The Error code has changedsee changesets
Change itemChange content
Error CodesThe Error code has changed.
    delete Error Codes: 400
    delete Error Codes: 403
    delete Error Codes: 404
    delete Error Codes: 406
    delete Error Codes: 407
    delete Error Codes: 500
    delete Error Codes: 503
2023-03-28The Error code has changedsee changesets
Change itemChange content
Error CodesThe Error code has changed.
    delete Error Codes: 400
    delete Error Codes: 403
    delete Error Codes: 404
    delete Error Codes: 406
    delete Error Codes: 407
    delete Error Codes: 500
    delete Error Codes: 503
2023-03-15The Error code has changed. The request parameters of the API has changedsee changesets
Change itemChange content
Error CodesThe Error code has changed.
    delete Error Codes: 400
    delete Error Codes: 403
    delete Error Codes: 404
    delete Error Codes: 406
    delete Error Codes: 407
    delete Error Codes: 500
    delete Error Codes: 503
Input ParametersThe request parameters of the API has changed.
    Added Input Parameters: ComputeEnableHt
2021-12-23The Error code has changedsee changesets
Change itemChange content
Error CodesThe Error code has changed.
    delete Error Codes: 400
    delete Error Codes: 403
    delete Error Codes: 404
    delete Error Codes: 406
    delete Error Codes: 407
    delete Error Codes: 500
    delete Error Codes: 503