niXforums Forum Index
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   PreferencesPreferences   Log in to check your private messagesLog in to check your private messages   Log inLog in 
·  nixdoc.net ·  man pages ·  Linux HOWTOs ·  FreeBSD Tips ·  Forums
navigation Forum index » Databases » IBM DB2
How to analyse poor performance of the database
Post new topic   Reply to topic Page 1 of 1 [4 Posts] View previous topic :: View next topic
Author Message
Civilian_Target
*nix forums beginner


Joined: 26 May 2005
Posts: 3

PostPosted: Mon Feb 14, 2005 8:22 am    Post subject: Re: How to analyse poor performance of the database Reply with quote

sac wrote:
Quote:
I am using DB2 v8.1 on UNIX.
At times the database shows extremely poor performance.
I do not have dba/admin rights nor do I have the web based client for
db2 v8.1.
I have only command line access.
Also DBA support starts after our jobs have completed.
(1) Is there any command that I could use from command line to find
out the process taking up maximum of the database resources ?

Well, yes. See 2.

Quote:
(2) Can the database snapshot be used for this purpose ?

Yep. You want to take a snapshot and read it. Any blaring performance
problems will generally be evident in the summary, the top 4 screenfuls
of info.

Classic performance problems would be evident from "High water mark for
connections", "Time database waited on locks" and "Deadlocks detected".
If you're getting high numbers for either of the first two, or any of
the third, your web app is probably causing DB2 performance issues.

Sometimes of course, a misconfigured DB2 server is the issue, such as
lack of indexing. For this, you should find the statement in the
"Dynamic SQL Snapshot Result" with the highest Total Execution Times.
Copy the statement text and load it into the DB2 control centre on any
server with a complete copy of the DB you're testing, and run a "Query
Plan" on it. If you can see any TSCANs, or any blaring loss of execution
time on a certain part of the statement, you should be able to either
index it, fix your code so that it never occurs, or if worst comes to
worst, set the table to volatile cardinality.

Quote:
(3) Is there any log created by DB2 which could be used for finding
the process consuming database resources ?

I don't follow you here, (2) may cover it.

Civilian_Target
Back to top
Thiru
*nix forums addict


Joined: 20 May 2005
Posts: 80

PostPosted: Mon Feb 14, 2005 5:26 am    Post subject: Re: How to analyse poor performance of the database Reply with quote

Hi,
If you have enough privilege(Sysadmin Authority), monitoring
switches has to be turned on. This can be done by using

update dbm cfg using <Monitoring Switch Name> on IMMEDIATE;

Then snapshot can be taken by using

get snapshot for dynamic sql on <database alias>;

Obtained output can be used for analysis purpose.

Cheers,
Thiru
WantedToBeDBA.
Back to top
Vincent M
*nix forums Guru


Joined: 22 Feb 2005
Posts: 1332

PostPosted: Sun Feb 13, 2005 2:10 pm    Post subject: Re: How to analyse poor performance of the database Reply with quote

"sac" <schoubal@gmail.com> wrote in message
news:15260680.0502130653.42b9a279@posting.google.com...
Quote:
I am using DB2 v8.1 on UNIX.
At times the database shows extremely poor performance.
I do not have dba/admin rights nor do I have the web based client for
db2 v8.1.
I have only command line access.
Also DBA support starts after our jobs have completed.
(1) Is there any command that I could use from command line to find
out the process taking up maximum of the database resources ?
(2) Can the database snapshot be used for this purpose ?
(3) Is there any log created by DB2 which could be used for finding
the process consuming database resources ?

I would appreciate any help in this direction.
Thanks in advance !

You could turn on the statement monitor and do a snapshot for dynamic
statements. It will tell you the number of times each SQL statement was
executed during the snapshot window, the total execution time, total CPU
time, etc. Then you could take the ones with high average times and do
explains on them.

But you need sysadmin authority to do the snapshots.
Back to top
sac
*nix forums beginner


Joined: 13 Feb 2005
Posts: 6

PostPosted: Sun Feb 13, 2005 1:53 pm    Post subject: How to analyse poor performance of the database Reply with quote

I am using DB2 v8.1 on UNIX.
At times the database shows extremely poor performance.
I do not have dba/admin rights nor do I have the web based client for
db2 v8.1.
I have only command line access.
Also DBA support starts after our jobs have completed.
(1) Is there any command that I could use from command line to find
out the process taking up maximum of the database resources ?
(2) Can the database snapshot be used for this purpose ?
(3) Is there any log created by DB2 which could be used for finding
the process consuming database resources ?

I would appreciate any help in this direction.
Thanks in advance !
Back to top
Google

Back to top
Display posts from previous:   
Post new topic   Reply to topic Page 1 of 1 [4 Posts] View previous topic :: View next topic
The time now is Thu Jan 08, 2009 3:04 am | All times are GMT
navigation Forum index » Databases » IBM DB2
Jump to:  

Similar Topics
Topic Author Forum Replies Last Post
No new posts Move Oracle 10g database to another location Selt Server 0 Fri Jul 21, 2006 2:14 pm
No new posts database Share Memory Limit (2 GB ) in a Instance is tota... sadanjan@gmail.com IBM DB2 0 Fri Jul 21, 2006 12:57 pm
No new posts Performance and Consistency ?? likun.navipal@gmail.com Berkeley DB 4 Fri Jul 21, 2006 4:24 am
No new posts AIX performance tuning jpzhai@gmail.com AIX 5 Fri Jul 21, 2006 2:27 am
No new posts A webserver (PHP 5) with a few database server (MySQL) ¥|¥J PHP 2 Fri Jul 21, 2006 1:43 am

Credit Cards UK | NFL Talk Football Forums | Buy WoW Gold | Internet Advertising | Looking for Credit Cards?
Copyright © 2004-2005 DeniX Solutions SRL
 
Other DeniX Solutions sites: Unix/Linux blog |  electronics forum |  medicine forum |  science forum | 
Privacy Policy


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.2238s ][ Queries: 20 (0.1391s) ][ GZIP on - Debug on ]