Macos 在终端(mac)中键入psql时用户身份验证失败
免责声明:我查看了许多StackOverFlow帖子,但没有一篇帮助我解决这个问题:/ 我在mac Sierra上运行这个 我试图通过键入Macos 在终端(mac)中键入psql时用户身份验证失败,macos,postgresql,Macos,Postgresql,免责声明:我查看了许多StackOverFlow帖子,但没有一篇帮助我解决这个问题:/ 我在mac Sierra上运行这个 我试图通过键入psql在终端中访问PostgreSQL。 每当我键入psql时,都会出现以下错误: psql: FATAL: password authentication failed for user "JohnSmith" password retrieved from file "/Users/JohnSmith/.pgpass" 在.pgpass文件中,以下是
psql
在终端中访问PostgreSQL。
每当我键入psql
时,都会出现以下错误:
psql: FATAL: password authentication failed for user "JohnSmith"
password retrieved from file "/Users/JohnSmith/.pgpass"
在.pgpass文件中,以下是内容:
localhost:(portnumber):*:JohnSmith:(password)
localhost:(portnumber):*:postgres:(password)
我确认pgpass中JohnSmith的密码与我的Mac用户密码相同
有人能猜出我做错了什么吗