How to restart kubernetes master?

2019-08-05 15:13发布

问题:

I'd like to restart the actual Kubernetes master related processes / services.

So this would relate to kubelete / scheduler etc etc.

How can this be done?

回答1:

I think this should help:

for SERVICES in etcd kube-apiserver kube-controller-manager kube-scheduler flanneld; do
    systemctl restart $SERVICES
    systemctl enable $SERVICES
    systemctl status $SERVICES
done

And

for SERVICES in kube-proxy kubelet flanneld docker; do
    systemctl restart $SERVICES
    systemctl enable $SERVICES
    systemctl status $SERVICES
done

Credit for this goes to BrandonPotter/restart-kubectl-master-services



标签: kubernetes