After you add bare metal hosts and create a managed cluster as described in
Create a MOSK cluster, proceed with associating Kubernetes machines
of your cluster with the previously added bare metal hosts
using the Container Cloud web UI.
To add a Kubernetes machine to a MOSK cluster:
Log in to the Container Cloud web UI with the m:kaas:namespace@operator or
m:kaas:namespace@writer permissions.
Switch to the required project using the Switch Project
action icon located on top of the main left-side navigation panel.
In the Clusters tab, click the required cluster name.
The cluster page with the Machines list opens.
Click Create Machine button.
Fill out the Create New Machine form as required:
Since MCC 2.28.0 (Cluster releases 17.3.0 and 16.3.0)
Name
New machine name. If empty, a name is automatically generated in the
<clusterName>-<machineType>-<uniqueSuffix> format.
Type
Machine type. Select Manager or Worker to
create a Kubernetes manager or worker node.
Caution
The required minimum number of machines:
3 manager nodes for HA
3 worker storage nodes for a minimal Ceph cluster
L2 Template
From the drop-down list, select the previously created L2 template,
if any. For details, see Create L2 templates.
Otherwise, leave the default selection to use the default L2 template
of the cluster.
Note
Before Container Cloud 2.26.0 (Cluster releases 17.1.0 and
16.1.0), if you leave the default selection in the drop-down list,
a preinstalled L2 template is used. Preinstalled templates are
removed in the above-mentioned releases.
Distribution
Operating system to provision the machine. From the drop-down list,
select Ubuntu 22.04 Focal as the machine distribution.
Caution
Do not use the deprecated Ubuntu 20.04 distribution on
greenfield deployments but only on existing clusters based on
Ubuntu 20.04.
Upgrade Index
Optional. A positive numeral value that defines the order of machine
upgrade during a cluster update.
The first machine to upgrade is always one of the control plane machines
with the lowest upgradeIndex. Other control plane machines are upgraded
one by one according to their upgrade indexes.
If the Cluster spec dedicatedControlPlane field is false, worker
machines are upgraded only after the upgrade of all control plane machines
finishes. Otherwise, they are upgraded after the first control plane
machine, concurrently with other control plane machines.
If several machines have the same upgrade index, they have the same priority
during upgrade.
If the value is not set, the machine is automatically assigned a value
of the upgrade index.
Host Configuration
Configuration settings of the bare metal host to be used for the
machine:
Host
From the drop-down list, select the previously created custom bare
metal host to be used for the new machine.
Host Profile
From the drop-down list, select the previously created custom bare
metal host profile, if any. For details, see
Create a custom bare metal host profile. Otherwise, leave the default
selection.
Labels
Add the required node labels for the worker machine to run certain
components on a specific node. For example, for the StackLight nodes
that run OpenSearch and require more resources than a standard node,
add the StackLight label. The list of available node
labels is obtained from allowedNodeLabels of your current
Cluster release.
If the value field is not defined in allowedNodeLabels, from
the drop-down list, select the required label and define an
appropriate custom value for this label to be set to the node. For
example, the node-type label can have the storage-ssd value
to meet the service scheduling logic on a particular machine.
Note
Due to the known issue 23002
fixed in Container Cloud 2.21.0 (Cluster releases 7.11.0 and
11.5.0), a custom value for a predefined node label cannot be set
using the Container Cloud web UI. For a workaround, refer to the
issue description.
Caution
If you deploy StackLight in the HA mode (recommended):
Add the StackLight label to minimum three worker
nodes. Otherwise, StackLight will not be deployed until
the required number of worker nodes is configured with
the StackLight label.
Removal of the StackLight label from worker nodes
along with removal of worker nodes with StackLight
label can cause the StackLight components to become
inaccessible. It is important to correctly maintain the worker
nodes where the StackLight local volumes were provisioned.
For details, see Delete a cluster machine.
If you move the StackLight label to a new worker machine
on an existing cluster, manually deschedule all StackLight components
from the old worker machine, which you remove the StackLight
label from. For details, see Deschedule StackLight Pods from a worker machine.
Note
To add node labels after deploying a worker machine,
navigate to the Machines page, click the
More action icon in the last column of the required
machine field, and select Configure machine.
Before MCC 2.28.0 (Cluster releases 17.2.0, 16.2.0, or earlier)
Count
Specify the number of machines to create. If you create a machine
pool, specify the replicas count of the pool.
Manager
Select Manager or Worker to create a Kubernetes
manager or worker node.
Caution
The required minimum number of machines:
3 manager nodes for HA
3 worker storage nodes for a minimal Ceph cluster
BareMetal Host Label
Assign the role to the new machine(s) to link the machine
to a previously created bare metal host with the corresponding label.
You can assign one role type per machine. The supported labels include:
Manager
This node hosts the manager services of a managed cluster.
For the reliability reasons, Container Cloud does not permit
running end user workloads on the manager nodes or use them
as storage nodes.
Worker
The default role for any node in a managed cluster.
Only the kubelet service is running on the machines of this type.
Upgrade Index
Optional. A positive numeral value that defines the order of machine upgrade
during a cluster update.
The first machine to upgrade is always one of the control plane machines
with the lowest upgradeIndex. Other control plane machines are upgraded
one by one according to their upgrade indexes.
If the Cluster spec dedicatedControlPlane field is false, worker
machines are upgraded only after the upgrade of all control plane machines
finishes. Otherwise, they are upgraded after the first control plane
machine, concurrently with other control plane machines.
If several machines have the same upgrade index, they have the same priority
during upgrade.
If the value is not set, the machine is automatically assigned a value
of the upgrade index.
Distribution
Operating system to provision the machine. From the drop-down list,
select the required Ubuntu distribution:
22.04 since Container Cloud 2.28.0 (Cluster releases 17.3.x and 16.3.x)
20.04 before Container Cloud 2.28.0 (Cluster releases 17.2.x, 16.2.x, or earlier)
Caution
Do not use the deprecated Ubuntu 20.04 distribution on
greenfield deployments but only on existing clusters based on Ubuntu
20.04.
L2 Template
From the drop-down list, select the previously created L2 template,
if any. For details, see Create L2 templates.
Otherwise, leave the default selection to use the default L2 template
of the cluster.
Note
Before Container Cloud 2.26.0 (Cluster releases 17.1.0 and
16.1.0), if you leave the default selection in the drop-down list,
a preinstalled L2 template is used. Preinstalled templates are
removed in the above-mentioned releases.
BM Host Profile
From the drop-down list, select the previously created custom bare metal
host profile, if any. For details, see Create a custom bare metal host profile.
Otherwise, leave the default selection.
Node Labels
Add the required node labels for the worker machine to run certain
components on a specific node. For example, for the StackLight nodes
that run OpenSearch and require more resources than a standard node,
add the StackLight label. The list of available node
labels is obtained from allowedNodeLabels of your current
Cluster release.
If the value field is not defined in allowedNodeLabels, from
the drop-down list, select the required label and define an
appropriate custom value for this label to be set to the node. For
example, the node-type label can have the storage-ssd value
to meet the service scheduling logic on a particular machine.
Note
Due to the known issue 23002
fixed in Container Cloud 2.21.0 (Cluster releases 7.11.0 and
11.5.0), a custom value for a predefined node label cannot be set
using the Container Cloud web UI. For a workaround, refer to the
issue description.
Caution
If you deploy StackLight in the HA mode (recommended):
Add the StackLight label to minimum three worker
nodes. Otherwise, StackLight will not be deployed until
the required number of worker nodes is configured with
the StackLight label.
Removal of the StackLight label from worker nodes
along with removal of worker nodes with StackLight
label can cause the StackLight components to become
inaccessible. It is important to correctly maintain the worker
nodes where the StackLight local volumes were provisioned.
For details, see Delete a cluster machine.
If you move the StackLight label to a new worker machine
on an existing cluster, manually deschedule all StackLight components
from the old worker machine, which you remove the StackLight
label from. For details, see Deschedule StackLight Pods from a worker machine.
Note
To add node labels after deploying a worker machine,
navigate to the Machines page, click the
More action icon in the last column of the required
machine field, and select Configure machine.
Click Create.
At this point, Container Cloud adds the new machine object to the specified
cluster. And the Bare Metal Operator Controller creates the relation to
BareMetalHost with the labels matching the roles.
Provisioning of the newly created machine starts when the machine object is
created and includes the following stages:
Creation of partitions on the local disks as required by the operating
system and the Container Cloud architecture.
Configuration of the network interfaces on the host as required by the
operating system and the Container Cloud architecture.
Installation and configuration of the Container Cloud LCM Agent.
Repeat the steps above for the remaining machines.