so**********@yahoo.com (David McGeorge) wrote in message news:<bc**************************@posting.google. com>...
what's the main scripts and ritual actions besides checking backup,
and db2diag.log you do everyday to manage your DB2 environment on
Solaris or AIX ?
How can check connections, load, tablespaces, catalogs, hit ratios?
The answer depends on whether or not you are running DB2 UDB V8. The
V8 release featured several SQL table functions that report on all
manner of database activity. Those V8 functions, called snapshot UDFs,
are documented here:
http://publib.boulder.ibm.com/infoce...n/r0006117.htm
Because of those snapshot UDFs, many of my scripts simply run a single
SQL statement (against the catalog or some snapshot UDFs) to provide
the desired information.
Here's what some of them do:
- Calculate the amount of remaining space in each DMS tablespace
- Sort the list of currently connected applications by ascending idle
time
- Output all of the files, directories, and raw device handles used by
tablespaces in a specific database
- Calculate the estimated completion time of an inplace reorg or a DMS
rebalance
- Calculate bufferpool hit ratios
- Identify SQL procedures whose bound access plans are more than X
days older than the newest statistics for any of the involved tables
Other scripts have been written in UNIX shell or Perl:
- Delete all log files more than X days older than the first active
log file
- Take an online backup and only delete previous backup if new backup
was successful
- Generate a script to perform RUNSTATS on every table in a database
- Create a database, convert it to retain logs, and set several common
configuration parameters
There are others I am forgetting, but I hope that gives you an idea.
Good Luck,
Fred