Thanks Daniel.

-> DB is getting restarted every weekend but tomcat is not getting restarted at 
the same time.
just fyi this issue doesnt happen every time. It happens once every month even 
if the DB is getting restarted every week.
So not sure wat is the exact root cause
->I have attached the server.xml. I dont find the Resource tag here..
>From java code, a data source is created using PoolableConnectionFactory and 
>GenericObjectPool and then a connection is retrieved from this datasource.

Let me know if you have any questions

--- On Thu, 19/7/12, Daniel Mikusa <dmik...@vmware.com> wrote:

> From: Daniel Mikusa <dmik...@vmware.com>
> Subject: Re: java.sql.SQLException: No more data to read from socket
> To: "Tomcat Users List" <users@tomcat.apache.org>
> Date: Thursday, 19 July, 2012, 9:53 PM
> ----- Original Message -----
> > Thanks Daniel and Jose.
> > Do you knoe what is the root cause of this issue
> 
> It's hard to say since you have not answered the questions
> from my previous email, you have not posted your data source
> configuration and you have only posted a partial stack
> trace.
> 
> Nevertheless, I will venture a guess.  *If* you are in
> fact restarting your Oracle database then that would
> disconnect any persistent connections maintained by the
> connection pool.  
> 
> Given that your connection pool would contain a bunch of
> connections which have been disconnected, you would either
> need to restart Tomcat (which will create a fresh connection
> pool) or configure your connection pool to find and replace
> the closed connections (hence the suggestion to use a
> validationQuery).
> 
> That's just a guess though, I do not believe that the amount
> of information that you have provided is sufficient to give
> you an exact answer.
> 
> Dan
> 
> 
> 
> > 
> > --- On Thu, 19/7/12, Daniel Mikusa <dmik...@vmware.com>
> wrote:
> > 
> > > From: Daniel Mikusa <dmik...@vmware.com>
> > > Subject: Re: java.sql.SQLException: No more data
> to read from
> > > socket
> > > To: "Tomcat Users List" <users@tomcat.apache.org>
> > > Date: Thursday, 19 July, 2012, 5:39 PM
> > > ----- Original Message -----
> > > > Jose,
> > > > Tomcat is using JDK 1.5 and its JDBC
> driver.So I am not
> > > sure if I
> > > > need to upgrade the JDBC driver.
> > > 
> > > >I suspect that whene DB is getting restarted,
> > > 
> > > Are you restarting the Oracle database without
> restarting
> > > your Tomcat instance?  Depending on how your
> > > application gets a database connection this could
> be an
> > > issue.
> > > 
> > > > the idle connections are being removed.
> > > 
> > > Are you using Tomcat DataSource to manage your
> > > connections?  If so, please include your
> > > <Resource/> tag.
> > > 
> > > > Not sure how we can avoid this situation
> > > 
> > > If you are using a DataSource, you could try
> adding
> > > validation.  With DBCP this is done by adding a
> > > "validationQuery" option.  For more details, see
> the
> > > following link.
> > > 
> > >   https://commons.apache.org/dbcp/configuration.html
> > > 
> > > Dan
> > > 
> > > 
> > > > 
> > > > Thanks and Regards,
> > > > Vijay Mathew
> > > > 
> > > > --- On Thu, 19/7/12, Jose María Zaragoza
> <demablo...@gmail.com>
> > > > wrote:
> > > > 
> > > > > From: Jose María Zaragoza <demablo...@gmail.com>
> > > > > Subject: Re: java.sql.SQLException: No
> more data
> > > to read from
> > > > > socket
> > > > > To: "Tomcat Users List" <users@tomcat.apache.org>
> > > > > Date: Thursday, 19 July, 2012, 1:28 PM
> > > > > 2012/7/19 vijay mathew <vijaymathew2...@yahoo.com>:
> > > > > > My application is using Tomcat 5.5
> It works
> > > fine all
> > > > > the time however at times when I try to
> login to
> > > the
> > > > > application I get the below exception
> > > > > > java.sql.SQLException: No more data
> to read
> > > from
> > > > > socket
> > > > > >         at
> > > > >
> > >
> oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:74)
> > > > > >         at
> > > > >
> > >
> oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:110)
> > > > > >         at
> > > > >
> > >
> oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:171)
> > > > > > Once restart , the application
> works fine.
> > > > > >
> > > > > > How to fix this issue
> > > > > >
> > > > > 
> > > > > Looks like a JDBC driver issue . Are you
> try to
> > > upgrade it
> > > > > ?
> > > > > 
> > > > >
> > >
> ---------------------------------------------------------------------
> > > > > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> > > > > For additional commands, e-mail: users-h...@tomcat.apache.org
> > > > > 
> > > > >
> > > > 
> > > >
> > >
> ---------------------------------------------------------------------
> > > > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> > > > For additional commands, e-mail: users-h...@tomcat.apache.org
> > > > 
> > > >
> > > 
> > >
> ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> > > For additional commands, e-mail: users-h...@tomcat.apache.org
> > > 
> > >
> > 
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> > For additional commands, e-mail: users-h...@tomcat.apache.org
> > 
> > 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
> 
>
  <?xml version="1.0" encoding="UTF-8" ?> 
 <Server port="8077" shutdown="SHUTDOWN" debug="0">
  <Listener className="org.apache.catalina.mbeans.ServerLifecycleListener" debug="0" /> 
  <Listener className="org.apache.catalina.mbeans.GlobalResourcesLifecycleListener" debug="0" /> 
  <Listener className="org.apache.catalina.storeconfig.StoreConfigLifecycleListener" debug="0" /> 
 <Service name="Agent8077">
  <Connector port="8079" maxThreads="150" minSpareThreads="25" maxSpareThreads="75" enableLookups="false" redirectPort="8443" acceptCount="100" debug="0" connectionTimeout="20000" disableUploadTimeout="true" /> 
  <Connector port="8078" enableLookups="false" tomcatAuthentication="false" redirectPort="8443" minProcessors="10" maxProcessors="5000" acceptCount="100" debug="0" protocol="AJP/1.3" connectionTimeout="300000" /> 
 <Engine jvmRoute="st2489" name="Agent8077" defaultHost="localhost" debug="0">
 <Manager className="org.apache.catalina.session.PersistentManager" debug="0" saveOnRestart="true" maxActiveSessions="-1" minIdleSwap="315" maxIdleSwap="390" maxIdleBackup="300">
  <Store className="org.apache.catalina.session.FileStore" /> 
  </Manager>
 <Host name="localhost" debug="0" appBase="webapps" unpackWARs="false" autoDeploy="true" xmlValidation="false" xmlNamespaceAware="false">
 <DefaultContext>
  <Parameter name="MrkJvmHttp" value="8079" override="false" /> 
  </DefaultContext>
  <Context path="/mrl" docBase="/websites/mrl.int.com/java/mrl" debug="0" privileged="false" /> 
  </Host>
  </Engine>
  </Service>
  </Server>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to