You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by abhishek reddy <ab...@gmail.com> on 2008/02/26 11:05:28 UTC

Connection Pooling

 Here are the pool configuration details in context.xml file.........

<Resource
name="jdbc/pool"
auth="Container"
type="javax.sql.DataSource"
username="scott"
password="tiger"
driverClassName="sun.jdbc.odbc.JdbcOdbcDriver"
url="jdbc:odbc:pool"
maxWait="60000"
removeAbandoned="true"
maxActive="130"
maxIdle="50"
removeAbandonedTimeout="300"
logAbandoned="true"
/>

 software:
 database : oracle 9i
 server: tomcat 5.5

 iam getting the following error:

 java.sql.SQLException: [Oracle][ODBC][Ora]ORA-00020: maximum number
of processes (150) exceeded.

 I have set the maxActive to 130 then how will the number of processes
exceeds 150?

 tell me when will the maximum number of processes (150) exceeded in
the oracle and how do i solve the problem?

 I have checked the application 5 to 10 times and there is no
connection leakage problem.

 the application is under going performance testing.....with around
200 users at a time, for the first time it worked perfeclty, next time
the
 above mentioned error is comming..

 i need your help in solving this problem..


-- 
Abhishek

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Connection Pooling

Posted by Dirk Weigenand <Di...@gmx.de>.
Hi,

you should try to use a dedicated worker process for connections.

Oracle by defaults spawns (some) worker processes for incoming connection requests which are shared (i.e. not dedicated to a certain user).

Setting your connection count to a high number will probably result in an equally high number of worker processes used.

So try to use a dedicated connection:

jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost)(PORT = 1521)))(CONNECT_DATA=(SID=ORCL)(SERVER=DEDICATED))).

You will have to use the jdbc driver supplied by Oracle though to get this working (you can use a recent version (i.e. >= 10.x.y.z) with Oracle 9i).

For further (and exact) information on this topic ask your local oracle database administrator.

regards
       Dirk

-------- Original-Nachricht --------
> Datum: Wed, 27 Feb 2008 11:56:36 +0530
> Von: "abhishek reddy" <ab...@gmail.com>
> An: "Tomcat Users List" <us...@tomcat.apache.org>
> Betreff: Re: Connection Pooling

> thanks Mr Adam Gordon for the reply,
> 
> Can u tell me how to determine why oracle is generating those many
> processes?
> Also tell me where to check the number of oracle processes in use and
> how to reduce it?
> 
> >  abhishek reddy wrote:
> >  >  Here are the pool configuration details in context.xml file.........
> >  >
> >  > <Resource
> >  > name="jdbc/pool"
> >  > auth="Container"
> >  > type="javax.sql.DataSource"
> >  > username="scott"
> >  > password="tiger"
> >  > driverClassName="sun.jdbc.odbc.JdbcOdbcDriver"
> >  > url="jdbc:odbc:pool"
> >  > maxWait="60000"
> >  > removeAbandoned="true"
> >  > maxActive="130"
> >  > maxIdle="50"
> >  > removeAbandonedTimeout="300"
> >  > logAbandoned="true"
> >  > />
> >  >
> >  >  software:
> >  >  database : oracle 9i
> >  >  server: tomcat 5.5
> >  >
> >  >  iam getting the following error:
> >  >
> >  >  java.sql.SQLException: [Oracle][ODBC][Ora]ORA-00020: maximum number
> >  > of processes (150) exceeded.
> >  >
> >  >  I have set the maxActive to 130 then how will the number of
> processes
> >  > exceeds 150?
> >  >
> >  >  tell me when will the maximum number of processes (150) exceeded in
> >  > the oracle and how do i solve the problem?
> >  >
> >  >  I have checked the application 5 to 10 times and there is no
> >  > connection leakage problem.
> >  >
> >  >  the application is under going performance testing.....with around
> >  > 200 users at a time, for the first time it worked perfeclty, next
> time
> >  > the
> >  >  above mentioned error is comming..
> >  >
> >  >  i need your help in solving this problem..
> >  >
> >  >
> >  >
> >
> >  ---------------------------------------------------------------------
> >  To start a new topic, e-mail: users@tomcat.apache.org
> >  To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> >  For additional commands, e-mail: users-help@tomcat.apache.org
> >
> >
> 
> 
> 
> -- 
> Abhishek
> 
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org

-- 
Psssst! Schon vom neuen GMX MultiMessenger gehört?
Der kann`s mit allen: http://www.gmx.net/de/go/multimessenger

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Connection Pooling

Posted by abhishek reddy <ab...@gmail.com>.
thanks Mr Adam Gordon for the reply,

Can u tell me how to determine why oracle is generating those many processes?
Also tell me where to check the number of oracle processes in use and
how to reduce it?


On Wed, Feb 27, 2008 at 4:18 AM, Adam Gordon <ad...@readytalk.com> wrote:
> Hi, I think you may be confusing the number of allowable processes with
>  the number of allowable threads.
>
>  Per Tomcat's documentation, maxActive refers to the maximum number of DB
>  connections whereas the Oracle error you are seeing refers to the
>  maximum number of processes (threads?) which are not necessarily
>  connections.  It's been too many years since I've worked with Oracle,
>  let alone 9i, so I can't point you where to look in your config files,
>  but I suspect that's where the problem may be.
>
>  As an aside, the solution is probably not to just up the number of
>  processes but to determine why Oracle is generating so many (if 150 is
>  indeed considered "many.").
>
>  Hope this helps.
>
>  --adam
>
>
>
>  abhishek reddy wrote:
>  >  Here are the pool configuration details in context.xml file.........
>  >
>  > <Resource
>  > name="jdbc/pool"
>  > auth="Container"
>  > type="javax.sql.DataSource"
>  > username="scott"
>  > password="tiger"
>  > driverClassName="sun.jdbc.odbc.JdbcOdbcDriver"
>  > url="jdbc:odbc:pool"
>  > maxWait="60000"
>  > removeAbandoned="true"
>  > maxActive="130"
>  > maxIdle="50"
>  > removeAbandonedTimeout="300"
>  > logAbandoned="true"
>  > />
>  >
>  >  software:
>  >  database : oracle 9i
>  >  server: tomcat 5.5
>  >
>  >  iam getting the following error:
>  >
>  >  java.sql.SQLException: [Oracle][ODBC][Ora]ORA-00020: maximum number
>  > of processes (150) exceeded.
>  >
>  >  I have set the maxActive to 130 then how will the number of processes
>  > exceeds 150?
>  >
>  >  tell me when will the maximum number of processes (150) exceeded in
>  > the oracle and how do i solve the problem?
>  >
>  >  I have checked the application 5 to 10 times and there is no
>  > connection leakage problem.
>  >
>  >  the application is under going performance testing.....with around
>  > 200 users at a time, for the first time it worked perfeclty, next time
>  > the
>  >  above mentioned error is comming..
>  >
>  >  i need your help in solving this problem..
>  >
>  >
>  >
>
>  ---------------------------------------------------------------------
>  To start a new topic, e-mail: users@tomcat.apache.org
>  To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>  For additional commands, e-mail: users-help@tomcat.apache.org
>
>



-- 
Abhishek

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Connection Pooling

Posted by Adam Gordon <ad...@readytalk.com>.
Hi, I think you may be confusing the number of allowable processes with 
the number of allowable threads.

Per Tomcat's documentation, maxActive refers to the maximum number of DB 
connections whereas the Oracle error you are seeing refers to the 
maximum number of processes (threads?) which are not necessarily 
connections.  It's been too many years since I've worked with Oracle, 
let alone 9i, so I can't point you where to look in your config files, 
but I suspect that's where the problem may be.

As an aside, the solution is probably not to just up the number of 
processes but to determine why Oracle is generating so many (if 150 is 
indeed considered "many.").

Hope this helps.

--adam

abhishek reddy wrote:
>  Here are the pool configuration details in context.xml file.........
>
> <Resource
> name="jdbc/pool"
> auth="Container"
> type="javax.sql.DataSource"
> username="scott"
> password="tiger"
> driverClassName="sun.jdbc.odbc.JdbcOdbcDriver"
> url="jdbc:odbc:pool"
> maxWait="60000"
> removeAbandoned="true"
> maxActive="130"
> maxIdle="50"
> removeAbandonedTimeout="300"
> logAbandoned="true"
> />
>
>  software:
>  database : oracle 9i
>  server: tomcat 5.5
>
>  iam getting the following error:
>
>  java.sql.SQLException: [Oracle][ODBC][Ora]ORA-00020: maximum number
> of processes (150) exceeded.
>
>  I have set the maxActive to 130 then how will the number of processes
> exceeds 150?
>
>  tell me when will the maximum number of processes (150) exceeded in
> the oracle and how do i solve the problem?
>
>  I have checked the application 5 to 10 times and there is no
> connection leakage problem.
>
>  the application is under going performance testing.....with around
> 200 users at a time, for the first time it worked perfeclty, next time
> the
>  above mentioned error is comming..
>
>  i need your help in solving this problem..
>
>
>   

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org