I'm having trouble seeing one of my pods when using 'kubectl get pod'. Despite this, the pod is actively pushing logs to ElasticSearch, which I can view in Kibana. Interestingly, when I check through ArgoCD, I can't find the 'missing' pod or its replica set either. However, there is another existing replica set and pod that I can see. Does anyone have any ideas on why this is happening?
4 Answers
Make sure you’re checking in the right namespace and cluster. Sometimes pods are created in different namespaces, and if you don't specify that, you might miss it completely. You can check all namespaces using the '-A' flag with your command. Just to be safe, double-check that you're on the correct context too!
You might want to dig deeper with 'crictl' directly on the node where you think the pod was running. Sometimes 'kubectl' doesn't show everything, and 'crictl' can give you a clearer picture of what's happening on the node.
It’s worth checking the containers and processes related to the pod. Sometimes the pod might exist in a terminated state, or there could be an issue with how the containers are reporting back to the control plane.
Check the logs in Kibana for any Kubernetes metadata like namespace info. This can help you figure out if the pod is being reported in a way that's not showing up with 'kubectl'. Also, consider if you might have inadvertently deleted the pod forcefully without realizing it.
I checked all namespaces and even did a grep on the pod name, but no luck. I’m confident I'm in the right cluster.