Not able to get Admin console using Keycloak 26.0.6 #35477
Replies: 12 comments 16 replies
-
|
If the server is started for the first time without setting the bootstrap environement variables, the database will be initialized without creating the bootstrap admin. They have to be set for the first time a start command is run. |
Beta Was this translation helpful? Give feedback.
-
|
I encountered this same problem. In logs you should find message like "INFO [org.keycloak.services] (main) KC-SERVICES0077: Created temporary admin user with username admin" |
Beta Was this translation helpful? Give feedback.
-
|
"To create the temporary administrative user open http://localhost:8080/, or set the environment variables KEYCLOAK_ADMIN and KEYCLOAK_ADMIN_PASSWORD when starting the server." I don't believe there was any release of keycloak that had this combination of wording. Once the message said temporary, the variables referenced the KC_BOOTSTRAP_ADMIN ones. Are you doing something with a custom theme? An issue is needed here as the suggestion even in main to use the env variables won't work - it is too late because they are only used when the master realm is created, which would have already happened. |
Beta Was this translation helpful? Give feedback.
-
|
I’ve been facing the same issue for the past week. In older tutorials, I noticed the use of the KEYCLOAK_ADMIN variable for setting up the admin credentials. However, in the latest Keycloak version (26.0.7), the documentation specifies using KC_BOOTSTRAP_ADMIN_USERNAME= and KC_BOOTSTRAP_ADMIN_PASSWORD= when starting the server. Here’s the command I am using on a Windows machine: Also I have seen this in the log - 2024-12-09 07:03:44,025 INFO [org.keycloak.services] (main) KC-SERVICES0050: Initializing master realm Still the credentials are not working, it says invalid username or password. |
Beta Was this translation helpful? Give feedback.
-
|
Try using 127.0.0.1:8080 instead of localhost:8080 |
Beta Was this translation helpful? Give feedback.
-
|
I faced same issue with keycloak 26.0.7 while setting it on RHEL server. This issue chain here helped me. As suggested, I removed existing keycloak folder, unziped another set and executed below commands. kc.sh start-dev --bootstrap-admin-username $KC_BOOTSTRAP_ADMIN_USERNAME --bootstrap-admin-password $KC_BOOTSTRAP_ADMIN_PASSWORD |
Beta Was this translation helpful? Give feedback.
-
|
I ran the same issue, however, in my case, I was attempting to access it using the docker-compose file. These are the environment variables in my docker-compose.yml : Then I exported them using the following command in my terminal : Just so you know, you need to set the environment variable before spinning up the keycloak container, because the credentials will be set during the container first initialization. Once the container is fully operational, the logs should show you the following result.
This is the version I'm currently using |
Beta Was this translation helpful? Give feedback.
-
|
Heyy , so i faced a similar thing . What i did was delete the keycloak folder and then set the environment variables for admin and password. |
Beta Was this translation helpful? Give feedback.
-
|
I pulled bitnami/keycloak:26.2.5-debian-12-r3 and customized it by injecting the internal libraries. The build was success in Docker and also in Docker compose. Error: And facing issues with the admin page login. Please suggest. |
Beta Was this translation helpful? Give feedback.
-
|
In my case, I managed to solve the login issue by escaping the $ character in the password variable in the .env file. I'm deploying Keycloak in a docker container via docker compose. When inspecting the container environment variables I noticed that The solution is to escape the $ character such as |
Beta Was this translation helpful? Give feedback.
-
|
I was unable to log into the admin console of keycloak. I've checked the environment variables and was confused, because they existed, just like they did in another working deployment. Got this error: invalid_user_credentials It turns out that I had the character "ö" in a password, which is a non-ascii character. I removed that character and was able to login afterwards. |
Beta Was this translation helpful? Give feedback.
-
|
Hello.
|
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi, i am completely new to this Keycloak, i have installed keycloak latest version in my local windows machine with quarkus distribution, using the following command-: kc.bat start-dev, i started the server, also added the following ENV variables with values against my account user in the windows system-:
KC_BOOTSTRAP_ADMIN_USERNAME=admin
KC_BOOTSTRAP_ADMIN_PASSWORD=admin123
But still the issue is that when i m hittng the localhost:8080/ end point it is asking me to create temporary administrative user-: following is the message i see on web page-:
You will need local access to create the temporary administrative user.
To create the temporary administrative user open http://localhost:8080/, or set the environment variables KC_BOOTSTRAP_ADMIN_USERNAME and KC_BOOTSTRAP_ADMIN_PASSWORD when starting the server.
Can anyone point out where i am going wrong?
Beta Was this translation helpful? Give feedback.
All reactions