[pgpool-general: 3256] Re: Problems Connecting via AppServer
Yugo Nagata
nagata at sraoss.co.jp
Tue Nov 4 18:15:20 JST 2014
Hi,
Is there any error messages in logs of pgpool or postgresql?
And, what about when using JDBC withoug Tomcat?
I also want to know the exact java code and SQL to reproduce this.
On Fri, 31 Oct 2014 15:02:23 -0500
Anthony Presley <anthony at timeforge.com> wrote:
> Hi all!
>
> We've been using pgpool-ii for nearly 3 years, successfully, and we love it.
>
> However, we're having some very, very strange issues when attempting to use
> Tomcat 6.x or 7.x to connect to pgpool.
>
> We currently use PG 9.0, and native binary and WAL replication.
>
> Specifically, our current set up looks like:
> AppServer1,2,3 -> pgpool -> db1, db2
>
> We currently send 100% of the reads to db2, and use db1 for inserts only.
>
> pgpool runs on port 5433.
>
> We've started deploying new appservers, and have found that they do not all
> connect to the pgpool instance. No change in Tomcat version (we've tried
> both Tomcat 6.x and 7.x), and using the same JDBC drivers.
>
> I can connect to pgpool, using psql, from these machines - and it works
> perfectly.
>
> However, when I start Tomcat, it hangs forever trying to connect to pgpool.
>
> I can connect to pgpool using psql, from those machines - to port 5433 -
> without problems. So, I'm assuming it's not a firewall / network problem.
>
> In trying to decode the problem, we set up a second pgpool, on one of the
> problematic machines - and continued having the same problem.
>
> We then upgraded to this pgpool:
> pgpool-II-93-devel-3.3.2-1.rhel6.x86_64
>
> FINE: Instantiating driver using class: org.postgresql.Driver
> [url=jdbc:postgresql://localhost:5433/scheduler?useUnicode=true&characterEncoding=utf-8]
> Oct 28, 2014 12:51:17 AM org.apache.tomcat.jdbc.pool.PooledConnection
> connectUsingDriver
> FINE: Unable to connect to database.
> org.postgresql.util.PSQLException: The connection attempt failed.
> .....
> .....
> Caused by: java.io.EOFException
> at org.postgresql.core.PGStream.ReceiveChar(PGStream.java:274)
> at
> org.postgresql.core.v3.ConnectionFactoryImpl.doAuthentication(ConnectionFactoryImpl.java:269)
> at
> org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:106)
> ... 93 more
>
> Any ideas?
>
>
> --
> Anthony Presley
--
Yugo Nagata <nagata at sraoss.co.jp>
More information about the pgpool-general
mailing list