Performing an In-Place Worker Node Update by Manually Replacing Nodes in an Existing Node Pool
You can update the properties of worker nodes in a node pool by changing properties of the existing node pool.
You delete each worker node in turn, selecting appropriate cordon and drain options to prevent new pods starting and to delete existing pods. You start a new worker node to take the place of each worker node you delete. When new worker nodes start in the existing node pool, they have the properties you specified.
Using the Console
To perform an 'in-place' update of a node pool in a cluster:
- In the Console, open the navigation menu and click Developer Services. Under Containers, click Kubernetes Clusters (OKE).
- Choose a Compartment you have permission to work in.
- On the Cluster List page, click the name of the cluster where you want to update worker node properties.
On the Cluster page, display the Node Pools tab, and click the name of the node pool where you want to update worker node properties.
On the Node Pool page, specify the required properties for worker nodes.
Note that if you change the Kubernetes version, the version you specify must be compatible with the version that is running on the control plane nodes. See Upgrading Clusters to Newer Kubernetes Versions.
Click Save changes to save the change.
You now have to delete existing worker nodes so that new worker nodes are started, with the properties you specified.
Recommended: Leverage pod disruption budgets as appropriate for your application to ensure that there's a sufficient number of replica pods running throughout the deletion operation. For more information, see Specifying a Disruption Budget for your Application in the Kubernetes documentation.
For the first worker node in the node pool:
- On the Node Pool page, display the Nodes tab and select Delete Node from the Actions menu beside the node you want to delete.
Either accept the defaults for advanced options, or click Show Advanced Options and specify alternatives as follows:
Cordon and drain: Specify when and how to cordon and drain worker nodes before terminating them.
- Eviction grace period (mins): The length of time to allow to cordon and drain worker nodes before terminating them. Either accept the default (60 minutes), or specify an alternative. For example, you might want to allow 30 minutes to cordon worker nodes and drain them of their workloads. To terminate worker nodes immediately, without cordoning and draining them, specify 0 minutes.
- Force terminate after grace period: Whether to terminate worker nodes at the end of the eviction grace period, even if they have not been successfully cordoned and drained. By default, this option is not selected.
Select this option if you always want worker nodes terminated at the end of the eviction grace period, even if they have not been successfully cordoned and drained.
De-select this option if you do not want worker nodes that have not been successfully cordoned and drained to be terminated at the end of the eviction grace period. Node pools containing worker nodes that could not be terminated within the eviction grace period have the Needs attention status (see Monitoring Clusters). The status of the work request that initiated the termination operation is set to Failed and the termination operation is cancelled.
For more information, see Notes on cordoning and draining managed nodes before termination.
- Click Delete to delete the worker node.
The worker node is deleted. Deleting the worker node also scales down the node pool itself by subtracting 1 from the number of worker nodes specified for the node pool.
- Click Edit (for managed node pools) or Scale (for virtual node pools) and increase the number of worker nodes in the node pool by 1 to replace the worker node you have deleted. A new worker node is started, with the properties you specified.
- Repeat the previous step for each remaining worker node in the node pool, until all worker nodes in the node pool have the required properties.