gpt4 book ai didi

postgresql - 为什么我不能从远程访问我的 postgres?

转载 作者:行者123 更新时间:2023-11-29 13:15:22 33 4
gpt4 key购买 nike

我在 Ubuntu 服务器上安装了 Postgres 10.3 服务器。

我做了必要的设置,这些设置总是足以让我的笔记本电脑从 PGAdmin 访问它,但这次它不起作用。

我尝试了以下步骤:

listen_addresses = '*'
host all all 0.0.0.0/0 trust
ufw allow 5432
Postgresql restarted
Server rebooted
Server pinged with success
Restarted the VPN-Client
direct IP instead of VPN-IP
disabled IPTABLES

我可以在本地连接到服务器,但远程仍然无法正常工作。

当我尝试连接时,似乎不是 postgres 阻止了它,而是之前的一些东西:

Unable to connect to server:

could not connect to server: Connection timed out (0x0000274C/10060)
Is the server running on host "10.8.0.50" and accepting
TCP/IP connections on port 5432?

可能是什么原因?

最佳答案

设置服务器时,安装了 Plesk。

Plesk 有自己的防火墙,它拒绝了连接。允许后,它运行完美。

关于postgresql - 为什么我不能从远程访问我的 postgres?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49921200/

33 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com