今日更新
技术新闻
精彩专题
IBM软件技术专区
微软开发专区
技术文档中心
编程语言
网络通信
网络安全
LINUX/UNIX
软件工程与管理
数据库开发
WEB开发
企业应用与开发
移动开发
资源中心
原创专栏
开放系统世界
人才与培训
技术天地论坛
厂商列表
社区推荐

· 女性身体内部人体受孕..
· 十部顶级的变态与情色..
· 感情放纵让我毁了两个..
· 当我撞见姐姐和男友在..
· 卖淫少女惨遭泄愤民工..
· 偷拍街上的走光mm绝对..
· 百度打击google的广告
· 港娱乐圈与黑社会揭秘
赛迪网>>技术应用>>教程和案例
关键字: Rman
来  源: 赛迪网
Oracle Rman/tivoli-TDP/下数据恢复到节点
作者:中铝广西分公司信息部 陈虹 发文时间:2003.07.18
AIX平台:4.3.3

Oracle版本: 8.0.5

从节点RS/6000 h50b备份的数据现恢复到节点43p-db。



43p-db:

一、把43p-db的tdpo_node文件的TDPO_NODE改为 h50b的node name

# vi /usr/tivoli/tsm/client/oracle/bin/tdpo.opt
TDPO_NODE               tdp_h50b
# cd /usr/tivoli/tsm/client/oracle/bin/
# tdpoconf password 
************************************************************
*       Tivoli Data Protection for Oracle Utility           *
*  Password file initialization/update program              *
*     ROOT privilege needed to update value                 *
*************************************************************
Please enter current password:
Please enter new password:
Please reenter new password for verification:
ANU0260I Password successfully changed.


二、Copy h50B的configora8_sb.ora initora8_sb.ora和口令文件到43p-db相应目录。所有相应的目录都要预先创建好。

三、43p-db的oracle为Startup nomount状态。

在H50b:
  恢复控制文件
$ export ORACLE_SID=ora8_sb
$ rman target system/passwd1@43p-db rcvcat rman/rman@forjy
Recovery Manager: Release 8.0.5.2.1 - Production

RMAN-06006: connected to target database: ora8_sb (not mounted)
RMAN-06008: connected to recovery catalog database
RMAN> run {
 allocate channel t1 type 'sbt_tape' parms
 'ENV=(TDPO_OPTFILE=/usr/tivoli/tsm/client/oracle/bin/tdpo.opt)'; 
 restore controlfile to '/sbfs/ctl01sb.ctl'; 
 release channel t1; 
 allocate channel d1 type disk; 
 replicate controlfile from '/sbfs/ctl01sb.ctl';
 sql 'alter database mount'; 
 release channel d1; 
}
RMAN-03022: compiling command: allocate
RMAN-03023: executing command: allocate
RMAN-08030: allocated channel: t1
RMAN-08500: channel t1: sid=12 devtype=SBT_TAPE
RMAN-03022: compiling command: restore
RMAN-03022: compiling command: IRESTORE
RMAN-03023: executing command: IRESTORE
RMAN-08016: channel t1: starting datafile backupset restore
RMAN-08502: set_count=0 set_stamp=0
RMAN-08021: channel t1: restoring controlfile
RMAN-08505: output filename=/sbfs/ctl01sb.ctl
RMAN-08023: channel t1: restored backup piece 1
RMAN-08511: piece handle=ORA8_SB_full_497711454_17_1 params=NULL
RMAN-08024: channel t1: restore complete
RMAN-03022: compiling command: release
RMAN-03023: executing command: release
RMAN-08031: released channel: t1
RMAN-03022: compiling command: allocate
RMAN-03023: executing command: allocate
RMAN-08030: allocated channel: d1
RMAN-08500: channel d1: sid=12 devtype=DISK
RMAN-03022: compiling command: replicate
RMAN-03023: executing command: replicate
RMAN-08058: replicating controlfile
RMAN-08506: input filename=/sbfs/ctl01sb.ctl
RMAN-08505: output filename=/sbfs/sbdata1/ctl02sb.ctl
RMAN-08505: output filename=/sbfs/sbdata2/ctl03sb.ctl
RMAN-03022: compiling command: sql
RMAN-06162: sql statement: alter database mount
RMAN-03023: executing command: sql
RMAN-03022: compiling command: release
RMAN-03023: executing command: release
RMAN-08031: released channel: d1
RMAN>exit
Recovery Manager complete.


四、获取最近ARCHIVED REDO LOGS线程中最小的SCN号,进行不完全恢复。

在h50b上
SQL> SELECT min(scn) FROM (SELECT max(next_change#) scn
FROM v$archived_log GROUP BY thread#);
  MIN(SCN)
----------
  99561745


五、恢复数据文件

$  rman target system/passwd1@43p-db rcvcat rman/rman@forjy
Recovery Manager: Release 8.0.5.2.1 - Production
RMAN-06005: connected to target database: ORA8_SB
RMAN-06008: connected to recovery catalog database
RMAN> run {
set until scn= 99561745;
allocate channel t1 type 'sbt_tape' parms
'ENV=(TDPO_OPTFILE=/usr/tivoli/tsm/client/oracle/bin/tdpo.opt)';
restore database;
recover database;
release channel t1;
sql "alter database open resetlogs";
}
RMAN-03022: compiling command: set
RMAN-03022: compiling command: allocate
RMAN-03023: executing command: allocate
RMAN-08030: allocated channel: t1
RMAN-08500: channel t1: sid=10 devtype=SBT_TAPE
RMAN-03022: compiling command: restore
RMAN-03022: compiling command: IRESTORE
RMAN-03023: executing command: IRESTORE
RMAN-08016: channel t1: starting datafile backupset restore
RMAN-08502: set_count=17 set_stamp=497711454
RMAN-08019: channel t1: restoring datafile 1
RMAN-08509: destination for restore of datafile 1:
  /sbfs/system01sb.dbf
RMAN-08019: channel t1: restoring datafile 2
RMAN-08509: destination for restore of datafile 2:
  /sbfs/rbs01sb.dbf
RMAN-08019: channel t1: restoring datafile 3
RMAN-08509: destination for restore of datafile 3:
  /sbfs/temp01sb.dbf
RMAN-08019: channel t1: restoring datafile 4
RMAN-08509: destination for restore of datafile 4:
  /sbfs/tools01sb.dbf
RMAN-08019: channel t1: restoring datafile 5
RMAN-08509: destination for restore of datafile 5:
  /sbfs/users01sb.dbf
RMAN-08019: channel t1: restoring datafile 6
RMAN-08509: destination for restore of datafile 6:
  /sbfs/sb01.dbf
RMAN-08019: channel t1: restoring datafile 7
RMAN-08509: destination for restore of datafile 7:
  /sbfs/isb01.dbf
RMAN-08019: channel t1: restoring datafile 8
RMAN-08509: destination for restore of datafile 8:
  /sbfs/rman/rman_sc.dbf
RMAN-08023: channel t1: restored backup piece 1
RMAN-08511: piece handle=ORA8_SB_full_497711454_17_1 params=NULL
RMAN-08024: channel t1: restore complete
RMAN-03023: executing command: partial resync
RMAN-08003: starting partial resync of recovery catalog
RMAN-08005: partial resync complete
RMAN-03022: compiling command: recover
RMAN-03022: compiling command: recover(1)
RMAN-03023: executing command: partial resync
RMAN-03022: compiling command: recover(2)
RMAN-03022: compiling command: recover(3)
RMAN-03023: executing command: recover(3)
RMAN-08054: starting media recovery
RMAN-08060: unable to find archivelog
RMAN-08510: archivelog thread=1 sequence=12
RMAN-03022: compiling command: recover(4)
RMAN-03023: executing command: recover(4)
RMAN-08017: 
  channel t1: starting archivelog restore to default destination
RMAN-08022: channel t1: restoring archivelog
RMAN-08510: archivelog thread=1 sequence=12
RMAN-08023: channel t1: restored backup piece 1
RMAN-08511: piece handle=ORA8_SB_arch_497711757_18_1 params=NULL
RMAN-08024: channel t1: restore complete
RMAN-08515: archivelog 
  filename=/user/oracle/app/oracle/product/8.0.5/dbs/arch1_12.dbf 
  thread=1 sequence=12
RMAN-08055: media recovery complete
RMAN-03022: compiling command: release
RMAN-03023: executing command: release
RMAN-08031: released channel: t1
RMAN-03022: compiling command: sql
RMAN-06162: sql statement: alter database open resetlogs
RMAN-03023: executing command: sql
RMAN>


(责任编辑:西门吹风




赛迪网推出“IT博客”,花不到一分钟就完成注册
评论】 【推荐】 【 】 【打印】 【关闭

·Linux专区· ·黑客攻防·
· Linux下添加硬盘、分区、格式化任务详解
· FreeBSD服务器的安装与优化之优化篇
· 初学者入门:FreeBSD服务器的安装与优化
· 金企鹅杯两岸四地开源软件大赛圆满结束
· 如何提高Linux系统安全性的十大招数
· 构筑Linux防火墙之为个人用户设置防火墙
· 谁更安全?黑客眼中的防火墙与路由器
· 识破骗局 练就识别QQ活动真伪火眼金睛
· 应用安全大有可为:目的、挑战、总结
· 道高一尺魔高一丈:安全防御的动感魅力
· 警惕网络“内”院起火 积极谋求安内之路
· HHCTRL漏洞被黑客利用 疯狂传播木马
·中国信息化· ·成功案例·
· ERP普及化是饮鸩止渴 精细化才是应用之道
· 赛门铁克第八期《互联网安全威胁报告》解析
· 抢食“数字工商” 国产中间件杀出血路
· 从IBM等操作系统的发展看软件创新的启示
· 服务成就蓝色快车 品牌是怎样炼成的?
· 三大技术应用大会合为一体甲骨文上演三重奏
· 南阳教育城域网 拆掉学校间的“围墙”
· 金算盘助申意美步入信息化快车道
· 不为人知的索尼信息化 谁是幕后英雄?
· InforBus/Q在穗高速路联网收费系统中的应用
· J2EE构建最新金融理念和运作模式的网上银行
· 食品安全令人担心 信息化能否保驾护航
*姓  名: 更多资料 了解方案 认识厂商
*单位名称:
*联系电话:
*电子邮件:
    
◆ 相关文章   ◆ 站内热点推荐
· 网管员论坛
· 开发者之家
· WLAN无限未来
· 我是如何掉进C#的……
· 中国“人件”非正式调查

   
合作网站: IBM dW中国网站 LinuxAID 软件工程专家网 中国系统分析员 UMLChina MATRIX Mobile2008 JavaResearch 华储网 UML软件工程组织 中国JAVA手机网 JAVA中文站 金山在线 海量科技