This morning I find I lose the connection with my icp4d kubernetes server (it was good last night), if I run:
1 2
# kubectl get pods error:theserverdoesn'thavearesourcetype"pods"
then:
1 2 3 4
# kubectl version Client Version:version.Info{Major:"1",Minor:"12",GitVersion:"v1.12.4+icp-ee",GitCommit:"d03f6421b5463042d87aa0211f116ba4848a0d0f",GitTreeState:"clean",BuildDate:"2019-01-17T13:14:09Z",GoVersion:"go1.10.4",Compiler:"gc",Platform:"linux/amd64"}
I check the docker and kubelet status, all are active:
1 2
systemctl status docker systemctl status kubelet
Then I try to reboot all nodes, and it set up correctly. Don’t know how to reproduce this issue, no idea what happened and how to fix it (without rebooting), sadly.
Server Connection Refused 6443
Similar issue happened again in my dstest cluster:
1 2 3 4 5 6
# kubectl get pods -n test-1 Theconnectiontotheserver9.30.188.95:6443wasrefused-didyouspecifytherighthostorport?
# kubectl version Client Version:version.Info{Major:"1",Minor:"13",GitVersion:"v1.13.2",GitCommit:"cff46ab41ff0bb44d8584413b598ad8360ec1def",GitTreeState:"clean",BuildDate:"2019-01-10T23:35:51Z",GoVersion:"go1.11.4",Compiler:"gc",Platform:"linux/amd64"} Theconnectiontotheserver9.30.188.95:6443wasrefused-didyouspecifytherighthostorport?
Note, there is no kube-apiserver service in systemctl, so how to restart it? The kube-apiserver is from a static pod, so I think I can restart the container directly by docker restart <container ID>:
1 2 3
# docker ps -a | grep apiserver 8f661411fa02177db4b8e93a"kube-apiserver --au..."AboutanhouragoUp4minutesk8s_kube-apiserver_kube-apiserver-dstest1.fyre.ibm.com_kube-system_d175f38c007e23cc443d6ba50ba15533_0 0f05946a8a59k8s.gcr.io/pause:3.1"/pause"AboutanhouragoUpAboutanhourk8s_POD_kube-apiserver-dstest1.fyre.ibm.com_kube-system_d175f38c007e23cc443d6ba50ba15533_0
Haven’t got chance to reproduce this issue, this solution may not work…