473,390 Members | 1,398 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,390 software developers and data experts.

Can someone enlighten me on 'handles'?

Hi there.

Recently, one of our application servers is moaning about its handles.
(no more handles available).

I'm guessing it has to do with some bug in our software where it does
not release handles properly and every x thousand queries, one available
handle gets lost (unreleased).

Are handles available PER application, or is there one general pool of
handles from which agents get their share?

In DB2 8.2 LUW 64bit, how many handles are available?
Can this limit be changed or is it hardcoded?

Can I get an overview of handles in use/available (I know about the
application snapshot, but I was hoping for something a little more...
brief.)

Can I assume for every cursor in use, 1 handle is allocated en vice
versa? Or is this wrong to think when you have a query that operates on
multiple datebbase objects. (for instance, 1 query that joins over 3
tables. Is that 1 handle and 3 cursors?)

Perhaps someone knows of some interesting reading on this subject.
Searching for handles in 1 pain in the ** because all I get is how DB2
is *handling* some stuff.

Thanks.

-R-
Jun 27 '08 #1
7 1934
"Jurgen Haan" <ju****@fake.tldwrote in message
news:48***********************@news.xs4all.nl...
Hi there.

Recently, one of our application servers is moaning about its handles.
(no more handles available).

I'm guessing it has to do with some bug in our software where it does
not release handles properly and every x thousand queries, one available
handle gets lost (unreleased).

Are handles available PER application, or is there one general pool of
handles from which agents get their share?

In DB2 8.2 LUW 64bit, how many handles are available?
Can this limit be changed or is it hardcoded?

Can I get an overview of handles in use/available (I know about the
application snapshot, but I was hoping for something a little more...
brief.)

Can I assume for every cursor in use, 1 handle is allocated en vice
versa? Or is this wrong to think when you have a query that operates on
multiple datebbase objects. (for instance, 1 query that joins over 3
tables. Is that 1 handle and 3 cursors?)

Perhaps someone knows of some interesting reading on this subject.
Searching for handles in 1 pain in the ** because all I get is how DB2
is *handling* some stuff.

Thanks.

-R-
Most likely, the applications are not closing transactions as soon as they
could (or should). Or they are not committing as often as they should. These
are common problems in many shops these days where programmers are very
poorly trained.
Jun 27 '08 #2
Mark A wrote:
>
Most likely, the applications are not closing transactions as soon as they
could (or should). Or they are not committing as often as they should. These
are common problems in many shops these days where programmers are very
poorly trained.

Lol!

I kind of figured it's most likely to be a fault in our software.
But nevertheless, I would like some clarification on the subjects stated
in my original post; First to be able to answer the programmers'
specific questions, and second for my own peace of mind, I like to know
what's going on under the bonnet.

And in defence of our programmers; they know their stuff, but mistakes
are easily made. (know that a hardcopy of your reply is going their way. :P)

Thanks for your reply.

-R-
Jun 27 '08 #3
On Jun 5, 1:17*pm, Jurgen Haan <jur...@fake.tldwrote:
Hi there.

Recently, one of our application servers is moaning about its handles.
(no more handles available).

I'm guessing it has to do with some bug in our software where it does
not release handles properly and every x thousand queries, one available
handle gets lost (unreleased).

Are handles available PER application, or is there one general pool of
handles from which agents get their share?

In DB2 8.2 LUW 64bit, how many handles are available?
Can this limit be changed or is it hardcoded?

Can I get an overview of handles in use/available (I know about the
application snapshot, but I was hoping for something a little more...
brief.)

Can I assume for every cursor in use, 1 handle is allocated en vice
versa? Or is this wrong to think when you have a query that operates on
multiple datebbase objects. (for instance, 1 query that joins over 3
tables. Is that 1 handle and 3 cursors?)

Perhaps someone knows of some interesting reading on this subject.
Searching for handles in 1 pain in the ** because all I get is how DB2
is *handling* some stuff.

Thanks.

-R-
Please always supply DB2 version and OS/platform.

Assuming DB2 LUW v8, here is some info on different type of "handles":
http://publib.boulder.ibm.com/infoce...d/c0004933.htm

HTH

--
Jeroen
Jun 27 '08 #4
>"Jeroen van den Broek" <nl****@baasbovenbaas.demon.nlwrote in message
>news:6b**********************************@c58g200 0hsc.googlegroups.com...
Please always supply DB2 version and OS/platform.
Assuming DB2 LUW v8, here is some info on different type of "handles":
http://publib.boulder.ibm.com/infoce...d/c0004933.htm

HTH
Jeroen
Although the OP did not state it explicitly, my guess is that the problem is
cursor handles. Java programmers usually don't have to open a cursor, even
though the JDBC interface opens one (or many) cursors for them depending on
what they are doing.

The resulting error is usually a -805 "package not found" when DB2 runs out
of system packages to handle cursors (usually large cursors). The large
cursor packages can handle thousands of handles each, but for some sloppy
programs that is not enough. The default is to have 3 large cursor packages
available, and the error is returned when DB2 cannot find the 4th package
(the first large cursor package ends in x'00', so the 4th one end in x'03').
This can be increased to 30 packages by rebinding the package with an option
to have more, but in my experience if the programmers can't get by with 3,
they will soon exhaust all 30 if you give them that many. They are like drug
addicts, the more you give them, the more they want.

Now it is possible, since the OP did not mention -805 error code, then he is
experiences some other type of handle problem. In that case it would help to
have more detailed information about what error message is being received.
Jun 27 '08 #5
Mark A wrote:
>"Jeroen van den Broek" <nl****@baasbovenbaas.demon.nlwrote in
message
news:6b**********************************@c58g200 0hsc.googlegroups.com...
Please always supply DB2 version and OS/platform. Assuming DB2 LUW v8,
here is some info on different type of
"handles":
http://publib.boulder.ibm.com/infoce...d/c0004933.htm

HTH
Jeroen

Although the OP did not state it explicitly, my guess is that the
problem is cursor handles. Java programmers usually don't have to
open a cursor, even though the JDBC interface opens one (or many)
cursors for them depending on what they are doing.

The resulting error is usually a -805 "package not found" when DB2
runs out of system packages to handle cursors (usually large
cursors). The large cursor packages can handle thousands of handles
each, but for some sloppy programs that is not enough. The default is
to have 3 large cursor packages available, and the error is returned
when DB2 cannot find the 4th package (the first large cursor package
ends in x'00', so the 4th one end in x'03'). This can be increased to
30 packages by rebinding the package with an option to have more, but
in my experience if the programmers can't get by with 3, they will
soon exhaust all 30 if you give them that many. They are like drug
addicts, the more you give them, the more they want.
Now it is possible, since the OP did not mention -805 error code,
then he is experiences some other type of handle problem. In that
case it would help to have more detailed information about what error
message is being received.
Yep, that's why I only could offer the link to the docs.
It could even be OP has issues with file handles on OS level...

--
Jeroen
Jun 27 '08 #6
Jeroen van den Broek wrote:
On Jun 5, 1:17 pm, Jurgen Haan <jur...@fake.tldwrote:
>Hi there.

Recently, one of our application servers is moaning about its handles.
(no more handles available).

I'm guessing it has to do with some bug in our software where it does
not release handles properly and every x thousand queries, one available
handle gets lost (unreleased).

Are handles available PER application, or is there one general pool of
handles from which agents get their share?

In DB2 8.2 LUW 64bit, how many handles are available?
Can this limit be changed or is it hardcoded?

Can I get an overview of handles in use/available (I know about the
application snapshot, but I was hoping for something a little more...
brief.)

Can I assume for every cursor in use, 1 handle is allocated en vice
versa? Or is this wrong to think when you have a query that operates on
multiple datebbase objects. (for instance, 1 query that joins over 3
tables. Is that 1 handle and 3 cursors?)

Perhaps someone knows of some interesting reading on this subject.
Searching for handles in 1 pain in the ** because all I get is how DB2
is *handling* some stuff.

Thanks.

-R-

Please always supply DB2 version and OS/platform.

Assuming DB2 LUW v8, here is some info on different type of "handles":
http://publib.boulder.ibm.com/infoce...d/c0004933.htm

HTH

--
Jeroen
:S

I quote:
"In DB2 8.2 LUW 64bit, how many handles are available?"
Jun 27 '08 #7
Jeroen van den Broek wrote:
>
Assuming DB2 LUW v8, here is some info on different type of "handles":
http://publib.boulder.ibm.com/infoce...d/c0004933.htm

HTH

--
Jeroen
Thank you. Is a very helpful link.
Jun 27 '08 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

11
by: Rohit | last post by:
Hi, Threads in the .NET Framework 1.1 (and possibly in 1.0 also) leak "Event" handles, by Event handles I mean Win32 Event handles which can be monitored using the ProcessExplorer from...
1
by: benc | last post by:
Hi Can anyone enlighten why dispose() a form does not seems to release window handles. My .NET app crushes after while, typically when window handles > 1400 or so. My main form creates/inits about...
3
by: Alex | last post by:
I'm having a problem porting an ASP solution to ASPX. In the ASP solution I'm accessing a DCOM server, create sub DCOM objects and call functions from VB script on the ASP pages. The DCOM object...
3
by: Sean | last post by:
HI There, I am trying to submit a form when a selection is made from a dropdown list, I keep getting the error "Handles clause requires With Events Variable". Could someone help me with the...
3
by: Shapper | last post by:
Hello, I have a third party control in my page. I need to set the properties of Labels and Images in this control when: 1. User enters the Page. 2. A button is clicked which changes culture...
9
by: M. Posseth | last post by:
i have 3 forms Public Class Form1 Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim frm As New Form2 frm.Show(Me) End Sub...
4
by: Ron | last post by:
I am having a bit of problem with this code: Dim cmd As New OleDb.OleDbCommand("INSERT INTO help (Name, Email, telephone, description)VALUES('" & txtName.Text & "','" & txtEmail.Text & "','" &...
4
by: lmefford | last post by:
Ok, so I've got a weird question. I'm working with an outside class that someone made that will save the application settings in the Application Data Folder. However, one problem I'm having, and I...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.