Skip to content
March 2, 2012 / Shivananda Rao P

Enabling Flashback Database in Oracle

Oracle Flashback Database, allows to quickly recover the entire database from logical data corruptions or user errors. It is very similar to PITR (Point In Time Recovery) which puts back the database to a state at a particular time in recent past. However, Flashback Database is much faster than PITR as it does not require restoration of datafiles from the backup. It only requires applying fewer changes from the archived redo logs.

Flashback database can be enabled by following the below steps but before that you need to make sure of the 2 things: Your database needs to be in archivelog mode and you must have FRA(flash recovery area) for your database because the Flashback logs can be stored only in FRA.

Steps to enable Flashback Database:

1. Place your database in mount stage.

  • sql>shutdown immediate
  • sql>startup mount

2. Set DB_FLASHBACK_RETENTION_TARGET to the requried minutes to have the flashback window. By default, the value would be 1440 minutes (1 day)

  • sql>alter system set db_flashback_retention_target=7220; #Here I have set it to 5 days

3. Enable Flashback on the database

  • sql>alter database flashback on;

4. You can skip enabling flashback at tablespaces level as shown below

  • sql>alter tablespace users flashback off;

5. Finally open the database

  • sql>alter database open;

6. You can check if the database is enabled with Flashback or not

  • sql>select flashback_on from v$database;




Here you go !!!



© Shivananda Rao P, 2012 to 2018. Unauthorized use and/or duplication of this material without express and written permission from this blog’s author and/or owner is strictly prohibited. Excerpts and links may be used, provided that full and clear credit is given to Shivananda Rao and with appropriate and specific direction to the original content.


The views expressed here are my own and do not necessarily reflect the views of any other individual, business entity, or organization. The views expressed by visitors on this blog are theirs solely and may not reflect mine.


One Comment

Leave a Comment
  1. son mai / Nov 7 2013 2:45 am

    thank you so much, i’m new to oracle and have to set up a failover database, your postes is my saviour :-*

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: