通过kubeadm安装好kubernetes v1.20.2 查看集群状态,发现组件controller-manager 和scheduler状态 Unhealthy
检查端口未监听
组件运行正常
检查kube-scheduler和kube-controller-manager组件配置是否禁用了非安全端口 vim /etc/kubernetes/manifests/kube-scheduler.yaml vim /etc/kubernetes/manifests/kube-controller-manager.yaml
将port=0去掉 然后systemctl restart kubelet 再检查集群组件状态已正常