Day 7/#30daysofK8s

Cordon/Uncordon/Drain

alias k=kubectl

k drain node-1 — it drains the node of all the pods, i.e. deletes all the pods from the node and recreates them on some other node. (What happens when a certain pod cannot be created on any other node coz of taints and tolerations or some other sort of filter?) The node is then marked as unschedulable until the restriction is explicitly removed.

k cordon node-1 — marks the node as unschedulable. But does not delete any existing pods on the node, but does not allow creating new pods on the node either.

k uncordon node-1 — marks the node as schedulable.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store