$ oc get nodes NAME STATUS ROLES AGE VERSION master-0 Ready master 63m v1.16.2 master-1 Ready master 63m v1.16.2 master-2 Ready master 64m v1.16.2 worker-0 NotReady worker 76s v1.16.2 worker-1 NotReady worker 70s v1.16.2
You can add more compute machines to your OpenShift Container Platform cluster on VMware vSphere.
You can create more compute machines for your cluster that uses user-provisioned infrastructure on VMware vSphere.
Obtain the Base64-encoded Ignition file for your compute machines.
You have access to the vSphere template that you created for your cluster.
After the template deploys, deploy a VM for a machine in the cluster.
Right-click the template’s name and click Clone → Clone to Virtual Machine.
On the Select a name and folder tab, specify a name for the VM. You might
include the machine type in the name, such as compute-1
.
On the Select a name and folder tab, select the name of the folder that you created for the cluster.
On the Select a compute resource tab, select the name of a host in your datacenter.
Optional: On the Select storage tab, customize the storage options.
On the Select clone options, select Customize this virtual machine’s hardware.
On the Customize hardware tab, click VM Options → Advanced.
From the Latency Sensitivity list, select High.
Click Edit Configuration, and on the Configuration Parameters window, click Add Configuration Params. Define the following parameter names and values:
guestinfo.ignition.config.data
: Paste the contents of the Base64-encoded
compute Ignition config file for this machine type.
guestinfo.ignition.config.data.encoding
: Specify base64
.
disk.EnableUUID
: Specify TRUE
.
In the Virtual Hardware panel of the Customize hardware tab, modify the specified values as required. Ensure that the amount of RAM, CPU, and disk storage meets the minimum requirements for the machine type. Also, make sure to select the correct network under Add network adapter if there are multiple networks available.
Complete the configuration and power on the VM.
Continue to create more compute machines for your cluster.
When you add machines to a cluster, two pending certificate signing requests (CSRs) are generated for each machine that you added. You must confirm that these CSRs are approved or, if necessary, approve them yourself.
You added machines to your cluster.
Confirm that the cluster recognizes the machines:
$ oc get nodes NAME STATUS ROLES AGE VERSION master-0 Ready master 63m v1.16.2 master-1 Ready master 63m v1.16.2 master-2 Ready master 64m v1.16.2 worker-0 NotReady worker 76s v1.16.2 worker-1 NotReady worker 70s v1.16.2
The output lists all of the machines that you created.
Review the pending CSRs and ensure that
you see a client and server request with the Pending
or Approved
status for
each machine that you added to the cluster:
$ oc get csr NAME AGE REQUESTOR CONDITION csr-8b2br 15m system:serviceaccount:openshift-machine-config-operator:node-bootstrapper Pending (1) csr-8vnps 15m system:serviceaccount:openshift-machine-config-operator:node-bootstrapper Pending csr-bfd72 5m26s system:node:ip-10-0-50-126.us-east-2.compute.internal Pending (2) csr-c57lv 5m26s system:node:ip-10-0-95-157.us-east-2.compute.internal Pending ...
1 | A client request CSR. |
2 | A server request CSR. |
In this example, two machines are joining the cluster. You might see more approved CSRs in the list.
If the CSRs were not approved, after all of the pending CSRs for the machines
you added are in Pending
status, approve the CSRs for your cluster machines:
Because the CSRs rotate automatically, approve your CSRs within an hour
of adding the machines to the cluster. If you do not approve them within an
hour, the certificates will rotate, and more than two certificates will be
present for each node. You must approve all of these certificates. After you
approve the initial CSRs, the subsequent node client CSRs are automatically
approved by the cluster |
To approve them individually, run the following command for each valid CSR:
$ oc adm certificate approve <csr_name> (1)
1 | <csr_name> is the name of a CSR from the list of current CSRs. |
To approve all pending CSRs, run the following command:
$ oc get csr -o go-template='{{range .items}}{{if not .status}}{{.metadata.name}}{{"\n"}}{{end}}{{end}}' | xargs oc adm certificate approve
For more information on CSRs, see Certificate Signing Requests.