Re: Too many clients----A big problem for my team

From: Steve Crawford <scrawford(at)pinpointresearch(dot)com>
To: pgsql-admin(at)postgresql(dot)org
Cc: "ganapatiram" <ganapatiram(at)symphonydata(dot)com>
Subject: Re: Too many clients----A big problem for my team
Date: 2005-03-18 16:24:09
Message-ID: 200503180824.09613.scrawford@pinpointresearch.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

On Friday 18 March 2005 5:31 am, ganapatiram wrote:
> Hi Mr. Steeve,
>
> I really thank for your detailed reply. I worked on the
> four points what you mentioned. I am sure it worked. But when i
> went for testing i saw a different error this time. It says:
>
> org.jboss.util.NestedSQLException: No ManagedConnections available
> within configured blocking timeout ( 1000 [ms] ); - nested
> throwable: (javax.resource.ResourceException: No ManagedConnections
> available within configured blocking timeout ( 1000 [ms] ))
>
> Here i tried by changing the " blocking-timeout-millis" to
> 30000. Even that did not work i am getting the same error. Please
> let me know your suggestion in this regard.
>
> Once again thanks for your reply.

You need to diagnose what is happening and reply to the list with your
findings. In particular, when you get this message you need to check
your PostgreSQL server and see how many connections it is handling.

Naturally you should first make sure the problem app/client can
connect once. If not, there may be a config or coding problem. Make
sure that you can connect from that machine using psql. Note and
report any error messages.

Your postgresql log file may yield clues as well.

When you are having the problem see if you can connect with psql from
the problem machine and from other known good machines. If you can,
the problem is probably somewhere in the code or configuration of
your application or Jboss so you will have to work internally or ask
on the Jboss groups.

If you can't connect, check the number of connections on the PG server
("ps -ef | grep postgres:" works on my server and also shows the IP
of each connecting client). If you are choked with lots of idle
connections you may have to track them down. You can use netstat on
the server to find the client-side port number for each of the
connections and on the clients you can use lsof, fuser or similar to
locate the specific process associated with each connection. That
still leaves you with determining why the connections are there which
will again probably be a question for Jboss or your developers.

Cheers,
Steve

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message Bruno G. Albuquerque 2005-03-18 19:55:43 Problem with backups and functions.
Previous Message Sabio - PSQL 2005-03-18 16:16:45 Re: large database versus many databases