[英]dbeaver connection to remote postgresql database times out
When I try to connect to a remote Postgresql database with Dbeaver the connection times out.当我尝试使用 Dbeaver 连接到远程 Postgresql 数据库时,连接超时。 I can connect to the same database on the same remote machine with psql.我可以使用 psql 连接到同一台远程计算机上的同一数据库。 I can connect to a local database on localhost.我可以连接到 localhost 上的本地数据库。
Where should I look for the problem?我应该在哪里寻找问题?
Could be many reasons why your connection time's out:连接时间超时的原因可能有很多:
Your network currently might not have access to the database.您的网络当前可能无法访问数据库。 / port. / 港口。
Your remote Postgres server is not configured for remote access from your location / user.您的远程 Postgres 服务器未配置为从您的位置/用户进行远程访问。 Go check the Postgres documentation about network configuration OR Your could try to use port forwarding with ssh. -L PORTLOCAL:localhost:POSTGRESPORT postgresserver
Go 检查有关网络配置的 Postgres 文档,或者您可以尝试将端口转发与ssh. -L PORTLOCAL:localhost:POSTGRESPORT postgresserver
ssh. -L PORTLOCAL:localhost:POSTGRESPORT postgresserver
and then use localhost:portlocal
to connect to your remote Postgres server through a tunnel. ssh. -L PORTLOCAL:localhost:POSTGRESPORT postgresserver
然后使用localhost:portlocal
通过隧道连接到远程 Postgres 服务器。 Lookup ssh port forwarding.查找 ssh 端口转发。
You manged to get a connection but the connection was randomly lost / My solution Was to: enable Keep-Alive.您设法建立了连接,但连接随机丢失/我的解决方案是:启用 Keep-Alive。 in the connection settings.在连接设置中。
disable the option to show all databases in the connection setting.禁用在连接设置中显示所有数据库的选项。 sometimes this prevented me to connection to remote databases.有时这会阻止我连接到远程数据库。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.