- 最后登录
- 2023-8-16
- 在线时间
- 1686 小时
- 威望
- 2135
- 金钱
- 50532
- 注册时间
- 2011-10-12
- 阅读权限
- 200
- 帖子
- 5207
- 精华
- 39
- 积分
- 2135
- UID
- 2
|
3#
发表于 2013-10-24 15:59:15
ODM FINDING:
ODM FINDING:
Switchover the primary to a standby database
SQL> ALTER DATABASE COMMIT TO SWITCHOVER TO STANDBY WITH SESSION SHUTDOWN;
If an ORA-16139 is encountered, as long as V$DATABASE.DATABASE_ROLE=’PHYSICAL STANDBY’, then you can proceed. A common case where this can occur is when there are a large number of data files, greater than 1,000, the apply of the EOR log will timeout.. Once managed recovery is started on the new standby it will recover.
If the role was not changed then you need to cancel the switchover and review the alert logs and trace files further.
Data Guard Physical Standby Database Setup
A Switchover was executed making the original Primary Database the new Standby
For some Reason the new Primary is rendered unusable before there was any Activity, i.e. before any new Redo was generated and shipped to the new Standby
Trying to reinstate the original Primary Database (now in Standby Mode) using the Command 'ALTER DATABASE COMMIT TO SWITCHOVER TO PRIMARY;' fails with Error:
ORA-16139 media recovery required
Changes
Switchover to Standby.
Cause
The Command used
ALTER DATABASE COMMIT TO SWITCHOVER TO PRIMARY;
is incorrect in this Scenario (Failover) as it must have been preceded by a
ALTER DATABASE RECOVER MANAGED STANDBY DATABASE FINISH FORCE;
Since the standby database never received and applied any Redo the above RECOVER Command was never executed and hence the COMMIT TO SWITCHOVER failed with ORA-16139.
Solution
1. To change the Database Role from 'physical standby' to 'primary' simply use:
ALTER DATABASE ACTIVATE STANDBY DATABASE;
2. Followed by
ALTER DATABASE OPEN;
3. Rebuild the Standby Database from a new Backup created after the Failover |
|