colebrooke / kubernetes-nagios

Basic health checks for a Kubernetes cluster
MIT License
50 stars 44 forks source link

Doesn't detect when node is totally down #12

Closed stefanlasiewski closed 4 years ago

stefanlasiewski commented 4 years ago

The script reports "OK" even if a node is down, if docker is down or if the Kubelet has crashed or entered an error condition.

In this case, I stopped the Kubelet on docker02, but the script says the node is OK.

$ kubectl get nodes
NAME        STATUS       ROLES                      AGE    VERSION
docker01   Ready          controlplane,etcd,worker   421d   v1.17.4
docker02   NotReady   controlplane,etcd,worker   421d   v1.17.4
docker03   Ready          controlplane,etcd,worker   421d   v1.17.4

$ ./check_kube_nodes.sh -k kube_config_cluster.yml
OK - Kubernetes nodes all OK
$