# Unable to login into the master console and empty Postgres database

**URL:** <https://forum.keycloak.org/t/unable-to-login-into-the-master-console-and-empty-postgres-database/28975>\
**Category:** Miscellanaeous\
**Created:** [November 28, 2024, 10:26am UTC](https://forum.keycloak.org/t/unable-to-login-into-the-master-console-and-empty-postgres-database/28975 "2024-11-28T10:26:24Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![hendrik212](https://yyz2.discourse-cdn.com/free1/user_avatar/forum.keycloak.org/hendrik212/32/11700_2.png) [@hendrik212](https://forum.keycloak.org/u/hendrik212)\
**Post date:** [November 28, 2024, 10:26am UTC](https://forum.keycloak.org/t/unable-to-login-into-the-master-console-and-empty-postgres-database/28975/1 "2024-11-28T10:26:24Z")

</div>

I have a very strange issue with keycloak. I use the following docker compose setup but I am not able to login into the console with `admin/password` and looking into the postgres database shows not tables are created. No error logs, also nothing relevant on trace level.

Database connection is established (wireshark shows that, albeit I can not decrypt the SSL traffic to see the SQL statements) and when using a deliberately wrong password keycloak startup failed as expected.

The postgres database is a managed Postgres service from (from a german hoster) version 15 with 3 nodes running as a cluster in STRICTLY\_SYNCHRONOUS mode

```auto
services:
  keycloak:
    image: quay.io/keycloak/keycloak:26.0.6
    command: start --log-level="TRACE"
    environment:
      KC_HOSTNAME: localhost
      KC_HOSTNAME_PORT: 8080
      KC_HOSTNAME_STRICT_BACKCHANNEL: false
      KC_HTTP_ENABLED: true
      KC_HOSTNAME_STRICT_HTTPS: false
      KC_HEALTH_ENABLED: true
      KEYCLOAK_ADMIN: admin
      KEYCLOAK_ADMIN_PASSWORD: password
      KC_DB: postgres
      KC_DB_URL: jdbc:postgresql://a.managed.hosted.postgres.db.com/keycloakdb
      KC_DB_USERNAME: keycloak
      KC_DB_PASSWORD: secretkkpswd
    ports:
      - 8080:8080
    networks:
      - keycloak_network

networks:
  keycloak_network:
    driver: bridge

```

The keycloak user has full permissions for keycloadb and I tested it with creating dummy tables via pgsql using that user and credentials. So its not a permission issues or alike.

When switching to dev-file database or to a local postgres running in docker compose everything works! I would expected error messages or startup failure if there is anything wrong with the database.

 ![Monosnap Sign in to Keycloak 2024-11-28 11-30-24](https://global.discourse-cdn.com/free1/uploads/keycloak/original/2X/5/5b8708308370b12686ce5c6110c52fcd2b8c05e5.jpeg)
