1) Make sure you have enough open cursors (specified as OPEN_CURSORS in your
init.ora file).

2) See what cursors you've got open after running your page(s) by doing,

    SELECT SQL_TEXT FROM SYS.V_$OPEN_CURSOR;

That'll tell you (more or less) what queries you've left open.

3) Make sure that you're closing all the connections, statements and result
sets you open.  In general, you should close resources in "finally" blocks,
like,

    ResultSet rs = stmt.executeQuery("SELECT 'X' FROM DUAL");

    try
    {
      // Handle the data in the result set,...
    }
    finally
    {
      try
      {
        rs.close();
      }
      catch (Exception ex)
      {
      }
    }

That way, if something crashes in the middle, you're still closing the
resource.

                                                            -- Bill K.


> -----Original Message-----
> From: Dan Randall [mailto:[EMAIL PROTECTED]]
> Sent: Monday, May 07, 2001 9:00 AM
> To: [EMAIL PROTECTED]
> Subject: Re: RE: Loosing Connections in a pool
> 
> 
> Hi Josh,
> 
> No, I am not receiving any error messages.  Well, not until 
> it crashes!  At that point, I get a java.lang out of memory 
> error.  It seems like an application (ours, not tomcat's) 
> resource leak to me, but I am searching for any know issues 
> with tomcat, jdbc, etc just in case.
> 
> Thanks,
> 
> Dan
> 
> >>> Joshua Sharp <[EMAIL PROTECTED]> 05/04 3:51 PM >>>
> Are you receiving any error messages? I know oracle 8.1.7 has 
> a connection
> limit of ~120/process before it runs out of file descriptors. 
> I haven't seen
> any problems with loosing connections though.
> 
> Josh
> 
> -----Original Message-----
> From: Dan Randall [mailto:[EMAIL PROTECTED]] 
> Sent: Friday, May 04, 2001 2:32 PM
> To: [EMAIL PROTECTED] 
> Subject: Loosing Connections in a pool
> 
> 
> Hi,
> 
> My tomcat application runs in a production environment for 
> about 24 hours
> before it fails and must be restarted.  During that time JDBC 
> connections to
> Oracle become ignored and eventually disappear.  A fair guess 
> is that I am
> loosing memory, threads and  resources in general until there 
> is nothing
> left and only a restart cures the matter.
> 
> Unfortunately, tomcat, rather than apache is serving much of 
> the pages and
> graphics.  That may be a contributing factor?
> 
> I am using:
> 
> Solaris 8
> Oracle 8.1.7
> tomcat 3.2.1
> apache 1.3.19
> and Java 1.3
> 
> Does anyone have an idea of what sort of problems I might be 
> having?  Any
> known resource leaks or threading issues?
> 
> Thanks!!
> 
> Dan
> <><><><><><><><><><><><><><><><><><><><><>This electronic 
> mail transmission
> may contain confidential information and is intended only for 
> the person(s)
> named.  Any use, copying or disclosure by any other person is strictly
> prohibited.  If you have received this transmission in error, 
> please notify
> the sender via e-mail. <><><><><><><><><><><><><><><><><><><><><>
> 

Reply via email to