ah! there's the rub. i am also searching the archives of the jakarta-commons-users list for insight and must also post to that list if i can't figure it out myself, but we think no, they are not getting closed correctly. i can claim 100% of the time i am calling conn_.close(), but when we watch our db connections they go up but they never come down. so we think no.
as i mentioned before, i do not fully grok the workings of dbcp and am thus in over my head. i could use a little step-by-step on how to test this (other than the logical deduction my sysadmin and i are using right now). thanks a million everybody for trying to be so helpful. barclay -----Original Message----- From: Angus Mezick [mailto:[EMAIL PROTECTED] Sent: Friday, August 08, 2003 2:23 PM To: Tomcat Users List Subject: RE: Help! heavy traffic is crapping out our site every 5 min! DBCP exceptions All of these connections are being correctly closed, right? --Angus > -----Original Message----- > From: rob engstrom [mailto:[EMAIL PROTECTED] > Sent: Friday, August 08, 2003 2:08 PM > To: 'Tomcat Users List' > Subject: RE: Help! heavy traffic is crapping out our site > every 5 min! DBCP exceptions > > > Ok, I'm the sysamdin of which is being spoken. So I checked > netstat, as I > normally do. Here's a bit of info: > > netstat -an | grep 172.16 | grep ESTABLISHED | wc -l > (172.16 refers to the DB connection on the internal network, > on a separate > VLAN than the rest of the network traffic) > > This elicits a response of : 45 , which if I watch the sysmon > on the SQL > server, it shows 45 connections currently. Same command with > TIME_WAIT > instead, shows: 15 > > So at least right now, it doesn't seem to be so much a > connection problem to > the DB. We did his some "too many open files" errors in the > Catalina.out, > which I temporarily resolved by changing ulimit -n from 1024 to 8092. > > > --- > robert engstrom > > > -----Original Message----- > From: Lawrence, Gabriel [mailto:[EMAIL PROTECTED] > Sent: Friday, August 08, 2003 1:47 PM > To: Tomcat Users List > Subject: RE: Help! heavy traffic is crapping out our site > every 5 min! DBCP > exceptions > > Try running netstat on the linux box to see how many > connections are out > there. This might give you some more visibility into what network > connections are actually being used and where they are going. > > -gabe > > -----Original Message----- > From: Barclay A. Dunn [mailto:[EMAIL PROTECTED] > Sent: Friday, August 08, 2003 10:43 AM > To: Tomcat Users List > Subject: RE: Help! heavy traffic is crapping out our site every 5 min! > DBCP exceptions > > your logic seems on target to me. > > my sysadmin (who's just as stymied as i am) says that according to his > sources, sockets on linux are open files so if the open file limit is > exceeded, it would affect sockets as well. any thoughts on this? > > barclay > > -----Original Message----- > From: Eric J. Pinnell [mailto:[EMAIL PROTECTED] > Sent: Friday, August 08, 2003 1:38 PM > To: Tomcat Users List > Subject: RE: Help! heavy traffic is crapping out our site every 5 min! > DBCP exceptions > > > I'm pretty sure "can't create socket" means it can't connect to the DB > for > some reason. I would wager the DB (or something) is refusing the > connection. The fact that it said "can't create socket" means that > tomcat > is trying to do so. So that part of it seems alright. > > -e > > On Fri, 8 Aug 2003, Barclay A. Dunn wrote: > > > well, i followed the dbcp comment that says "set to 0 for unlimited" > and > > that turns out to be wrong. > > > > i also tried -1 and that is equally unuseful in terms of > setting it to > > unlimited. > > > > so i tried setting maxActive to 1000000000 and so far it is > generating > no > > errors. no, i'm wrong. connecs shot up to around 600 or maybe more, > then > we > > started getting the java.sql.SQLException: > [Microsoft][SQLServer 2000 > Driver > > for JDBC]Error establishing socket. > > > > the db has an insanely huge connection limit of 99,999 we think. > > > > barclay > > > > -----Original Message----- > > From: Eric J. Pinnell [mailto:[EMAIL PROTECTED] > > Sent: Friday, August 08, 2003 1:27 PM > > To: Tomcat Users List > > Subject: RE: Help! heavy traffic is crapping out our site > every 5 min! > > DBCP exceptions > > > > > > Is it also unlimited (or insanely huge) on the database? > > > > -e > > > > On Fri, 8 Aug 2003, Barclay A. Dunn wrote: > > > > > i adjusted the pool to unlimited and am still getting > these errors. > > > something else seems to be fekachte. > > > > > > barclay > > > > > > -----Original Message----- > > > From: Eric J. Pinnell [mailto:[EMAIL PROTECTED] > > > Sent: Friday, August 08, 2003 1:11 PM > > > To: Tomcat Users List > > > Subject: Re: Help! heavy traffic is crapping out our site every 5 > min! > > > DBCP exceptions > > > > > > > > > Hi, > > > > > > Your pool of connections to your database is exhausted. > Try upping > the > > > number. > > > > > > -e > > > > > > On Fri, 8 Aug 2003, Barclay A. Dunn wrote: > > > > > > > we are getting a ton of these errors in our catalina.out and i > could > use > > > > help in fixing it. > > > > > > > > i know they are related to our connection pooling, but > not what to > do > to > > > > fix. my understanding of the underlying mechanics of connection > pooling > > is > > > > somewhat limited. > > > > > > > > i have put two different but related error messages in here: > > > > > > > > java.sql.SQLException: DBCP could not obtain an idle db > connection, > pool > > > > exhausted > > > > at > > > > > > > > > > org.apache.commons.dbcp.AbandonedObjectPool.borrowObject(Aband > onedObject > Pool > > > > .java:123) > > > > at > > > > > > > > > > org.apache.commons.dbcp.PoolingDataSource.getConnection(Poolin > gDataSourc > e.ja > > > > va:110) > > > > at > > > > > > > > > > org.apache.commons.dbcp.BasicDataSource.getConnection(BasicDat > aSource.ja > va:3 > > > > 12) > > > > at > com.happypuppy.util.HPSql.getConnection(HPSql.java:21) > > > > at > org.apache.jsp.index_jsp._jspService(index_jsp.java:222) > > > > at > > > > > org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:137) > > > > at > javax.servlet.http.HttpServlet.service(HttpServlet.java:853) > > > > at > > > > > > > > > > org.apache.jasper.servlet.JspServletWrapper.service(JspServlet > Wrapper.ja > va:2 > > > > 04) > > > > at > > > > > org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet > .java:295) > > > > at > > > org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241) > > > > at > javax.servlet.http.HttpServlet.service(HttpServlet.java:853) > > > > at > > > > > > > > > > org.apache.catalina.core.ApplicationDispatcher.invoke(Applicat > ionDispatc > her. > > > > java:684) > > > > at > > > > > > > > > > org.apache.catalina.core.ApplicationDispatcher.doInclude(Appli > cationDisp > atch > > > > er.java:575) > > > > at > > > > > > > > > > org.apache.catalina.core.ApplicationDispatcher.include(Applica > tionDispat > cher > > > > .java:498) > > > > at > > > > > > > > > > org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntime > Library.ja > va:8 > > > > 22) > > > > at > org.apache.jsp._404_jsp._jspService(_404_jsp.java:373) > > > > at > > > > > org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:137) > > > > at > javax.servlet.http.HttpServlet.service(HttpServlet.java:853) > > > > at > > > > > > > > > > org.apache.jasper.servlet.JspServletWrapper.service(JspServlet > Wrapper.ja > va:2 > > > > 04) > > > > at > > > > > org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet > .java:295) > > > > at > > > org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241) > > > > at > javax.servlet.http.HttpServlet.service(HttpServlet.java:853) > > > > at > > > > > > > > > > org.apache.catalina.core.ApplicationFilterChain.internalDoFilt > er(Applica > tion > > > > FilterChain.java:247) > > > > at > > > > > > > > > > org.apache.catalina.core.ApplicationFilterChain.doFilter(Appli > cationFilt > erCh > > > > ain.java:193) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardWrapperValve.invoke(StandardW > rapperValv > e.ja > > > > va:260) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline$StandardPipelineValv > eContext.i > nvok > > > > eNext(StandardPipeline.java:643) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline.invoke(StandardPipel > ine.java:4 > 80) > > > > at > > > > > org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardContextValve.invoke(StandardC > ontextValv > e.ja > > > > va:191) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline$StandardPipelineValv > eContext.i > nvok > > > > eNext(StandardPipeline.java:643) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline.invoke(StandardPipel > ine.java:4 > 80) > > > > at > > > > > org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) > > > > at > > > > > > > org.apache.catalina.core.StandardContext.invoke(StandardContex > t.java:241 > 5) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardHostValve.invoke(StandardHost > Valve.java > :180 > > > > ) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline$StandardPipelineValv > eContext.i > nvok > > > > eNext(StandardPipeline.java:643) > > > > at > > > > > > > > > > org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDi > spatcherVa > lve. > > > > java:170) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline$StandardPipelineValv > eContext.i > nvok > > > > eNext(StandardPipeline.java:641) > > > > at > > > > > > > > > > org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReport > Valve.java > :172 > > > > ) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline$StandardPipelineValv > eContext.i > nvok > > > > eNext(StandardPipeline.java:641) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline.invoke(StandardPipel > ine.java:4 > 80) > > > > at > > > > > org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardEngineValve.invoke(StandardEn > gineValve. > java > > > > :174) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline$StandardPipelineValv > eContext.i > nvok > > > > eNext(StandardPipeline.java:643) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline.invoke(StandardPipel > ine.java:4 > 80) > > > > at > > > > > org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) > > > > at > > > > > org.apache.ajp.tomcat4.Ajp13Processor.process(Ajp13Processor.java:458) > > > > at > > > > > org.apache.ajp.tomcat4.Ajp13Processor.run(Ajp13Processor.java:551) > > > > at java.lang.Thread.run(Thread.java:536) > > > > > > > > org.apache.commons.dbcp.DbcpException: java.sql.SQLException: > > > > [Microsoft][SQLServer 2000 Driver for JDBC]Error establishing > socket. > > > > at > > > > > > > > > > org.apache.commons.dbcp.DriverConnectionFactory.createConnecti > on(DriverC > onne > > > > ctionFactory.java:85) > > > > at > > > > > > > > > > org.apache.commons.dbcp.PoolableConnectionFactory.makeObject(P > oolableCon > nect > > > > ionFactory.java:184) > > > > at > > > > > org.apache.commons.pool.impl.GenericObjectPool.borrowObject(Unknown > > > Source) > > > > at > > > > > > > > > > org.apache.commons.dbcp.AbandonedObjectPool.borrowObject(Aband > onedObject > Pool > > > > .java:117) > > > > at > > > > > > > > > > org.apache.commons.dbcp.PoolingDataSource.getConnection(Poolin > gDataSourc > e.ja > > > > va:110) > > > > at > > > > > > > > > > org.apache.commons.dbcp.BasicDataSource.getConnection(BasicDat > aSource.ja > va:3 > > > > 12) > > > > at > com.happypuppy.util.HPSql.getConnection(HPSql.java:21) > > > > at > com.happypuppy.util.HPUser.isLoggedIn(HPUser.java:121) > > > > at > > > > > org.apache.jsp.checkLoggedIn_jsp._jspService(checkLoggedIn_jsp > .java:56) > > > > at > > > > > org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:137) > > > > at > javax.servlet.http.HttpServlet.service(HttpServlet.java:853) > > > > at > > > > > > > > > > org.apache.jasper.servlet.JspServletWrapper.service(JspServlet > Wrapper.ja > va:2 > > > > 04) > > > > at > > > > > org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet > .java:295) > > > > at > > > org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241) > > > > at > javax.servlet.http.HttpServlet.service(HttpServlet.java:853) > > > > at > > > > > > > > > > org.apache.catalina.core.ApplicationDispatcher.invoke(Applicat > ionDispatc > her. > > > > java:684) > > > > at > > > > > > > > > > org.apache.catalina.core.ApplicationDispatcher.doInclude(Appli > cationDisp > atch > > > > er.java:575) > > > > at > > > > > > > > > > org.apache.catalina.core.ApplicationDispatcher.include(Applica > tionDispat > cher > > > > .java:498) > > > > at > > > > > > > > > > org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntime > Library.ja > va:8 > > > > 22) > > > > at > org.apache.jsp._404_jsp._jspService(_404_jsp.java:351) > > > > at > > > > > org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:137) > > > > at > javax.servlet.http.HttpServlet.service(HttpServlet.java:853) > > > > at > > > > > > > > > > org.apache.jasper.servlet.JspServletWrapper.service(JspServlet > Wrapper.ja > va:2 > > > > 04) > > > > at > > > > > org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet > .java:295) > > > > at > > > org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241) > > > > at > javax.servlet.http.HttpServlet.service(HttpServlet.java:853) > > > > at > > > > > > > > > > org.apache.catalina.core.ApplicationFilterChain.internalDoFilt > er(Applica > tion > > > > FilterChain.java:247) > > > > at > > > > > > > > > > org.apache.catalina.core.ApplicationFilterChain.doFilter(Appli > cationFilt > erCh > > > > ain.java:193) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardWrapperValve.invoke(StandardW > rapperValv > e.ja > > > > va:260) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline$StandardPipelineValv > eContext.i > nvok > > > > eNext(StandardPipeline.java:643) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline.invoke(StandardPipel > ine.java:4 > 80) > > > > at > > > > > org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardContextValve.invoke(StandardC > ontextValv > e.ja > > > > va:191) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline$StandardPipelineValv > eContext.i > nvok > > > > eNext(StandardPipeline.java:643) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline.invoke(StandardPipel > ine.java:4 > 80) > > > > at > > > > > org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) > > > > at > > > > > > > org.apache.catalina.core.StandardContext.invoke(StandardContex > t.java:241 > 5) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardHostValve.invoke(StandardHost > Valve.java > :180 > > > > ) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline$StandardPipelineValv > eContext.i > nvok > > > > eNext(StandardPipeline.java:643) > > > > at > > > > > > > > > > org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDi > spatcherVa > lve. > > > > java:170) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline$StandardPipelineValv > eContext.i > nvok > > > > eNext(StandardPipeline.java:641) > > > > at > > > > > > > > > > org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReport > Valve.java > :172 > > > > ) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline$StandardPipelineValv > eContext.i > nvok > > > > eNext(StandardPipeline.java:641) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline.invoke(StandardPipel > ine.java:4 > 80) > > > > at > > > > > org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardEngineValve.invoke(StandardEn > gineValve. > java > > > > :174) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline$StandardPipelineValv > eContext.i > nvok > > > > eNext(StandardPipeline.java:643) > > > > at > > > > > > > > > > org.apache.catalina.core.StandardPipeline.invoke(StandardPipel > ine.java:4 > 80) > > > > at > > > > > org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) > > > > at > > > > > org.apache.ajp.tomcat4.Ajp13Processor.process(Ajp13Processor.java:458) > > > > at > > > > > org.apache.ajp.tomcat4.Ajp13Processor.run(Ajp13Processor.java:551) > > > > at java.lang.Thread.run(Thread.java:536) > > > > Caused by: java.sql.SQLException: [Microsoft][SQLServer 2000 > Driver > for > > > > JDBC]Error establishing socket. > > > > at > > com.microsoft.jdbc.base.BaseExceptions.createException(Unknown > > > > Source) > > > > at > com.microsoft.jdbc.base.BaseExceptions.getException(Unknown > > > > Source) > > > > at > com.microsoft.jdbc.base.BaseExceptions.getException(Unknown > > > > Source) > > > > at > com.microsoft.jdbc.sqlserver.tds.TDSConnection.<init>(Unknown > > > > Source) > > > > at > > > com.microsoft.jdbc.sqlserver.SQLServerImplConnection.open(Unknown > > > > Source) > > > > at > > > > > com.microsoft.jdbc.base.BaseConnection.getNewImplConnection(Unknown > > > Source) > > > > at com.microsoft.jdbc.base.BaseConnection.open(Unknown > Source) > > > > at com.microsoft.jdbc.base.BaseDriver.connect(Unknown > Source) > > > > at > > > > > > > > > > org.apache.commons.dbcp.DriverConnectionFactory.createConnecti > on(DriverC > onne > > > > ctionFactory.java:83) > > > > ... 51 more > > > > > > > > > > > > > --------------------------------------------------------------------- > > > > To unsubscribe, e-mail: > [EMAIL PROTECTED] > > > > For additional commands, e-mail: > [EMAIL PROTECTED] > > > > > > > > > > > > > > > --------------------------------------------------------------------- > > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > > For additional commands, e-mail: > [EMAIL PROTECTED] > > > > > > > > > > --------------------------------------------------------------------- > > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > > For additional commands, e-mail: > [EMAIL PROTECTED] > > > > > > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]