What is unknown user client in kubernetes?

0 votes

Kubectl isn't working as expected. I amd running it on my local shell with gcloud sdk. A simple command like:

$ kubectl get pod

gives me this error:

Error from server (Forbidden): pods is forbidden: User "client" cannot list pods at the cluster scope: Unknown user "client"

I can run the same command on GCP cloud shell with correct output

$ gcloud auth list

output:

Credentialed Accounts
ACTIVE ACCOUNT
* foo@bar.com

I tried creating a clusterrolebinding, but the error still persists.

Sep 12, 2018 in Kubernetes by Atul
• 10,240 points
44 views

1 answer to this question.

0 votes

I think your Legacy Authorisation has been disabled in cluster settings. The client certificate that you are using is a Legacy Authentication method. So your client authentication actually succeeds but the authorisation fails. So now you can either of the following things:

Try and disable the use of client certificate:

gcloud config unset container/use_client_certificate

And regenerate your kubectl config:

gcloud container clusters get-credentials my-cluster

OR the more simpler method being, enable Legacy Authorisation in the cluster settings in the Google Cloud Console.

answered Sep 12, 2018 by DareDev
• 6,810 points

Related Questions In Kubernetes

0 votes
1 answer

What all components is the Master server in Kubernetes made up of?

Kubernetes is a combination of multiple parts ...READ MORE

answered Jul 11 in Kubernetes by Sirajul
• 19,670 points
42 views
0 votes
1 answer

What is a Resource Quota in Kubernetes?

A resource quota, defined by a ResourceQuota ...READ MORE

answered Jul 16 in Kubernetes by Sirajul
• 19,670 points
13 views
0 votes
1 answer

What is a service role in kubernetes components?

A service is an abstraction for pods. ...READ MORE

answered Jul 16 in Kubernetes by Sirajul
• 19,670 points
23 views
0 votes
1 answer

permissions related to AWS ECR

if you add allowContainerRegistry: true, kops will add those permissions ...READ MORE

answered Oct 9, 2018 in Kubernetes by Kalgi
• 39,330 points
58 views
0 votes
1 answer
0 votes
3 answers

Error while joining cluster with node

Hi Kalgi after following above steps it ...READ MORE

answered Jan 17 in Others by anonymous
1,670 views
0 votes
1 answer
0 votes
3 answers

Using multiple commands in a kubernetes yaml file

Try something like this: containers: - name: ...READ MORE

answered Apr 23 in Kubernetes by lyza
4,250 views