【Vegas原创】用RMAN进行在线DG Rebuild(Windows版)
例:DG损坏,需要重新建立
前提:DG已经有build。build DG的方法:http://www.cnblogs.com/vegaslee/archive/2009/08/11/1543716.html
步骤:
DB:
1,运行RMAN备份脚本,获取最新的RMAN备份集,并将备份集copy到DG中:
参见:http://www.cnblogs.com/vegaslee/archive/2009/08/11/1543660.html
2,运行以下sql,并将生成的control文件copy到DG中:
DG:
1,关闭DG,并rename mesdb_stby.ctl to control01.ctl,control02.ctl,control03.ctl;
2, 还原DG:
3,开启DG:
DB:
查APPLED:
前提:DG已经有build。build DG的方法:http://www.cnblogs.com/vegaslee/archive/2009/08/11/1543716.html
步骤:
DB:
1,运行RMAN备份脚本,获取最新的RMAN备份集,并将备份集copy到DG中:
参见:http://www.cnblogs.com/vegaslee/archive/2009/08/11/1543660.html
2,运行以下sql,并将生成的control文件copy到DG中:
SQL> alter database create standby controlfile as 'e:\mesdb_stby.ctl';
DG:
1,关闭DG,并rename mesdb_stby.ctl to control01.ctl,control02.ctl,control03.ctl;
SQL> shutdown database
2, 还原DG:
SQL> startup mount;
RMAN > restore database;
3,开启DG:
SQL> shutdown immediate;
SQL> startup nomount;
SQL> alter database mount standby database;
SQL> alter database recovery managed standby database disconnect from session;
DB:
查APPLED:
SQL> select * from v$archived_log where first_time>to_date('2009-09-13 16:30:00','yyyy-mm-dd hh24:mi:ss')
order by completion_time desc
order by completion_time desc
喜欢请赞赏一下啦^_^