用rman进行数据迁移
来源:互联网 发布:淘宝上的劣质充气娃娃 编辑:程序博客网 时间:2024/06/06 13:16
RMAN数据迁移
原理:源数据库(A) rman备份。新数据库rman(B)恢复。
(A)
1.新建RMAN恢复目录数据库(实例=rman).
第一步,在目录数据库中创建恢复目录所用表空间:
create tablespace rman_tar datafile '/oracle/oradata/rman/rman_tar.dbf' size 20M;
第二步,在目录数据库中创建RMAN 用户并授权:
create user rman identified by rman default tablespace rman_tar;
grant recovery_catalog_owner to rman;
grant connect to rman;
grant resource to rman;
第三步,在目录数据库中创建恢复目录
$rman catalog rman/rman
如果未安装恢复目录 (执行)
create catalog tablespace rman_tar;
2.注册目标数据库
[oracle@SZSC ~]$ rman catalog rman/rman
RMAN> connect target /
RMAN> register database;
3.对目标数据库进行备份
run{
configure controlfile autobackup on;
configure controlfile autobackup format for device type disk to '/opt/backup/%F';
allocate channel d1 type disk format '/opt/backup/full_%U';
backup database tag 'full_ora10g_data' filesperset 10 plus archivelog filesperset 20 delete all input;
release channel d1;
}
4.将备份的backup目录传输到目标服务器对应的backup目录。并且将密码文件及pfile文件传到对应的目录。
Scp -r /opt/backup/* 192.168.124.3:/opt/backup
Scp -r /opt/oracle/dbs/* 192.168.124.3:/opt/oracle/dbs
(B)
5.到B数据库,进行恢复。
先用传输过来的pfile启动数据库。
Sqlplus / as sysdba
Startup nomount pfile='/opt/oracle/dbs/initora10g.ora
6.连接rman
Rman target /
Set dbid=XXXXX(DBID到控制文件自动备份里找)
恢复控制文件。
Restore controlfile from '/opt/backup/c-4106385437-20120723-01'
Alter database mount
恢复数据文件
Restore databae from tag='full_ora10g_data';
Recover database;
Alter databae open;
- 用rman进行数据迁移
- 使用RMAN进行数据迁移
- rman数据迁移
- 使用rman进行数据库迁移
- 【ORACLE】RMAN实现数据迁移
- 用Rman迁移数据库
- 用RMAN 备份异机恢复 迁移数据
- 用RMAN 备份异机恢复 迁移数据
- 用RMAN 备份异机恢复 迁移数据
- 用RMAN 备份异机恢复 迁移数据
- 用RMAN 备份异机完全恢复 迁移数据
- 用RMAN 备份异机恢复 迁移数据
- 用RMAN 备份异机恢复 迁移数据
- 用rman进行恢复数据,出现RMAN-03009,RMAN-11003,ORA-01991错误
- Oracle 数据进行迁移
- Rman数据迁移至ASM数据库
- Rman数据迁移至ASM数据库
- RMAN 备份异机恢复 迁移数据
- Git使用笔记
- Qt入门-QTreeWidget类
- ios界面动画小结
- Linux创建静态库和动态库
- win7中,让你的资源管理器默认打开是磁盘列表
- 用rman进行数据迁移
- 众人给诺基亚支招 Android提议何时了?
- log4j.properties的完整配置
- Linux下undefined reference to ‘pthread_create’问题解决
- sqlite 升级
- (转)java学习:ArrayList的实现原理
- php中获取系统信息的方法
- 即时通讯软件openfire+spark+smack
- 27路公交缩线半年未恢复 回应:正联系合适停车场地