RMAN 异机迁移实战操作-附加常用命令

php中文网
发布: 2016-06-07 15:54:56
原创
1386人浏览过

操作操作场景 源服务器 OEL 6.3 11G R2 11.2.0.3目标服务器 OEL 6.3 11G R2 11.2.0.3源服务器和目标服务器存放数据路

操作操作场景

 源服务器      OEL 6.3 11G R2 11.2.0.3
目标服务器    OEL 6.3 11G R2 11.2.0.3
源服务器和目标服务器存放数据路径一样

 源服务器
[Oracle@mxq ~]$ rman target /

 Recovery Manager: Release 11.2.0.2.0 - Production on Sat May 16 08:51:05 2015

 Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.

 connected to target database: ORACLE11 (DBID=2573050700)

 RMAN> run
 {allocate channel orademo type disk MAXPIECESIZE 1024m;
 backup incremental level 0 as compressed backupset database include current controlfile tag='full' format '/home/oracle/db_%s_%p_%t' plus archivelog tag='arch_all' format  '/home/oracle/arch_%s_%p_%t' delete input;
 }2> 3> 4>

 released channel: ORA_DISK_1
 allocated channel: orademo
 channel orademo: SID=147 device type=DISK


 Starting backup at 16-MAY-15
 current log archived
 channel orademo: starting compressed archived log backup set
 channel orademo: specifying archived log(s) in backup set
 input archived log thread=1 sequence=96 RECID=69 STAMP=879840530
 channel orademo: starting piece 1 at 16-MAY-15
 channel orademo: finished piece 1 at 16-MAY-15
 piece handle=/home/oracle/arch_59_1_879840531 tag=ARCH_ALL comment=NONE
 channel orademo: backup set complete, elapsed time: 00:00:01
 channel orademo: deleting archived log(s)
 archived log file name=/orafile/arc/1_96_879804940.arc RECID=69 STAMP=879840530
 Finished backup at 16-MAY-15

 Starting backup at 16-MAY-15
 channel orademo: starting compressed incremental level 0 datafile backup set
 channel orademo: specifying datafile(s) in backup set
 including current SPFILE in backup set
 including current control file in backup set
 input datafile file number=00002 name=/orafile/oradata/sysaux01.dbf
 input datafile file number=00001 name=/orafile/oradata/system01.dbf
 input datafile file number=00003 name=/orafile/oradata/undotbs01.dbf
 input datafile file number=00004 name=/orafile/oradata/users01.dbf
 channel orademo: starting piece 1 at 16-MAY-15
 channel orademo: finished piece 1 at 16-MAY-15
 piece handle=/home/oracle/db_60_1_879840533 tag=FULL comment=NONE
 channel orademo: backup set complete, elapsed time: 00:02:55
 Finished backup at 16-MAY-15

 Starting backup at 16-MAY-15
 current log archived
 channel orademo: starting compressed archived log backup set
 channel orademo: specifying archived log(s) in backup set
 input archived log thread=1 sequence=97 RECID=72 STAMP=879840713
 channel orademo: starting piece 1 at 16-MAY-15
 channel orademo: finished piece 1 at 16-MAY-15
 piece handle=/home/oracle/arch_61_1_879840714 tag=ARCH_ALL comment=NONE
 channel orademo: backup set complete, elapsed time: 00:00:01
 channel orademo: deleting archived log(s)
 archived log file name=/orafile/arc/1_97_879804940.arc RECID=72 STAMP=879840713
 Finished backup at 16-MAY-15
 released channel: orademo

把新的备份集拷贝到目标服务器
[oracle@mxq ~]$ cd /home/oracle/
 [oracle@mxq ~]$ ls
 arch_59_1_879840531  arch_61_1_879840714  db_60_1_879840533
 [oracle@mxq ~]$ ll
 total 248900
 -rw-r----- 1 oracle oinstall    219648 May 16 08:08 arch_59_1_879840531
 -rw-r----- 1 oracle oinstall  1256448 May 16 08:11 arch_61_1_879840714
 -rw-r----- 1 oracle oinstall 253394944 May 16 08:11 db_60_1_879840533
 [oracle@mxq ~]$ scp * [email protected]:/home/oracle/
 [email protected]'s password:
 arch_59_1_879840531                          100%  215KB 214.5KB/s  00:00   
 arch_61_1_879840714                          100% 1227KB  1.2MB/s  00:00   
 db_60_1_879840533                            100%  242MB  13.4MB/s  00:18 

目标服务器

Natural Language Playlist
Natural Language Playlist

探索语言和音乐之间丰富而复杂的关系,并使用 Transformer 语言模型构建播放列表。

Natural Language Playlist 67
查看详情 Natural Language Playlist

 提示:
 如果已经数据文件、控制文件、在线日志文件、参数文件那么新删除掉在进行做恢复不然后面报错

[oracle@mxq ~]$ rman target /

 Recovery Manager: Release 11.2.0.2.0 - Production on Sun May 17 12:10:05 2015

 Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.

 connected to target database (not started)


 RMAN> startup force nomount;

 Oracle instance started

 Total System Global Area    521936896 bytes

 Fixed Size                    2228072 bytes
 Variable Size                159383704 bytes
 Database Buffers            352321536 bytes
 Redo Buffers                  8003584 bytes


 RMAN> restore spfile from '/home/oracle/db_54_1_879855779';

 Starting restore at 17-MAY-15
 allocated channel: ORA_DISK_1
 channel ORA_DISK_1: SID=134 device type=DISK

最佳 Windows 性能的顶级免费优化软件
最佳 Windows 性能的顶级免费优化软件

每个人都需要一台速度更快、更稳定的 PC。随着时间的推移,垃圾文件、旧注册表数据和不必要的后台进程会占用资源并降低性能。幸运的是,许多工具可以让 Windows 保持平稳运行。

下载
来源:php中文网
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系admin@php.cn
最新问题
开源免费商场系统广告
热门教程
更多>
最新下载
更多>
网站特效
网站源码
网站素材
前端模板
关于我们 免责申明 举报中心 意见反馈 讲师合作 广告合作 最新更新 English
php中文网:公益在线php培训,帮助PHP学习者快速成长!
关注服务号 技术交流群
PHP中文网订阅号
每天精选资源文章推送
PHP中文网APP
随时随地碎片化学习

Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号