Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: OPEN_CURSORS ??

Re: OPEN_CURSORS ??

From: Thomas Kyte <tkyte_at_us.oracle.com>
Date: Thu, 30 Dec 1999 07:58:23 -0500
Message-ID: <film6s8522pm7eubup51jn9s95to2dk888@4ax.com>


A copy of this was sent to "Alan Sze" <alan_at_icon.com.hk> (if that email address didn't require changing) On Thu, 30 Dec 1999 18:08:46 +0800, you wrote:

>
>Hi,
>
>I'm using Oracle8i on Solaris 2.6, and Netscape Enterprise Server 3.6
>and WebSphere 3. I found that the system will be down and not accessible
>after some time. The error comes from getting connection through JDBC
>failure.
>
>Does increasing the OPEN_CURSORS parameter help in this situation??

it will probably in your case POSTPONE the erro.

>How does the parameter OPEN_CURSORS affects the Oracle8i??
>If I set it to 500, will it use up lots of memory and slow down the system??

probably not. I have mine set to 1,000

>How can I check the number of active (or un-closed) connections to
>Oracle8i??
>

v$session will show you connections.
v$open_cursor will show you open, unclosed cursors.

In jdbc, this is almost always due to NOT closing result sets, callable statements, prepared statements and the like. If you let them go out of scope -- the cursor associated with them stays open until the jdbc app logs off. Websphere is most likely not disconnecting from the database after each call, hence the cursor leaks you have build up over time.

you can use v$open_cursor to identify the cursors (the sql statments can be seen in there) and then go back to the source and ensure you are closing them in your application.

>Thanks in advance, and Happy Millenmium.
>
>-- Alan
>
>

--
See http://osi.oracle.com/~tkyte/ for my columns 'Digging-in to Oracle8i'... Current article is "Part I of V, Autonomous Transactions" updated June 21'st  

Thomas Kyte                   tkyte_at_us.oracle.com
Oracle Service Industries     Reston, VA   USA

Opinions are mine and do not necessarily reflect those of Oracle Corporation Received on Thu Dec 30 1999 - 06:58:23 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US