Steps to flashback the primary and stanby database to a point in time.
Disable dataguard configuration
dgmgrl
show configuration – check no errors before starting this
disable FAST_START FAILOVER;
DISABLE CONFIGURATION;
Primary
srvctl stop database -d PTEST1
srvctl start database -d PTEST1 -o mount
SQL>flashback database to timestamp to_timestamp(‘2011-02-17 14:00:00’, ‘YYYY-MM-DD HH24:MI:SS’) or restore point
SQL>alter database open resetlogs;
SQL>select resetlogs_change# from v$database;
srvctl start service -s TEST -d PTEST1
Standby
srvctl stop database -d FTEST1
srvctl start database -d FTEST1 -o mount
flashback database to scn <above-2>
Enable dataguard configuration
dgmgrl
ENABLE CONFIGURATION;
ENABLE FAST_START FAILOVER;
show configuration – check no errors