一、原题
二、解答
[root@master ~]# kubectl get node
NAME STATUS ROLES AGE VERSION
master Ready control-plane,master 25h v1.22.12
node1 Ready worker 25h v1.22.12
node2 Ready worker 25h v1.22.12
[root@master ~]# kubectl cordon master
node/master cordoned
[root@master ~]# kubectl drain master --delete-emptydir-data --ignore-daemonsets --force
node/master already cordoned
WARNING: ignoring DaemonSet-managed Pods: kube-system/calico-node-nlckp, kube-system/kube-proxy-rlw8p, kube-system/nodelocaldns-dqqhl, kubesphere-monitoring-system/node-export