Connecting Tech Pros Worldwide Forums | Help | Site Map

How to calculate size of partition in DB2

Newbie
 
Join Date: Oct 2009
Posts: 1
#1: Oct 16 '09
Hi,

I need to find out the the total size of a partition and how much of it has been utilized.

How to calculate the percentage of utilization of a partition in DB2 of Z/OS.

Thanks

Newbie
 
Join Date: Oct 2009
Posts: 5
#2: 4 Weeks Ago

re: How to calculate size of partition in DB2


Hi,

DB2 LUW has the get_dbsize_info(?, ?, ?, 0) stored procedure to calculate the size of the databases. I'm not sure if this procedure is available in z/OS, but you may want to verify this.

Also this general approach may be useful.

use db2_all command (not sure its available in z/OS!) to list the table space container info for the database in question.

db2_all "list tablespace containers for <tablespacenum> show detail"

This will dump out

1. the path to the containers (in case of SMS tablespaces it will be a directory for DMS it will be a file or raw device).
2. Total number of pages used
3. Total number of useable pages.

Under Unix the size of the file in (1.) can be measured using the du command. I'm guessing Z/OS has a similar utility/command?
Reply


Similar DB2 Database bytes