我坚持从远程主机连接到PostresSQL数据库。 服务器正在接受端口5432的传入连接,并且已经像这样configuration了pg_hba.conf:
local all all md5 host all all 0.0.0.0/0 md5
和postgresql.conf是这样的:
listen_addresses = '*' port = 5432 max_connections = 100
我从本地访问没有任何问题,但是当我尝试通过psql连接这样的东西:
psql -U myuser -h hostname db_name
我得到这个错误:
psql: FATAL: no pg_hba.conf entry for host "87.zz.yy.xxx", user "myuser", database "db_name", SSL off
我还尝试将主机87.zz.yy.xxx放入pg_hba.conf文件中,但未成功。