[compute_resource] section - Amazon ParallelCluster
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

[compute_resource] section

Defines configuration settings for a compute resource. [compute_resource] sections are referenced by the compute_resource_settings setting in the [queue] section. [compute_resource] sections are only supported when scheduler is set to slurm.

The format is [compute_resource <compute-resource-name>]. compute-resource-name must start with a letter, contain no more than 30 characters, and only contain letters, numbers, hyphens (-), and underscores (_).

[compute_resource cr1] instance_type = c5.xlarge min_count = 0 initial_count = 2 max_count = 10 spot_price = 0.5
Note

Support for the [compute_resource] section was added in Amazon ParallelCluster version 2.9.0.

initial_count

(Optional) Sets the initial number of Amazon EC2 instances to launch for this compute resource. Cluster creation doesn't complete until at least this many nodes have been launched into the compute resource. If the compute_type setting for the queue is spot and there aren't enough Spot Instances available, the cluster creation might time out and fail. Any count larger than the min_count setting is dynamic capacity subject to the scaledown_idletime setting. This setting replaces the initial_queue_size setting.

Defaults to 0.

initial_count = 2

Update policy: The compute fleet must be stopped for this setting to be changed for an update.

instance_type

(Required) Defines the Amazon EC2 instance type that's used for this compute resource. The architecture of the instance type must be the same as the architecture used for the master_instance_type setting. The instance_type setting must be unique for each [compute_resource] section referenced by a [queue] section. This setting replaces the compute_instance_type setting.

instance_type = t2.micro

Update policy: The compute fleet must be stopped for this setting to be changed for an update.

max_count

(Optional) Sets the maximum number of Amazon EC2 instances that can be launched in this compute resource. Any count larger than the initial_count setting is started in a power down mode. This setting replaces the max_queue_size setting.

Defaults to 10.

max_count = 10

Update policy: Reducing the size of a queue below the current number of nodes requires that the compute fleet be stopped first.

Note

The update policy did not support changing the max_count setting until the compute fleet was stopped for Amazon ParallelCluster version 2.0.0 through version 2.9.1.

min_count

(Optional) Sets the minimum number of Amazon EC2 instances that can be launched in this compute resource. These nodes are all static capacity. Cluster creation doesn't complete until at least this number of nodes has been launched into the compute resource.

Defaults to 0.

min_count = 1

Update policy: Reducing the number of static nodes in a queue requires that the compute fleet be stopped first.

Note

The update policy did not support changing the min_count setting until the compute fleet was stopped for Amazon ParallelCluster version 2.0.0 through version 2.9.1.

spot_price

(Optional) Sets the maximum Spot price for this compute resource. Used only when the compute_type setting for the queue containing this compute resources is set to spot. This setting replaces the spot_price setting.

If you don't specify a value, you're charged the Spot price, capped at the On-Demand price.

For assistance finding a Spot Instance that meets your needs, see the Spot Instance advisor.

spot_price = 1.50

Update policy: The compute fleet must be stopped for this setting to be changed for an update.