文章目录

问题描述

Unable to connect to the server: x509: certificate signed by unknown authority (possibly because of “crypto/rsa: verification error” while trying to verify candidate authority certificate “kubernetes”)

Kubernetes常见问题_01_by unknown authority (possibly because of “crypto/rsa: verification error“_解决方案


Kubernetes常见问题_01_by unknown authority (possibly because of “crypto/rsa: verification error“_kubernetes_02

小结:kubelet服务正常,docker容器看到静态pod也正常,但是kubectl命令使用不了


原因分析

kubernetes集群 = 每个节点上的kubelet服务 + 静态Pod

现在kubelet服务没有问题,也找到哪个静态pod的问题,这种零碎问题, 干脆重装用那个小重装的方案为好

解决方案

kubeadm reset
rm -rf /etc/cni
kubeadm init --kubernetes-version=v1.14.0 --pod-network-cidr=10.244.0.0/16 \
--service-cidr=10.96.0.0/12 --ignore-preflight-errors=Swap

Kubernetes常见问题_01_by unknown authority (possibly because of “crypto/rsa: verification error“_kubernetes_03

kubectl apply -f https://docs.projectcalico.org/v3.9/manifests/calico.yaml
kubectl get pod -n kube-system

Kubernetes常见问题_01_by unknown authority (possibly because of “crypto/rsa: verification error“_ico_04