Last active
August 7, 2019 04:30
-
-
Save Qquanwei/7b28aefb05972abc841471863a064b29 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
docker rm -f $(sudo docker ps -aq); | |
docker volume rm $(sudo docker volume ls -q); | |
rm -rf /etc/ceph \ | |
/etc/cni \ | |
/etc/kubernetes \ | |
/opt/cni \ | |
/opt/rke \ | |
/run/secrets/kubernetes.io \ | |
/run/calico \ | |
/run/flannel \ | |
/var/lib/calico \ | |
/var/lib/etcd \ | |
/var/lib/cni \ | |
/var/lib/kubelet \ | |
/var/lib/rancher/rke/log \ | |
/var/log/containers \ | |
/var/log/pods \ | |
/var/run/calico | |
for mount in $(mount | grep tmpfs | grep '/var/lib/kubelet' | awk '{ print $3 }') /var/lib/kubelet /var/lib/rancher; do umount $mount; done | |
rm -f /var/lib/containerd/io.containerd.metadata.v1.bolt/meta.db | |
sudo systemctl restart containerd | |
sudo systemctl restart docker | |
IPTABLES="/sbin/iptables" | |
cat /proc/net/ip_tables_names | while read table; do | |
$IPTABLES -t $table -L -n | while read c chain rest; do | |
if test "X$c" = "XChain" ; then | |
$IPTABLES -t $table -F $chain | |
fi | |
done | |
$IPTABLES -t $table -X | |
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/bash | |
wget https://github.com/rancher/rke/releases/download/v0.2.6/rke_linux-amd64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
nodes: | |
- address: 192.168.77.129 | |
internal_address: 192.168.77.129 | |
user: quanwei | |
role: [controlplane,worker,etcd] | |
services: | |
etcd: | |
snapshot: true | |
creation: 6h | |
retention: 24h |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment