alter database commit to switchover to physical standby;
2.备份切换成primary,启动到open
select OPEN_MODE, DATABASE_ROLE, SWITCHOVER_STATUS, FORCE_LOGGING, DATAGUARD_BROKER, GUARD_STATUS from v$database;
alter database commit to switchover to primary;
3.新的备份执行日志应用
alter database recover managed standby database using current logfile disconnect from session;
3.2 Data Guard Broker 快速switchover
SQL> show parameter dg_broker_start
?NAME? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? TYPE? ? ? ? VALUE
------------------------------------ ----------- ------------------------------
dg_broker_start? ? ? ? ? ? ? ? ? ? ? boolean? ? FALSE
SQL> alter system set dg_broker_start = true;
?System altered.
?SQL> show parameter dg_broker_start
?NAME? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? TYPE? ? ? ? VALUE
------------------------------------ ----------- ------------------------------
dg_broker_start? ? ? ? ? ? ? ? ? ? ? boolean? ? TRUE
配置dgmgrl
create CONFIGURATION jydb as primary database is jyzhao CONNECT IDENTIFIER IS jyzhao;
add database? jyzhao_s as CONNECT IDENTIFIER IS jyzhao_s MAINTAINED AS? PHYSICAL;
enable configuration;
show configuration;
switchover to jyzhao_s;
switchover to jyzhao;
show database verbose jydb