首页 文章

将PGAdmin3连接到OpenShift PostgreSQL数据库

提问于
浏览
0

我试图在OpenShift上构建并运行一个连接到PostgreSQL数据库的简单Java Tomcat Web应用程序 . 我想使用PGAdmin3访问远程数据库 .

我可以使用端口转发在本地计算机上使用 psql 访问数据库:

./psql -h 127.0.0.1 -p 5434 testdb -Uadmin6synqbm

我很高兴我的身份文件,私钥和密码短语很好,因为它们适用于其他情况 .

我在 PGAdmin3 上设置了一个名为 OpenShif 的服务器,并尝试使用 SSH Tunneling 连接到数据库,但我收到以下错误消息:

SSH error: Authentication by identity file failed with error code - 16

我的设置如下......

On OpenShift:-

PostgreSQL 9.2  Database: testdb User: admin6synqbm Password: ????
ssh 579792ef0c1e66011b00017b@testdb-infomediauk.rhcloud.com

On PGAdmin:-

Has anyone managed to do this successfully? Any help would be much appreciated.

1 回答

  • 0

    我想我会让大家知道,这个设置确实有用 . 我重新启动了我的工作站并重新启动了我的OpenShift应用程序,然后重新尝试连接并且工作正常 .

    我得到了一个对话框,其中包含以下信息: -

    **Host key received for the SSH server "testdbinfomediauk.rhcloud.com" is
    B9 65 49 1B D7 D5 D1 22 4E 2A 90 C4 0A C2 55 C4 CA A9 CC 7D
    Would you like to accept it and continue with the connection?**
    

    我点击确定它有效!

相关问题