我在centos 7上安装了postgresql95 (在我的服务器上),但是我不能用pgadmin从我的笔记本电脑远程使用postgresql。我试过任何方法,但还是无法将它遥控。
我在postgresql.conf和pg_hba.conf上做了设置
我在postgresql.conf中改变了这个
#listen_addresses = '*' 并将其添加到pg_hba.conf中
host all all 0.0.0.0/0 trust
host all all ::/0 trust我尝试重新启动postgresql
systemctl start postgresql-9.5
systemctl stop postgresql-9.5但还是无法遥控。我试着用防火墙做些像这样的事
firewall-cmd --permanent --zone=public --add-port=5432/tcp
firewall-cmd --permanent --zone=public --add-port=5432/udp
firewall-cmd --reload当我打开端口80来访问我的服务器时,它运行得很好,但是对于端口5432,它不能正常工作。
发布于 2018-05-05 17:24:21
从#中删除#listen_addresses = '*'。你把它评论掉了。
这一行看起来应该是:
listen_addresses = '*'
https://serverfault.com/questions/910886
复制相似问题