Kubernetes – Reset Cluster

REF: Stack Overflow

james@server-01:~$ more ~/kube_reset.sh
#!/bin/sh
# https://stackoverflow.com/questions/56850650/reset-kubernetes-cluster
sudo kubeadm reset -f &&
 sudo systemctl stop kubelet &&
 sudo systemctl stop docker &&
 sudo rm -rf /var/lib/cni/ &&
 sudo rm -rf /var/lib/kubelet/* &&
 sudo rm -rf /etc/cni/ &&
 sudo ifconfig cni0 down &&
 sudo ifconfig flannel.1 down &&
 sudo ifconfig docker0 down &&
 sudo ip link delete cni0 &&
 sudo ip link delete flannel.1 &&
 sudo rm -rf /var/lib/etcd/* &&
 sudo rm -fr ~/.kube/* &&
 sudo shutdown -r now


Deprecated: Function get_magic_quotes_gpc() is deprecated in /home/hncom/public_html/sandlininc.com/wp-includes/formatting.php on line 4803
This entry was posted in Uncategorized by james. Bookmark the permalink.