【发布时间】:2015-07-04 06:41:51
【问题描述】:
我在 centos 上设置了 posgresql。我正在尝试访问它,但收到错误消息:
sudo -u postgres psql -c "ALTER USER john WITH PASSWORD 'mypass';"
[sudo] password for john:
could not change directory to "/home/john"
ALTER ROLE
psql -h localhost -U john -d proddb -W
Password for user john:
psql: FATAL: Ident authentication failed for user "john"
我列出了带有“du”的用户,并且知道 john 是超级用户。 谁能告诉我为什么会发生这种情况以及如何解决?
【问题讨论】:
-
是的。这是同一个问题。但是,在之前的帖子中,答案并不清楚。我已经在直截了当的回答中明确了问题所在。如果您是管理员,则可以继续将我的答案移至该帖子并关闭此帖子。
标签: postgresql