Re: JDBC Connection Errors - Mailing list pgsql-general

From Thomas Markus
Subject Re: JDBC Connection Errors
Date
Msg-id 4E54A470.2080707@proventis.net
Whole thread Raw
In response to JDBC Connection Errors  (Sam Nelson <samn@consistentstate.com>)
List pgsql-general
Hi,

- check for open server socket: netstat -tulpen | grep postgres
- try to force ipv4 for java with system property (a recent jre prefers
ipv6): -Djava.net.preferIPv4Stack=true

regards
Thomas

Am 24.08.2011 00:47, schrieb Sam Nelson:
> Hi list,
>
> A client is hitting an issue with JDBC:
> org.postgresql.util.PSQLException: Connection refused. Check that the
> hostname and port are correct and that the postmaster is accepting
> TCP/IP connections.
>
> -pg_hba.conf is set to trust 0.0.0.0/0 (IPv4 only)
> -listen_addresses is *
> -I can find no evidence of iptables running on the server.
> -PGAdmin connects just fine.
> -psql connects just fine.
> -I can find no errors in the log file from that day for the user that
> the client is trying to log in as.
>
> We're working on getting access to more details about how they're
> trying to connect, but in the mean time, does anyone know if JDBC has
> any issues connecting that psql and PGAdmin wouldn't have?  Is it
> possible that JDBC is somehow susceptible to connection issues that
> JDBC and psql are not?
> ---
> ===========================
> Samuel Nelson
> Consistent State
> www.consistentstate.com
> 303-955-0509
> ===========================
>

pgsql-general by date:

Previous
From: Chris Hanks
Date:
Subject: Re: Collapsing multiple subqueries into one
Next
From: Rebecca Clarke
Date:
Subject: Re: Connection Error during Pg_restore