RAC本地数据文件迁移至ASM的方法(2)

RMAN> copy datafile '/u01/oracle/app/oracle/11.2.0/db/dbs/data0401.ora' to '+DATA';
Starting backup at 13-MAY-16
using channel ORA_DISK_1
channel ORA_DISK_1: starting datafile copy
input datafile file number=00012 name=/u01/oracle/app/oracle/11.2.0/db/dbs/data0401.ora
output file name=+DATA/sdgdorcl/datafile/data01.279.911710969 tag=TAG20160513T050248 RECID=2 STAMP=911711045
channel ORA_DISK_1: datafile copy complete, elapsed time: 00:01:25
Finished backup at 13-MAY-16
RMAN>

6.在sqlplus中将数据库启动到mount状态,rename数据文件,并查看信息
SQL> alter database rename file '/u01/oracle/app/oracle/11.2.0/db/dbs/data0328.ora' to '+DATA/sdgdorcl/datafile/data01.278.911710731';
SQL> alter database rename file '/u01/oracle/app/oracle/11.2.0/db/dbs/data0401.ora' to '+DATA/sdgdorcl/datafile/data01.279.911710969';


7.将rac1,rac2启动
#RAC1
SQL> alter database open;
Database altered.
SQL>

#RAC2
SQL> startup
ORACLE instance started.
Total System Global Area 1.7103E+10 bytes
Fixed Size                  2245480 bytes
Variable Size            7381978264 bytes
Database Buffers        9663676416 bytes
Redo Buffers              55263232 bytes
Database mounted.
Database opened.
SQL>

附:SYSTEM数据文件移植步骤(过程说明):
1. Stop DB.
2. Move the datafile using asmcmd.
3. Mount the DB.
4. Rename the datafile.
5. Open the DB.
6. On other RAC nodes you still need to bounce the database because it is SYSTEM tablespace, otherwise you will keep getting errors ORA-01516 or original error ORA-01157: cannot identify/lock data file.

如何将ASM中的数据文件复制到操作系统中

Oracle 11g RAC ASM磁盘全部丢失后的恢复

Oracle 11g从入门到精通 PDF+光盘源代码

RHEL6 ASM方式安装Oracle 11g R2

Oracle 10g 手工创建ASM数据库

Oracle 10g R2创建ASM实例Step By Step

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://www.heiqu.com/1f6fcdd10e7e18aaa6da2e796d08333e.html