【问题标题】:PostgreSQL: 'FATAL: role "*" does not exist' while connecting from applicationPostgreSQL:从应用程序连接时'致命:角色“*”不存在'
【发布时间】:2018-04-05 07:49:21
【问题描述】:

经过几个月的出色工作,PostgreSQL 突然提出“角色不存在”。 尝试从应用程序连接时,我可以看到此错误,但“psql”工作正常:

07:43:16.700 [postgresql connection adder] DEBUG com.zaxxer.hikari.pool.HikariPool - postgresql - Cannot acquire connection from data source
org.postgresql.util.PSQLException: FATAL: role "user" does not exist
...
lalala@Ubuntu-1604-xenial-64-minimal:~$ docker exec -it postgresql psql -U user db;
psql (9.6.1)
Type "help" for help.

db=> 

有谁知道可能导致问题的原因吗?

【问题讨论】:

    标签: postgresql database-administration privileges


    【解决方案1】:

    如果它一直在工作,那就有点奇怪了,我会检查你的 pg_hba.conf 文件上的日期和最近的更改。在该文件中,您的 psql(本地)将是一个不同的设置,这可以解释为什么会有不同的行为

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2017-05-25
      • 1970-01-01
      • 2015-04-01
      • 2012-08-08
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多