Connection to [name of the host name] failed. Host [name of the host name] is unknown. [08001] The connection attempt failed - datagrip

I am trying to connect datagrip to my remote heroku postgres database but it doesn't connect
Connection to jdbc:postgresql://ec2-54-235-156-60.compute-1.amazonaws.com :5432/d89oi6u1v8vmmo failed.
Host ec2-54-235-156-60.compute-1.amazonaws.com is unknown.
[08001] The connection attempt failed.
I read heroku needs ssl so i provided here

I found the answer. The problem was the whitespace between ".com and :". I removed it. It again showed error as
The SSLSocketFactory class provided org.postgresql.ssl.NonValidatingFactory could not be instantiated
I tested it again it started working

Related

Receiving Invalid database URL while trying to start chainlink node

I am trying to start a chainlink node in rinkeby testnet.I have setup a postgres DB in AWS. The Database URL is already given. Below is the error while i am trying to start the node.
[ERROR] invalid database url %spostgresql://postgres:Bounty2000%#database-1.ciiecd8szsuh.us-west-1.rd
s.amazonaws.com:5432/db_sar_rinkeby orm/config.go:283
[ERROR] failed to initialize database, got error failed to connect to `host=/tmp user=root database=`
: dial error (dial unix /tmp/.s.PGSQL.5432: connect: no such file or directory) orm/orm.go:82
[ERROR] failed to initialize database, got error failed to connect to `host=/tmp user=root database=`
: dial error (dial unix /tmp/.s.PGSQL.5432: connect: no such file or directory) orm/orm.go:82
I tried changing few settings from AWS front but nothing helped.. If anyone have any clue pls help me up.
Based on the documentation it looks like there may be an "s" in front of your postgres URL, try removing that in your .env file. Also try replacing the database name with the IP address+Port. What should replace $DATABASE is "postgres". Finally try adding in ?sslmode=disable if you don't have ssl activated at the database (not recommended for a production node).
Example in .env:
DATABASE_URL=postgresql://me1234:password1234#10.10.100.100:3000/postgres?sslmode=disable

Can not connect to AWS parse server on Mac : ssh_exchange_identification: Connection closed by remote host

The image from my terminal
Hi, I am following a Swift Xcode class, and now we are building a project required to connect with AWS parse server, After tried lots of times, it still the same error: ssh_exchange_identification: Connection closed by remote host
Here is the error message:
luodeMacBook-Air:desktop luo$ chmod 400 onepicioskeypair.pem luodeMacBook-Air:desktop luo$ ssh -i "onepicioskeypair.pem" ubuntu#ec2-18-216-187-86.us-east-2.compute.amazonaws.com ssh_exchange_identification: read: Operation timed out luodeMacBook-Air:desktop luo$
Please verify you are trying with correct ip address or url.
change EC2 setting to Allow all IP address
and restart instance and try again

Unable to connect to Heroku Postgres from Play 2.3

I have a Play 2.3 app in Java. For this app, I am able to connect to local Postgres server.
But I am unable to connect to Heroku Postgres server.
I have following settings in my application.conf:
db.default.driver=org.postgresql.Driver
db.default.url="jdbc:postgresql://ec2test.amazonaws.com:5432/rwerwerwer"
db.default.user=eerwerwerer
db.default.password="5345fdwfdsvfvsdfsdfds"
I am getting following error:
Caused by: org.postgresql.util.PSQLException: FATAL: no pg_hba.conf entry for ho
st "172.56.17.147", user "eerwerwerer", database "rwerwerwer", SSL off
From PgAdim III, I am able to successful connect to Heroku database.
While adding heroku config, I got:
**! No app specified.**
Follow these steps.
Things to remember:
Use Heroku commands from inside your main directory.
Use database connection as:
db.default.driver=org.postgresql.Driver
db.default.url=${?DATABASE_URL}
No need for username and password.
No need for Procfile.

TeamCity: Test connection failed due to I/O-Exception

I’m starting to use TeamCity and getting few problems:
I'm trying to create an ssh connection to a unix server(e.g isk-vsrv131)in order to run commands/scripts on the unix server.
I used "Administration->Edit Build Configuration->Edit VCS Root" to configure a new vsc root but as i'm testing the connection i'm getting the following error:
Connection failed!
Test connection failed in TestU1 :: test_bc. I/O-Exception: isk-vsrv13 (isk-vsrv13)
i've tried different configurations including the server local ip/full domain/using Private key instead of ssh password - nothing works.
on teamcity-vcs.log is see the following:
[2012-03-26 17:41:33,827] WARN [on=editVcsRoot ] - jetbrains.buildServer.VCS - Error occurred in test connection
jetbrains.buildServer.vcs.VcsException: I/O-Exception: isk-vsrv13 (isk-vsrv13)
.
.
.
Caused by: java.net.UnknownHostException: isk-vsrv13
.
.
.
How can i fixed that?
I’ve created a "Build Steps" which includes a 'Runner type: Command Line" - how can i connect those to a specific ssh connection?
Thanks
It seems server machine where TeamCity is installed cannot resolve host name isk-vsrv13, hence the java.net.UnknownHostException error. I would try to specify fully qualified name of this host.

Connect DbVisualizer to HSQLDB on Mac

I need to connect DbVisualizer to HSQLDB. I've installed both on my mac (OSX 10.6.9). I've installed DbVisualized 8.0.5, and HSQLDB. I have both open, but when I try to ping the server, I receive the error message: "Cannot connect to 'localhost' on port 9001." The message below shows up in the Connection Message window:
An error occurred while establishing the connection:
Long Message:
java.net.ConnectException: Connection refused
Details:
   Type: java.sql.SQLTransientConnectionException
   Error Code: -1301
   SQL State: 08001
By default, when you run the HSQLDB Server, it shows some messages in the window. The last maessage should indicate susseful startup.
[Server#80fa6f]: 2011-11-12 21:03:24.904 HSQLDB server 2.2.6 is online on port 9001
[Server#80fa6f]: To close normally, connect and execute SHUTDOWN SQL
When you ping from DbVis, the server rejects the data because it's not valid data for making a connection. It shows an exception. This is normal behaviour. On the DBVis side, it should return success after the ping.
You should then connect from DbVis and it should work.
You must use the same HSQLDB jar on both DbVis and HSQLDB (you probably have done this).
You can also double check by executing the HSQLDB (version 2.2.x) jar, which brings up its own database manager and allows you to connect to the server.
One likely cause is network problems. You can try the IP address 127.0.0.1 instead of 'localhost'

Resources