Description of problem: system:admin requiring password when starting fresh with a copied version of admin.kubeconfig Workaround is to use the -u option the first time. Version-Release number of selected component (if applicable): 3.0.2 How reproducible: 100% Steps to Reproduce: [root@master ~]# rm .kube/config rm: remove regular file ‘.kube/config’? y [root@master ~]# cp /etc/openshift/master/admin.kubeconfig .kube/config [root@master ~]# oc login Authentication required for https://master.lizard.com:8443 (openshift) Username: system:admin Password: Error from server: Internal error occurred: unexpected response: 500 [root@master ~]# oc login -u system:admin Logged into "https://master.lizard.com:8443" as "system:admin" using existing credentials. Using project "default". You have access to the following projects and can switch between them with 'oc project <projectname>': * default (current) * openshift * openshift-infra Actual results: Error from server: Internal error occurred: unexpected response: 500 Expected results: Logged into "https://master.lizard.com:8443" as "system:admin" using existing credentials. Additional info: This only happens when the -u option is not used the first time. This was tested with htpasswd auth
To switch to an existing credentials, you must use "-u ...". Will look into preventing the 500 error
Fixed in origin in https://github.com/openshift/origin/pull/5726
Usernames with colons no longer attempt password auth
checked with devenv-centos7_3136, and still not work # oc login Authentication required for https://172.18.8.193:8443 (openshift) Username: system:admin Password: error: username system:admin is invalid for basic auth
To switch to an existing credentials, you must use "-u ...". The bug that was fixed was the 500 error encountered if you try to use "system:admin" as a password login. The "username system:admin is invalid for basic auth" error is working correctly if you attempt to use that username for a password login.
(In reply to Jordan Liggitt from comment #6) > To switch to an existing credentials, you must use "-u ...". The bug that > was fixed was the 500 error encountered if you try to use "system:admin" as > a password login. > > The "username system:admin is invalid for basic auth" error is working > correctly if you attempt to use that username for a password login. If so should be verified.
Hy guys, i have the same problem whit the last version of origin (openshift-origin-server-v1.1.1) when i run this command : oc login localhost:8443 -usystem:admin openshift requires password. I need to system:admin user but i don't know how to get permits to run : oadm policy add-cluster-role-to-user cluster-admin admin Do you have any idea to help me ? thanks in advace.
system:admin credentials live in a client certificate. If you get prompted for a password, that means your $KUBECONFIG file does not contain those credentials. You need to locate the admin.kubeconfig file generated at server start and do export KUBECONFIG=/path/to/admin.kubeconfig Then you will be able to run cluster admin commands.
thanks, now work fine :D