nbu 恢复 oracle 控制文件 报错
各位好!小弟在测试环境恢复oracle控制文件遇到些问题,情况是这样的:
1.在一部win2003 server 上安装nbu server,备份介质为磁盘空间;
2.aix 5.3安装oracle 10g。
备份oracle 10g成功,包括控制文件。不过没有将controlfile设为autobackup到磁盘,现在想从nbu备份介质中恢复。
在网上找了些资料:
3.1.bplist查看备份:
# ./bplist -C aix -S win2003 -t 4 -R /
EXIT STATUS 25: cannot connect on socket
# ping win2003
0821-062 ping: host name win2003 NOT FOUND
# ./bplist -C aix -S su182 -t 4 -R /
/c-1240301407-20100304-06
/ctrl_u1ol7o75m_s56_p1_t712776886
/c-1240301407-20100304-05
/arch_u1ml7o716_s54_p1_t712776742
/c-1240301407-20100304-04
/bk_u1kl7o6ps_s52_p1_t712776508
/c-1240301407-20100304-03
/ctrl_u1il7o36f_s50_p1_t712772815
/c-1240301407-20100304-02
/arch_u1fl7o2kk_s47_p1_t712772244
/c-1240301407-20100304-01
/ctrl_u1dl7o2er_s45_p1_t712772059
/c-1240301407-20100304-00
/bk_u1bl7o1mp_s43_p1_t712771289
/c-1240301407-20100303-05
/bk_u18l7ll7s_s40_p1_t712692988
/c-1240301407-20100303-04
/14l7lk4m_1_1
/13l7lk4d_1_1
/c-1240301407-20100303-03
/11l7ljt7_1_1
/c-1240301407-20100303-02
/0tl7lj86_1_1
/c-1240301407-20100303-01
/0rl7lip8_1_1
/c-1240301407-20100303-00
/0pl7liev_1_1
/c-1240301407-20100302-05
/bk_u0kl7j0o0_s20_p1_t712606464
/c-1240301407-20100302-04
/bk_u0hl7j00b_s17_p1_t712605707
/c-1240301407-20100302-03
/cntrl_15_1_712605367
/c-1240301407-20100302-02
/al_13_1_712605248
/al_12_1_712605202
/al_11_1_712605202
/c-1240301407-20100302-01
/bk_8_1_712604973
/bk_9_1_712604973
/c-1240301407-20100302-00
/bk_u04l7iudo_s4_p1_t712604088
3.2.恢复控制文件:
QL> startup nomount
ORACLE instance started.
Total System Global Area 612368384 bytes
Fixed Size 2022800 bytes
Variable Size 230687344 bytes
Database Buffers 373293056 bytes
Redo Buffers 6365184 bytes
SQL> declare
2 devtype varchar2(256);
3 done boolean;
4 begin
5 devtype:=dbms_backup_restore.deviceallocate('sbt_tape',params=>'');
6 dbms_backup_restore.restoresetdatafile;
7 dbms_backup_restore.restorecontrolfileto('/home/oracle/abc.cf');
8 dbms_backup_restore.restorebackuppiece('c-1240301407-20100304-06',done=>done
9 );
10 end;
11 /
declare
*
ERROR at line 1:
ORA-19624: operation failed, retry possible
ORA-19870: error reading backup piece c-1240301407-20100304-06
ORA-19507: failed to retrieve sequential file,
handle="c-1240301407-20100304-06", parms=""
ORA-27029: skgfrtrv: sbtrestore returned error
ORA-19511: Error received from media manager layer, error text:
Failed to open backup file for restore.
ORA-06512: at "SYS.X$DBMS_BACKUP_RESTORE", line 5149
ORA-06512: at line 8
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(8)
本帖最后由 zhangmq 于 2010-10-18 15:21 编辑
回复 3# 赵大少爷
你好,数据库在nomount模式恢复报错:
RMAN> run {
2> allocate channel t1 type 'sbt_tape';
3> send 'NB_ORA_CLIENT=aix';
4> send 'NB_ORA_SERV=su182';
5> restore controlfile from '/ctrl_u1ol7o75m_s56_p1_t712776886';
6> release channel t1;
7> }
allocated channel: t1
channel t1: sid=157 devtype=SBT_TAPE
channel t1: Veritas NetBackup for Oracle - Release 6.5 (2007072323)
sent command to channel: t1
sent command to channel: t1
Starting restore at 08-MAR-10
channel t1: restoring control file
released channel: t1
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of restore command at 03/08/2010 15:15:57
ORA-19870: error reading backup piece /ctrl_u1ol7o75m_s56_p1_t712776886
ORA-19507: failed to retrieve sequential file, handle="/ctrl_u1ol7o75m_s56_p1_t712776886", parms=""
ORA-27029: skgfrtrv: sbtrestore returned error
ORA-19511: Error received from media manager layer, error text:
Failed to open backup file for restore.
RMAN>
备份服务器activity monitor报错见附件,错误代码37
很奇怪,为什么在备份服务器显示客户端为主机“localhost,是不是问题关键?
这一句restore controlfile from '/ctrl_u1ol7o75m_s56_p1_t712776886';
去掉" /"
改成restore controlfile from 'ctrl_u1ol7o75m_s56_p1_t712776886';
这种回复方式不需set DBID
/etc/hosts编辑正确吗?
回复 4# 赵大少爷
是的。
/c-*
这些都应该是aotubanckup的controlfile吧
RMAN> run {
allocate channel t1 type 'sbt_tape';
send 'NB_ORA_CLIENT=client_name';
send 'NB_ORA_SERV=veritas_server';
restore controlfile from ‘/ctrl_u1ol7o75m_s56_p1_t712776886‘;
release channel t1;
}
另外,我在另一个环境测试。用一部windows 2003虚拟机安装oracle 10g ,安装nbu,用同样的方式备份后恢复是成功的,是不是跟系统差异有关。有在备份服务器C:Program FilesVERITASNetBackupdbaltnames创建No.Restrictions。