Page 529
Using the Space Manager MenuSpace Manager is invoked by typing spc_mgr.u from the command line. This will display the main menu with the thirteen options. A brief description of what each option means and how to use them is given next.
1. Build Repository
Use this option to build the repository of the Space Manager.
2. Capture Space Statistics
Use this option to capture the space statistics. It is normally run at the end of the day or any other suitable interval which the user thinks is an accurate time interval over which space statistics have to be captured.
3. Tablespace Free Space Drop Trends
Use this option to report the space used by tablespaces between two space snapshots. Refer to Figure 21.12 for the output. You can use this option to find out the fall in space in a tablespace during a specified interval and then use Option 4 (Report Object Growth Rate) to pinpoint which object in the tablespace has actually used this space.
4. Report Object Growth Rate
Use this option to report the object growth rate. It prompts you for the Start and End Space IDs over which the growth rate has to be reported. Refer to Figure 21.13 for sample output. When used in conjunction with Option 3, this can be very useful.
5. Report Tablespace Space Usage
Use this option to report the allocated and used space for every tablespace in the database. Refer to Figure 21.11 for details.
6. Report Object Space Usage
Use this option to report the space used by every object in the database. It uses the latest captured snapshot to report this.
7. Extents Greater than Specified
This option uses the latest captured Space Snapshot information to report. It prompts the user for the number of extents required and then reports all the objects in the database whose current number of extents of the object is greater than specified.
8. Percentage of Extents Greater than Specified
This option uses the latest captured Space Snapshot information to report. It prompts the user for the percentage of extents to be reported and then reports on all the objects in the database whose number of extents as a percentage of the maximum extents in the database is greater than the percentage specified.
Page 530
9. Space Warnings
This option will not use any repository data to report. It uses the system tables to report objects having next extent parameters greater than the maxextent size in the tablespace. The possible actions to be taken if this report shows any such objects are to:
10. Tablespace Predictor
Use this option to obtain the predictions as to when the tablespace will become full. As usual, this prompts you for the Start and the End Space IDs, which are the snapshot IDs of the statistics captured over different times. The prediction is made using these.
11. Drop the Repository
This option performs the cleanup if for some reason the current repository has to be dropped. It drops all the repository objects. Be very careful when using this option, as all historical information captured will be wiped out.
12. Purge a Snapshot
This option can be used to delete individual captured snapshots. It performs a cascade delete and deletes from all tables that have the particular snapshot information.
13. View the Generated Reports
Most of the previous options generate an output file that is stored in the same directory as the software. Use this option to view all reports generated by Space Manager without exiting Space Manager.
Almost all the previous options revolve around the concept of space id. Each option will ask for a start space id and an end space id or just a space id. Using the various previous options and the statistics captured during various intervals (defined by start space id and end space id), it becomes easy for the DBA to point out space abnormalities that have occurred in the past and that are otherwise impossible to track back.l