master

kubectl delete node node32

kubeadm reset

echo "1" >/proc/sys/net/bridge/bridge-nf-call-iptables

kubeadm init --kubernetes-version=v1.16.2 --pod-network-cidr=10.244.0.0/16

export KUBECONFIG=/etc/kubernetes/admin.conf

kubectl apply -f kube-flannel.yml

node

kubeadm reset

重新生成token   kubeadm token create

获取ca证书sha256编码hash值

openssl x509 -pubkey -in /etc/kubernetes/pki/ca.crt | openssl rsa -pubin -outform der 2>/dev/null | openssl dgst -sha256 -hex | sed 's/^.* //'

echo "1" >/proc/sys/net/bridge/bridge-nf-call-iptables

kubeadm join 192.168.88.107:6443 --token mue45i.m627f190awfgxluz \
    --discovery-token-ca-cert-hash sha256:a9c58d3c8de1715a4158d5e63d2fd86cd33aeb8ff9c4f7ea2a3385c7fd0fe886

kubectl apply -f kube-flannel.yml

scp admin.conf 192.168.88.109:/root/.kube/config

 

Logo

K8S/Kubernetes社区为您提供最前沿的新闻资讯和知识内容

更多推荐