amelbakry / kubernetes-scripts

Kubernetes scripts to troubleshoot and check the health status of the cluster and deployments
37 stars 36 forks source link

Cluster node status are not correct #5

Open jainpratik163 opened 3 years ago

jainpratik163 commented 3 years ago

From K8s version 1.16v onwards roles of nodes are not coming and due to this below code output is coming as zero

 echo -e "\e[1m\e[39mCluster Node Status:\e[21m"
        echo -e "${BLUE}"ALL Nodes"                      :${GREEN}$nodes"
        echo -e "${BLUE}"Worker Nodes"                   :${GREEN}$worker"
        echo -e "${BLUE}"Master Nodes"                   :${GREEN}$master"
        echo -e "${BLUE}"Nodes Status"                   :${GREEN}$node_status"

output Cluster Node Status: ALL Nodes :19 Worker Nodes :0 Master Nodes :0 Nodes Status :Ready