CREATE RESTORE POINT before_upgrade;
CREATE RESTORE POINT before_upgrade GUARANTEE FLASHBACK DATABASE;

LIST RESTORE POINT restore_point_name;
LIST RESTORE POINT ALL;

SELECT NAME, SCN, TIME, DATABASE_INCARNATION#, GUARANTEE_FLASHBACK_DATABASE,STORAGE_SIZE FROM V$RESTORE_POINT;

DROP RESTORE POINT before_app_upgrade;

ALTER SYSTEM SET DB_FLASHBACK_RETENTION_TARGET=4320; # 3 days

ALTER DATABASE FLASHBACK ON;

ALTER TABLESPACE tbs_3 FLASHBACK OFF;

if flashback buf free by RVWR is the top wait event, then you know that Oracle Database cannot write flashback logs very quickly.

The V$FLASHBACK_DATABASE_STAT view shows the bytes of flashback data logged by the database. Each row in the view shows the statistics accumulated (typically over the course of an hour). The FLASHBACK_DATA and REDO_DATA columns describe bytes of flashback data and redo data written respectively during the time interval, while the DB_DATA column describes bytes of data blocks read and written. The columns FLASHBACK_DATA and REDO_DATA correspond to sequential writes, whereas DB_DATA column corresponds to random reads and writes.

 

Because of the difference between sequential I/O and random I/O, a better indication of I/O overhead is the number of I/O operations issued for flashback logs. The V$SYSSTAT statistics shown can tell you the number of I/O operations that your instance has issued for various purposes.

Physical write I/O request The number of write operations issued for writing data blocks
Physical read I/O request  The number of read operations issued for reading data blocks
Redo writes                     The number of write operations issued for writing to the redo log
Flashback log writes         The number of write operations issued for writing to flashback logs
Flashback log write bytes  Total size in bytes of flashback database data written from this instance

When flashback is enabled or when there are guaranteed restore points, the background process RVWR writes flashback data to flashback database logs in the fast recovery area.

If RVWR encounters an I/O error, then the following behavior is expected:

■If there are any guaranteed restore points defined, then the instance fails when RVWR encounters I/O errors.

■If no guaranteed restore points are defined, then the instance remains unaffected when RVWR encounters I/O errors. Note the following; On a primary database, Oracle Database automatically disables Flashback Database while the database is open. All existing transactions and queries proceed unaffected. This behavior is expected for both single-instance and Oracle RAC databases.