You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
= Creating a machine pool with Capacity Reservations using the {rosa-cli}
8
8
9
+
[role="_abstract"]
9
10
You can create a new machine pool with Capacity Reservations by using the {rosa-cli-first}. Both On-Demand Capacity Reservations and Capacity Blocks for ML are supported.
10
11
11
12
[NOTE]
12
13
====
13
-
Currently, upgrading machine pools and enabling autoscaling is not suppored on machine pools with Capacity Reservations.
14
+
Currently, autoscaling is not supported on machine pools with Capacity Reservations.
14
15
====
15
16
16
17
.Prerequisites
17
18
18
-
* You installed and configured the {rosa-cli} version 1.2.57 or above.
19
+
* You installed and configured the latest {rosa-cli}.
19
20
* You logged in to your Red{nbsp}Hat account using the {rosa-cli}.
20
21
* You created a {product-title} cluster version 4.19 or above.
21
22
* The cluster already has a machine pool that is not using a Capacity Reservation or taints. The machine pool must have at least 2 worker nodes.
22
23
* You have a Capacity Reservation ID and capacity is reserved for the instance type required in the Availability Zone (AZ) of the machine pool that you are creating.
23
24
24
25
.Procedure
25
26
26
-
* Create the machine pool and define the instance type, worker node count, and Capacity Reservation ID by running the following command:
27
+
* Create the machine pool and define the Capacity Reservation preference and ID by running the following command:
27
28
+
28
-
--
29
29
[source,terminal]
30
30
----
31
-
$ rosa create machinepool --cluster=<cluster-name> \
31
+
$ rosa create machinepool --cluster=<cluster_name> \
32
32
--name=<machine_pool_id> \
33
33
--replicas=<replica_count> \
34
+
--capacity-reservation-preference none | open | capacity-reservations-only \
*<machine_pool_id>*:: Specifies the name of the machine pool.
42
43
*<replica_count>*:: Specifies the number of provisioned compute nodes. If you deploy {product-title} using a single AZ, this defines the number of compute nodes provisioned to the machine pool for the AZ. If you deploy your cluster using multiple AZs, this defines the total number of compute nodes provisioned across all AZs. For multi-zone clusters, the compute node count must be a multiple of 3. The `--replicas` argument is required when autoscaling is not configured.
44
+
*<capacity_reservation_preference>*:: Specifies the Capacity Reservation behaviour. Valid preferences include:
45
+
46
+
* `none`: The instance does not use a Capacity Reservation even if one is available. The instance runs as an EC2 On-Demand instance. Choose this option when you want to avoid consuming purchased reserved capacity and use it for other workloads.
47
+
* `open`: The instance can run in any `open` Capacity Reservation that has matching attributes such as the instance type, platform, AZ, or tenancy. Choose this option for flexibility; if a reservation is not available, the instance can use regular unreserved EC2 capacity.
48
+
* `capacity-reservations-only`: The instance can only run in a Capacity Reservation. If capacity is not available, the instance fails to launch.
49
+
43
50
*cr-<capacity_reservation_id>*:: Specifies the reservation ID. You get an ID in the `cr-<capacity_reservation_id>` format when you purchase a Capacity Reservation from AWS. The ID can be for both On-Demand Capacity Reservations or Capacity Blocks for ML, you do not need to specify the reservation type.
44
51
*<instance_type>*:: *Optional*: Specifies the instance type for the compute nodes in your machine pool. The instance type defines the vCPU and memory allocation for each compute node in the pool. Replace `<instance_type>` with an instance type. The default is `m5.xlarge`. You cannot change the instance type for a machine pool after the pool is created.
45
-
*<subnet_id>*:: *Optional*: Specifies the subnet ID. For Bring Your Own Virtual Private Cloud (BYO VPC) clusters, you can select a subnet to create a single-AZ machine pool. If you select a subnet that was not specified during the initial cluster creation, you must tag the subnet with the `kubernetes.io/cluster/<infra-id>` key and `shared` value. Customers can obtain the Infra ID by running the following command:
52
+
*<subnet_id>*:: *Optional*: Specifies the subnet ID. For Bring Your Own Virtual Private Cloud (BYO VPC) clusters, you can select a subnet to create a single-AZ machine pool. If you select a subnet that was not specified during the initial cluster creation, you must tag the subnet with the `kubernetes.io/cluster/<infra_id>` key and `shared` value. Customers can obtain the Infra ID by running the following command:
This document describes how to manage compute (also known as worker) nodes with {product-title}.
8
+
[role="_abstract"]
9
+
With {product-title}, you can manage compute (also known as worker) nodes to create and configure optimal compute capacity for your workloads.
9
10
10
11
The majority of changes for compute nodes are configured on machine pools. A machine pool is a group of compute nodes in a cluster that have the same configuration, providing ease of management.
11
12
@@ -24,13 +25,12 @@ Once you configure Capacity Reservations in {product-title}, you can use your AW
24
25
25
26
Using Capacity Reservations on machine pools in {product-title} clusters has the following prerequisites and limitations:
26
27
27
-
* You have installed the {rosa-cli} version 1.2.57 or above.
28
+
* You installed and configured the latest {rosa-cli}.
28
29
* Your {product-title} cluster is version 4.19 or later.
29
30
* The cluster already has a machine pool that is not using a Capacity Reservation or taints. The machine pool must have at least 2 worker nodes.
30
31
* You have purchased a Capacity Reservation for the instance type required in the AZ of the machine pool that you are creating.
31
32
* You can only add a Capacity Reservation ID to a new machine pool.
32
33
* You cannot use autoscaling on a machine pool with configured Capacity Reservations.
33
-
* You cannot upgrade a machine pool with configured Capacity Reservations.
34
34
35
35
To create a machine pool with a Capacity Reservation, see xref:../../rosa_cluster_admin/rosa_nodes/rosa-managing-worker-nodes.adoc#creating_machine_pools_cli_capres_rosa-managing-worker-nodes[Creating a machine pool with Capacity Reservations using the {rosa-cli}].
0 commit comments