Calculating the Space Requirements For Undo Retention
Given a specific UNDO_RETENTION
parameter setting and some system statistics, the amount of undo space required to satisfy the undo retention requirement can be estimated using the following formula:
UndoSpace = UR * UPS + overhead
where:
- UndoSpace is the number of undo blocks
- UR is
UNDO_RETENTION
in seconds - UPS is undo blocks for each second
- overhead is the small overhead for metadata (transaction tables, bitmaps, and so forth)
As an example, if UNDO_RETENTION
is set to 2 hours, and the transaction rate (UPS) is 200 undo blocks for each second, with a 4K block size, the required undo space is computed as follows:
(2 * 3600 * 200 * 4K) = 5.8GBs.
Such computation can be performed by using information in the V$UNDOSTAT
view. In the steady state, you can query the view to obtain the transaction rate. The overhead figure can also be obtained from the view.
V$UNDOSTAT
V$UNDOSTAT
displays a histogram of statistical data to show how well the system is working. The available statistics include undo space consumption, transaction concurrency, and length of queries executed in the instance. You can use this view to estimate the amount of undo space required for the current workload. Oracle uses this view to tune undo usage in the system. This view is available in both automatic undo management mode and manual undo management mode.
Each row in the view keeps statistics collected in the instance for a 10-minute interval. The rows are in descending order by the BEGIN_TIME
column value. Each row belongs to the time interval marked by (BEGIN_TIME
, END_TIME
). Each column represents the data collected for the particular statistic in that time interval. The first row of the view contains statistics for the (partial) current time period. The view contains a total of 1008 rows, spanning a 7 day cycle.
Extraído de los manuales oficiales de Oracle 9i r2. También se puede obtener más información en la nota ID 460481.1 de metalink.
No hay comentarios:
Publicar un comentario