Home
Blog
About
Database administration
Operating systems
Development
Links


Following require login:
ScratchPad



Locations of visitors to this page


Monitor and troubleshoot DB2

Table usage statistics

Database partition uptime

Returns the state and uptime of all database partitions.

$ db2pd - -alldbpartitionnums

Database Partition 0 -- Active -- Up 57 days 03:58:06 -- Date 06/14/2011 07:27:57

Database uptime

Return database status and uptime for local partition …

$ db2pd - -alldbs

Database Partition 0 -- Database ED1 -- Active -- Up 3 days 06:48:00 -- Date 06/14/2011 07:35:54

… on all partitions …

$ db2pd - -alldbs -alldbpartitionnums

Database Partition 0 -- Database ED1 -- Active -- Up 3 days 06:50:44 -- Date 06/14/2011 07:38:38

… or a specific database …

$ db2pd - -db ED1

Database Partition 0 -- Database ED1 -- Active -- Up 3 days 06:49:47 -- Date 06/14/2011 07:37:41

Database manager configuration

$ db2pd -dbmcfg

Database Partition 0 -- Database ED1 -- Active -- Up 3 days 06:34:54 -- Date 06/14/2011 07:22:48

Database Manager Configuration Settings:
Description                    Memory Value                 Disk Value
RELEASE                        0xd00                        0xd00
CPUSPEED(millisec/instruction) 1.417033e-07                 1.417033e-07
COMM_BANDWIDTH(MB/sec)         1.000000e+02                 1.000000e+02
NUMDB                          8                            8
FEDERATED                      NO                           NO
...

Database configuration

$ db2pd -db ED1 -dbcfg

Database Partition 0 -- Database ED1 -- Active -- Up 3 days 06:35:24 -- Date 06/14/2011 07:23:18

Database Configuration Settings:
Description                    Memory Value         Disk Value
DB configuration release level 0xd00                0xd00
Database release level         0xd00                0xd00
Database territory             en_US                en_US
Database code page             1208                 1208
Database code set              UTF-8                UTF-8
Database country/region code   1                    1
...

Which is the equivalent of running:

$ db2 get db cfg for ED1

       Database Configuration for Database ED1

 Database configuration release level                    = 0x0d00
 Database release level                                  = 0x0d00

Copyright HandyDBA 2012