Open
Description
What happened: I'm using kubectl logs command to get the logs of multiple pods of same application using labels. However, it doesn't give logs from all the pods.
What you expected to happen: I should be able to use the -f/--follow option to get the logs from all the pods and use grep/awk with it.
How to reproduce it (as minimally and precisely as possible):
Running multiple replicas of a deployment, try to get the logs using label selector.Anything else we need to know?: NA
Environment:
- Kubernetes client and server versions (use
kubectl version
): v1.29.0 - Cloud provider or hardware configuration: GCP
- OS (e.g:
cat /etc/os-release
):
NAME="Ubuntu"
VERSION="20.04.6 LTS (Focal Fossa)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 20.04.6 LTS"
VERSION_ID="20.04"
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
VERSION_CODENAME=focal
UBUNTU_CODENAME=focal