473,498 Members | 2,026 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

problem with db2 commit on aix (lock and cuncurrency)

Dear all,

I got a problem on db2 for aix running a high workload messaging
system with more than 5,000,000 of deliveries per day. During high
peak hours it happens frequently that the application,
the application threads, are all waiting for a commit to complete.
This seems a typical case of a
missing or locked shared resource. The lock anyway is not at row or
table level during an SQL operation, but it is at commit time. In
fact, different applications at the same time are affected by
this problem. The db2 is v8.1 fixpak 14 and aix is 5.3 fixpak 05 with
5 processor (power5+ 1.6Ghz)
and 64 GB of memory. While the commit hang the db2 machine has no I/O
wait (no disk usage),
plenty of memory and processing power and plenty of network resources
(that's why I suspect
a lock).

To complete the scenario, the databases (same hw, same sw) are two in
continuos replication. The apply programs are running at the target
database. MIN_COMMIT is 5

The question is which monitoring parameter should I check to
understand what happen to
the db. Is there any operating-system resource that I can check?

As last thing, why the rootvg disks are working a lot? iostat says
that they write 8/10 MB per
second... I suspect something related to authentication due to
continuos connect/disconnect of replication, but I don't understand
what it matters with commit.

Thanks in advance
Matteo Gelosa

Jun 1 '07 #1
7 5190
Lew
I'm not sure I understand all that you are saying but I would get a
snapshot for locks and also look in the diag log to see if there are
lock escalations. Even though you have plenty of memory on the box if
you misconfigure your locklist and maxlocks parms you may still
encounter lock escalations. As far as the high i/o rates to rootvg ,
typically I see that when a system is paging since most systems have
their paging space in rootvg. It could be other obscure things like
maybe someone put database temp on rootvg or something like that.

On Jun 1, 12:24 pm, m.gel...@gmail.com wrote:
Dear all,

I got a problem on db2 for aix running a high workload messaging
system with more than 5,000,000 of deliveries per day. During high
peak hours it happens frequently that the application,
the application threads, are all waiting for a commit to complete.
This seems a typical case of a
missing or locked shared resource. The lock anyway is not at row or
table level during an SQL operation, but it is at commit time. In
fact, different applications at the same time are affected by
this problem. The db2 is v8.1 fixpak 14 and aix is 5.3 fixpak 05 with
5 processor (power5+ 1.6Ghz)
and 64 GB of memory. While the commit hang the db2 machine has no I/O
wait (no disk usage),
plenty of memory and processing power and plenty of network resources
(that's why I suspect
a lock).

To complete the scenario, the databases (same hw, same sw) are two in
continuos replication. The apply programs are running at the target
database. MIN_COMMIT is 5

The question is which monitoring parameter should I check to
understand what happen to
the db. Is there any operating-system resource that I can check?

As last thing, why the rootvg disks are working a lot? iostat says
that they write 8/10 MB per
second... I suspect something related to authentication due to
continuos connect/disconnect of replication, but I don't understand
what it matters with commit.

Thanks in advance
Matteo Gelosa

Jun 1 '07 #2
On Jun 1, 1:24 pm, m.gel...@gmail.com wrote:
Dear all,

I got a problem on db2 for aix running a high workload messaging
system with more than 5,000,000 of deliveries per day. During high
peak hours it happens frequently that the application,
the application threads, are all waiting for a commit to complete.
This seems a typical case of a
missing or locked shared resource. The lock anyway is not at row or
table level during an SQL operation, but it is at commit time. In
fact, different applications at the same time are affected by
this problem. The db2 is v8.1 fixpak 14 and aix is 5.3 fixpak 05 with
5 processor (power5+ 1.6Ghz)
and 64 GB of memory. While the commit hang the db2 machine has no I/O
wait (no disk usage),
plenty of memory and processing power and plenty of network resources
(that's why I suspect
a lock).

To complete the scenario, the databases (same hw, same sw) are two in
continuos replication. The apply programs are running at the target
database. MIN_COMMIT is 5

The question is which monitoring parameter should I check to
understand what happen to
the db. Is there any operating-system resource that I can check?

As last thing, why the rootvg disks are working a lot? iostat says
that they write 8/10 MB per
second... I suspect something related to authentication due to
continuos connect/disconnect of replication, but I don't understand
what it matters with commit.

Thanks in advance
Matteo Gelosa
Are you by chance running SDD version 1.6.1.2 or 1.6.2.0 on this
machine? There is a bug in these versions that caused the exact same
symptoms on our db2 instance. Our solution was to back level to
1.6.0.8 but i believe 1.6.2.1 has since been released to fix this
issue.

Paul

Jun 1 '07 #3
On 1 Giu, 18:44, Lew <seth...@yahoo.comwrote:

Well, the db2diag.log is empty and doesn't report any kind of error.
The suspected lock doesn't seem to be at row or table level. What I'm
sure
of is that the client applications are executing the commit (the CLI
api) and they
are waiting for an answer from the database server.

About paging, the machine is not paging. I tried with filemon but I
couldn't find
any relevant info. Anyway, thanks for your answer. I will try with
snapshot.
About the snapshots I was wondering if there is any COMMIT related
parameter
I can explore in order to solve my load problem.

Tnx
Matteo
I'm not sure I understand all that you are saying but I would get a
snapshot for locks and also look in the diag log to see if there are
lock escalations. Even though you have plenty of memory on the box if
you misconfigure your locklist and maxlocks parms you may still
encounter lock escalations. As far as the high i/o rates to rootvg ,
typically I see that when a system is paging since most systems have
their paging space in rootvg. It could be other obscure things like
maybe someone put database temp on rootvg or something like that.

On Jun 1, 12:24 pm, m.gel...@gmail.com wrote:
Jun 4 '07 #4
On 1 Giu, 19:10, stlh...@gmail.com wrote:
On Jun 1, 1:24 pm, m.gel...@gmail.com wrote:


Dear all,
I got a problem on db2 foraixrunning a high workload messaging
system with more than 5,000,000 of deliveries per day. During high
peak hours it happens frequently that the application,
the application threads, are all waiting for acommitto complete.
This seems a typical case of a
missing or locked shared resource. The lock anyway is not at row or
table level during an SQL operation, but it is atcommittime. In
fact, different applications at the same time are affected by
this problem. The db2 is v8.1 fixpak 14 andaixis 5.3 fixpak 05 with
5 processor (power5+ 1.6Ghz)
and 64 GB of memory. While thecommithang the db2 machine has no I/O
wait (no disk usage),
plenty of memory and processing power and plenty of network resources
(that's why I suspect
a lock).
To complete the scenario, the databases (same hw, same sw) are two in
continuos replication. The apply programs are running at the target
database. MIN_COMMIT is 5
The question is which monitoring parameter should I check to
understand what happen to
the db. Is there any operating-system resource that I can check?
As last thing, why the rootvg disks are working a lot? iostat says
that they write 8/10 MB per
second... I suspect something related to authentication due to
continuos connect/disconnect of replication, but I don't understand
what it matters withcommit.
Thanks in advance
Matteo Gelosa

Are you by chance running SDD version 1.6.1.2 or 1.6.2.0 on this
machine? There is a bug in these versions that caused the exact same
symptoms on our db2 instance. Our solution was to back level to
1.6.0.8 but i believe 1.6.2.1 has since been released to fix this
issue.

Paul- Nascondi testo tra virgolette -

- Mostra testo tra virgolette -
Unfortunately, we're not using SDD...

Tnx
Matteo

Jun 4 '07 #5
On 1 Giu, 18:44, Lew <seth...@yahoo.comwrote:

To add something: the application status with db2 list application
says
"Commit Active" for around the 400 transactions blocked. The I/O load
of the
log related disks (with iostat) is none... That's why I suspected a
lock
in a different place than rows/tables.

Bye,
Matteo

I'm not sure I understand all that you are saying but I would get a
snapshot for locks and also look in the diag log to see if there are
lock escalations. Even though you have plenty of memory on the box if
you misconfigure your locklist and maxlocks parms you may still
encounter lock escalations. As far as the high i/o rates to rootvg ,
typically I see that when a system is paging since most systems have
their paging space in rootvg. It could be other obscure things like
maybe someone put database temp on rootvg or something like that.
Jun 4 '07 #6
Ian
m.******@gmail.com wrote:
>
To complete the scenario, the databases (same hw, same sw) are two in
continuos replication. The apply programs are running at the target
database. MIN_COMMIT is 5
Have you read the documentation on MINCOMMIT? Setting it to 1 means
that transactions must wait for either MINCOMMIT other transactions to
issue a commit, OR 1 second has passed.

Even on very busy systems (200 trxn/s), MINCOMMIT=1 is often sufficient.

I would suggest tuning MINCOMMIT way down -- perhaps back to 1 to check
performance. *Maybe* increase it to 2, if absolutely necessary.

Jun 4 '07 #7
On 4 Giu, 19:09, Ian <ianb...@mobileaudio.comwrote:

I tried, but the behavior is the same. Anyway, I suspect something
related to replication. When the replication is down (no apply program
running) the db is working well.
As just as I turn on the replication, it starts to have the behavior I
mentioned, by blocking 400 tnxs in a Commit Active state. I googled
for "Commit Active" and I found one message of mine of some years ago
related to db2 replication hang in a "Commit Active" state, solved
with a fixpak downgrade. I don't want to say it's a db2 replication
bug, but I suspect something wrong in the configuration of this area.
Besides, the control database for replication resides is the source
database (so the replication control tables reside on it), that has a
much higher frequence of the hang I experience.
As last info I discovered, even the "get snapshot for locks on <db>"
is blocked until the "commit active" finished,
while other snapshots (bufferpools, applications, ...) work.

Tnx,
Matteo
m.gel...@gmail.com wrote:
To complete the scenario, the databases (same hw, same sw) are two in
continuos replication. The apply programs are running at the target
database. MIN_COMMIT is 5

Have you read the documentation on MINCOMMIT? Setting it to 1 means
that transactions must wait for either MINCOMMIT other transactions to
issue acommit, OR 1 second has passed.

Even on very busy systems (200 trxn/s), MINCOMMIT=1 is often sufficient.

I would suggest tuning MINCOMMIT way down -- perhaps back to 1 to check
performance. *Maybe* increase it to 2, if absolutely necessary.

Jun 5 '07 #8

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

Similar topics

7
5589
by: John Bailo | last post by:
I'm seeing some odd locking behavior when using an DB2400 database and running an ado.net transaction. My code -- in simplified form, appears at the bottom. I want to run several INSERT...
2
1653
by: Bjørn T Johansen | last post by:
I run the following SQL before updating one table: "lock table tablename" but when I try do update the same table later on, the lock table command just hangs (i.e the table is already locked)....
2
4456
by: xixi | last post by:
i am using type 4 driver with fp3 on windows 64bit server, auto commit is true, cursor is CS type. i have a sensitive , updatable cursor open and bring back a one row resultset, i get this...
0
5380
by: Fan Ruo Xin | last post by:
Nothing got wrong with DB2 COMMIT, db2 cfg, ... Even you did an "insert some_id+1 ..." immediately after you did "select max(some_id) from .... " in session1. This will not block the operations...
2
19505
by: Ray | last post by:
I have a list of about 20,000 rows that I am updating. I loop through each row in my program and basically do the following (1) select * from TABLE where SID= for update /*lock the row*/ (2)...
0
1623
by: John Bailo | last post by:
I'm seeing some odd locking behavior when using an DB2400 database and running an ado.net transaction. My code -- in simplified form, appears at the bottom. I want to run several INSERT...
14
6296
by: Sharon | last post by:
Hi all. I have an ArrayList and sometimes while enumerating through, i get an exception because another thread has added to the ArrayList. To solve this problem, i lock the enumeration, passing...
0
2992
by: cburnett | last post by:
Have a peculiar problem regarding lock escalation. Originally lock escalation was occurring because of an application changing most of the rows in a large table. After setting locksize to table to...
1
6881
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...
0
7375
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5456
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
4899
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4584
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3088
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3078
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1411
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
650
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.