如何使用NBU 做Oracle 重定向恢复
(2011-03-17 10:13:39)
标签:
it
Problem如何使用NBU 做Oracle 重定向恢复?
SolutionNetbackup for oracle 重定向恢复
1. 备份原数据库
a. 备份数据库
Run{
Allocate channel c1 type ‘sbt_tape’;
Backup
Format ‘dbbk_%s_%p_%t’
Database;
Sql ‘alter database system archive log current’;
Release channel c1;
}
b. 备份归档日志
run {
allocate channel c1 type ‘sbt_tape’;
backup
format ‘arbk_%s_%p_%t’
archive log all;
release channel c1;
}
c. 备份控制文件
run {
allocate channel c1 type ‘sbt_tape’;
backup
format ‘mancntl_%s_%p’
current controlfile;
release channel c1;
}
2.重定向恢复
d. 在master 创建 No.Restrictions file(
install_path\NetBackup\db\altnames\No.Restrictions)
e. 重新安装一台新的oracle 服务器Oracle & OS 版本与原机器一致。
f. 在新的Oracle 服务器上
创建密码orapwd file=path\pwdsid.ora password=
(或COPY 原密码文件到目标机器)
g. 创建相同SID 的数据库 ,文件路径与要恢复的机器一致
h. 记录下原DBID 可以从备份的RMAN 输出中查到,或问DBA
i. Copy 原pfile 到新的机器上
Sql>create pfile =’/$PATH/pfile’ from
spfile=’/$PATH/spfile’
可以在原机上产生pfile
j. 启动到nomount 状态
k. set DBID =原机DBID
l. 恢复controlfile
RMAN> run {
2> allocate channel c1 type 'sbt_tape';
3> SEND
'NB_ORA_SERV=nbu-master,NB_ORA_CLIENT=oracle10';
4> restore controlfile from 'mancntl_116_1';
5> release channel c1;
6> }
m. 恢复数据库
n. 修复数据库
RMAN> run {
2> allocate channel c1 type 'sbt_tape';
3> SEND
'NB_ORA_SERV=nbu-master,NB_ORA_CLIENT=oracle10';
5> restore database;
6> recover database;
7> release channel c1;
8> }
o. 打开数据库
RMAN> alter database open resetlogs;
database opened
p. 恢复完成
分享:
喜欢
0
赠金笔
加载中,请稍候......
评论加载中,请稍候...
发评论
登录名: 密码: 找回密码 注册记住登录状态
昵 称:
评论并转载此博文
发评论
以上网友发言只代表其个人观点,不代表新浪网的观点或立场。