kubeadm join时出现错误:[ERROR Port-10250]: Port 10250 is in use [ERROR FileAvailable--etc-kubernetes-pki
生活随笔
收集整理的這篇文章主要介紹了
kubeadm join时出现错误:[ERROR Port-10250]: Port 10250 is in use [ERROR FileAvailable--etc-kubernetes-pki
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
kubeadm join時出現錯誤:[ERROR Port-10250]: Port 10250 is in use;[ERROR FileAvailable--etc-kubernetes-pki-ca.crt]: /etc/kubernetes/pki/ca.crt already exists
初次使用kubeadm構建k8s集群,所以對子節點加入管理節點的過程認識不足,導致我先對子節點進行了kubeadm init之后,才準備進行kubeadm join操作。結果出現了如下錯誤:
[root@k8s-node02 ostrich5yw]# kubeadm join 192.168.139.129:6443 --token abcdef.0123456789abcdef \ > --discovery-token-ca-cert-hash sha256:3ac4ae8b5b3b08f2b8cd8a85be7b37bc5855e749ec9126e3d87bebfb2235af9b [preflight] Running pre-flight checks[WARNING SystemVerification]: this Docker version is not on the list of validated versions: 20.10.6. Latest validated version: 18.09 error execution phase preflight: [preflight] Some fatal errors occurred:[ERROR DirAvailable--etc-kubernetes-manifests]: /etc/kubernetes/manifests is not empty[ERROR FileAvailable--etc-kubernetes-kubelet.conf]: /etc/kubernetes/kubelet.conf already exists[ERROR Port-10250]: Port 10250 is in use[ERROR FileAvailable--etc-kubernetes-pki-ca.crt]: /etc/kubernetes/pki/ca.crt already exists [preflight] If you know what you are doing, you can make a check non-fatal with `--ignore-preflight-errors=...`問題原因:只有父節點需要運行kubeadm init --config=kubeadm-config.yaml --upload-certs | tee kubeadm-init.log進行初始化;對于子節點來說,無需進行kubeadm init進行初始化,直接運行kubeadm join加入父節點即可。
解決方法:運行kubeadm reset重置子節點,之后直接對子節點使用kubeadm join 192.168.139.129:6443 --token abcdef.0123456789abcdef --discovery-token-ca-cert-hash sha256:3ac4ae8b5b3b08f2b8cd8a85be7b37bc5855e749ec9126e3d87bebfb2235af9b將其加入對應的父節點中。
總結
以上是生活随笔為你收集整理的kubeadm join时出现错误:[ERROR Port-10250]: Port 10250 is in use [ERROR FileAvailable--etc-kubernetes-pki的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: U盘装XP系统(含截图,2012最新原创
- 下一篇: 什么是套接字?Socket基本介绍