Chandu:
what is the difference between pod eviction vs pod completion vs pod termination? What are the possible scenarios of a pod gets evicted?
Trung Tran:
Hello @Chandu
Eviction and termination are the same: “Eviction is the process of terminating one or more Pods
on Nodes
.”
https://kubernetes.io/docs/concepts/scheduling-eviction/
The real world scenario of pod
eviction is when we performing cluster upgrade (ex: kubeadm
v 1.x -> v 1.y), before upgrade we need to drain the node (master or worker), this action will mark the node
unschedule-able and evic all pod
(terminate on this node
and kube-scheduler
will place these pods on other ready nodes). By that way the application (pods) will be up & run during the cluster upgrade.
This is part of the CKA so you will see it soon!
Chandu:
Thank you