When I run kubectl get pods
on my cluster I only get NAME
and AGE
information. I cannot see anything about READY-STATUS-RESTARTS.
The -o
wide flag doesn't help either.
This is my client version:
Client Version: version.Info{Major:"1", Minor:"16", GitVersion:"v1.16.1", GitCommit:"d647ddbd755faf07169599a625faf302ffc34458", GitTreeState:"clean", BuildDate:"2019-10-02T17:01:15Z", GoVersion:"go1.12.10", Compiler:"gc", Platform:"windows/amd64"}
Server Version: version.Info{Major:"1", Minor:"9", GitVersion:"v1.9.5", GitCommit:"f01a2bf98249a4db383560443a59bed0c13575df", GitTreeState:"clean", BuildDate:"2018-03-19T15:50:45Z", GoVersion:"go1.9.3", Compiler:"gc", Platform:"linux/amd64"}
The problem is your client version.
Change your client version to v1.14.0 using the following commands (on Mac):
curl -LO https://storage.googleapis.com/kubernetes-release/release/v1.14.0/bin/darwin/amd64/kubectl
chmod +x ./kubectl
sudo mv ./kubectl /usr/local/bin/kubectl
And try again
Source: https://kubernetes.io/docs/tasks/tools/install-kubectl/#install-kubectl-on-macos
I had the same issue (I had v.1.17.0) and I could solve with this.
You can use the option -o
to specify the output format you need, an example of more info is wide
, if you run next command:
kubectl get pods -o wide
The output will include the columns
NAME READY STATUS RESTARTS AGE IP NODE NOMINATED NODE
But if you want a more custom output you can use custom-columns
instead of wide
, you can see the different options in the documentation here