从RAC环境复制到单机(二)

http://inthirties.com:90/thread-1296-1-1.html

 

 

从RAC环境复制到单机< 一>

 

 

备份很全,可以开始复制数据库了。
先启动目标库到nomount

[oracle@inthrac01 oracle]$ sqlplus sys/1qaz2wsx@single as sysdba
SQL> startup nomount;
ORACLE instance started.

Total System Global Area 230686720 bytes
Fixed Size 2082944 bytes
Variable Size 83888000 bytes
Database Buffers 138412032 bytes
Redo Buffers 6303744 bytes
SQL> show parameter control;

 

下面开始duplicate数据库了

[oracle@inthrac01 oracle]$ rman target / auxiliary sys/1qaz2wsx@single

Recovery Manager: Release 10.2.0.4.0 - Production on Fri Mar 26 08:04:09 2010

Copyright (c) 1982, 2007, Oracle. All rights reserved.

connected to target database: INTHRAC (DBID=1794719859)
connected to auxiliary database: SINGLE (not mounted)

RMAN> duplicate target database to single;

Starting Duplicate Db at 26-MAR-10
…….
executing Memory Script

database opened
Finished Duplicate Db at 26-MAR-10
RMAN>

现在复制数据库已经成功

检查目标库
数据文件

SQL> select file_name, file_id from dba_data_files;

FILE_NAME FILE_ID
——————————————— ———-
+DG1/single/datafile/system.315.714643485 1
+DG1/single/datafile/undotbs1.310.714643497 2
+DG1/single/datafile/sysaux.314.714643489 3
+DG1/single/datafile/users.308.714643501 4
+DG1/single/datafile/undotbs2.312.714643491 5
+DG1/single/datafile/xpr91ts.1 6

6 rows selected.

日志文件

SQL> select * from v$logfile;

GROUP# STATUS TYPE MEMBER IS_
———- ——- ——- ——————————————— —
2 ONLINE +DG1/single/onlinelog/group_2.302.714643733 NO
1 ONLINE +DG1/single/onlinelog/group_1.303.714643731 NO
3 ONLINE +DG1/single/onlinelog/group_3.306.714643723 NO
4 ONLINE +DG1/single/onlinelog/group_4.304.714643727 NO

控制文件

SQL> select * from v$controlfile;

STATUS NAME IS_ BLOCK_SIZE FILE_SIZE_BLKS
——- ————————————————– — ———- ————–
+DG1/single/controlfile/current01.ctl NO 16384 952

现在复制成功,把你的spfile建到asm里吧
SQL> create spfile=’+DG1/single/spfilesingle’ from pfile=’/u01/app/oracle/product/10.2.0/db_1/dbs/initsingle.ora’;
File created.

修改你的/u01/app/oracle/product/10.2.0/db_1/dbs /initsingle.ora
将spfile定位到ASM的DG上
vi /u01/app/oracle/product/10.2.0/db_1/dbs/initsingle.ora
spfile=’+DG1/single/spfilesingle’

启动数据库
SQL> shutdown immediate;
Database closed.
Database dismounted.
ORACLE instance shut down.

SQL> startup
ORACLE instance started.
SQL> show parameter spfile;

NAME TYPE VALUE
———————————— ———– ——————————
spfile string +DG1/single/spfilesingle

[oracle@inthrac01 oracle]$ rman target /

 

 

 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

inthirties

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值