If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > DB2 goes mad using CPU for no particular reason

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 09-09-09, 06:36
grofaty grofaty is offline
Registered User
 
Join Date: Jan 2003
Posts: 1,570
DB2 goes mad using CPU for no particular reason

Hi,
in January current year we have migrated to DB2 Enterprise Edition v9.5 fixpack 2 on Linux and DB2 was working without any problem at all. Only two times so far on weekends (Saturday or Sunday) there was some extensive CPU usage on DB2. Process db2sysc was going mad and consumed 100% of CPU for hours despite usually on weekends there is no more then 10% CPU peek. I have analyzed db2diag.log file and there was absolutely no error or any other message for hours in this file. It looks like DB2 stopped logging to db2diag.log and the only message is then DB2 manager is starting up. There was also no application connected to database at the time that would consume CPU. After about 1 hour of extensive CPU usage applications couldn't connect on database any more. So there was a night wake-up call. I have checked and db2sysc process was constantly consuming more and more CPU power with no particular reason, there was no application connected on database that would consume CPU!

This kind of behaviour is extremely strange. On weekends there is almost no application activity on DB2. On week-day there are 100-times more DB2 transactions then on weekends.

On migration day on this database I have turned on self-tuning for every parameter that was possible to turn on and DB2 was working like a charm (way better performance). I just have an assumption that DB2 recognizes that there is very little activities on database and self-tuning is executing some tasks that goes mad. Just an assumption... I don't know what is happening because there are no info in log files.

Anyone experiencing the same problem? Any idea what should I check?
Regards

Last edited by grofaty; 09-09-09 at 06:42.
Reply With Quote
  #2 (permalink)  
Old 09-09-09, 08:21
ARWinner ARWinner is offline
Registered User
 
Join Date: Jan 2003
Posts: 3,575
We had a similar problem a few months ago, but it would happen randomly throughout the day. DB2 would just seem to hang from just a minute or so to nearly an hour. We opened a PMR with IBM and found that DB2 was doing some memory defragmentation in one of the caches. When it decided to do this, the system would hang until it finished. The solution was to set db_mem_thresh to 100.

You can try this, but I would suggest that you open a PMR with IBM. They have some better diagnostic tools with v9.5, especially when the systems seems to hang.

Andy
Reply With Quote
  #3 (permalink)  
Old 09-09-09, 08:48
grofaty grofaty is offline
Registered User
 
Join Date: Jan 2003
Posts: 1,570
ARWinner,
your description looks like my second problem!!! It just looks like that DB2 freezes for some seconds: 5 to 20 seconds reported by end-users. They just reported that running the same application 10-times runs in fraction of second, but some times it runs for 10 seconds. This started to happend 14-days ago according to end-user report.
In my case DB_MEM_THRESH is set to default value of 10. Any more info is greatly appreciated.
Thanks a lot.
Reply With Quote
  #4 (permalink)  
Old 09-09-09, 09:53
n_i n_i is offline
:-)
 
Join Date: Jun 2003
Location: Toronto, Canada
Posts: 4,449
You could use the db2top tool for additional troubleshooting.
Reply With Quote
  #5 (permalink)  
Old 09-09-09, 09:58
ARWinner ARWinner is offline
Registered User
 
Join Date: Jan 2003
Posts: 3,575
If you are getting hangs, then I would open a PMR and get it fixed.

Andy
Reply With Quote
  #6 (permalink)  
Old 09-10-09, 01:32
grofaty grofaty is offline
Registered User
 
Join Date: Jan 2003
Posts: 1,570
Quote:
Originally Posted by n_i
You could use the db2top tool for additional troubleshooting.
I have executed db2top command with db2inst1 super-user and got error:
"-bash: db2top: command not found"

According to documentation:
"db2top is a monitor for DB2 UDB specifically designed for
DPF environments. It provides a unified, ’single system
view’ of a multi-partition DB2 database."

We are not using DPF, so this tool is not available in our ESE version.
Reply With Quote
  #7 (permalink)  
Old 09-10-09, 07:33
n_i n_i is offline
:-)
 
Join Date: Jun 2003
Location: Toronto, Canada
Posts: 4,449
It should be included with 9.5. fp2. I'm not sure if it is installed in ~/sqllib/bin, which is in the path. Try searching for it, e.g.
Code:
find ~/sqllib -name db2top -ls
Reply With Quote
  #8 (permalink)  
Old 09-10-09, 07:42
grofaty grofaty is offline
Registered User
 
Join Date: Jan 2003
Posts: 1,570
Hi,
I have tried to search the whole disk:
Code:
sudo find / -name db2top -ls
but no program was found.

Is this program installed separately? Is this Linux/Intel specific? This my DB2 is on Linux on hardware: System_z.
Regards

Last edited by grofaty; 09-10-09 at 07:54.
Reply With Quote
  #9 (permalink)  
Old 09-10-09, 08:02
ARWinner ARWinner is offline
Registered User
 
Join Date: Jan 2003
Posts: 3,575
db2top should be in {INSTHOME}/sqllib/bin/. That is where it is in our environment, which is RH linux single partition DB2 is ESE. We are using V9.5 FP 4 and FP 3a.

Andy
Reply With Quote
  #10 (permalink)  
Old 09-10-09, 08:18
grofaty grofaty is offline
Registered User
 
Join Date: Jan 2003
Posts: 1,570
Hi,
I have checked on Suse Linux on "System z" DB2 ESE single partition v9.5 FP 2. But db2top is not available in any path.

But I have checked on other test Intel computer: DB2 v9.7! and db2top is in /opt/ibm/db2/V9.7/bin/db2top. But I don't have any db2 v9.5/intel, to check if this is Linux/Intel specific.
Regards
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On