Hi, I want to know if any of you run a script at regular bases to monitor the growth rate of database(s). If you do so, what kind of script do you use and how often do you run?
If you want to monitor the growth of the extents on daily basis, you can run the following script:
---------------------------------------------------------------------
select owner schema,
segment_name table_name,
segment_type table_type,
extents Used_ext,
max_extents
from dba_segments
where segment_type in ('TABLE', 'INDEX', 'ROLLBACK')
and max_extents - extents < 11
--------------------------------------------------------------------
In the above script you can find the schema, which is nearing to maxextent, So you have to increase the Maxextents.
To increase the Maxextents, you can run the following script:
Assume: ext_used:63, Max_extent 70
--------------------------------------------------------------
ALTER . STORAGE (MAXEXTENTS 80)
---------------------------------------------------------------
To increase the Maxextents, you can run the following script:
Assume: ext_used:63, Max_extent 70
--------------------------------------------------------------
ALTER segmenttype schema.tablename
STORAGE (MAXEXTENTS 80)
---------------------------------------------------------------
Bookmarks