oracle 11g 从+DATA迁移到+newdata ASM 磁盘组迁移
oracle 11g 从+DATA迁移到+newdata ASM 磁盘组迁移
原创 lixora 最后发布于2016-12-04 11:01:39 阅读数 1069 收藏
展开
从+DATA迁移到+newdata磁盘组
---归档模式:
1.利用copy备份数据库
rman>backup as copy database format ‘+DG1‘
2.待备份完,启动到mount状态(启动第一节点数据库到mount,其它节点数据库实例关闭)
SQL> shutdown immediate
SQL> startup mount;
P750a:/home/oracle$export ORACLE_SID=lixora1
P750a:/home/oracle$rman target /
Recovery Manager: Release 11.2.0.3.0 - Production on Fri Dec 2 23:58:55 2016
Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.
connected to target database: lixora (DBID=2736577994, not open)
RMAN> switch database to copy;
using target database control file instead of recovery catalog
datafile 1 switched to datafile copy "+NEWDATA/lixora/datafile/system.305.929576161"
datafile 2 switched to datafile copy "+NEWDATA/lixora/datafile/sysaux.306.929576161"
datafile 3 switched to datafile copy "+NEWDATA/lixora/datafile/undotbs1.257.929568027"
datafile 4 switched to datafile copy "+NEWDATA/lixora/datafile/undotbs2.256.929568027"
datafile 5 switched to datafile copy "+NEWDATA/lixora/datafile/users.258.929568027"
datafile 6 switched to datafile copy "+NEWDATA/lixora/datafile/users.259.929568027"
datafile 7 switched to datafile copy "+NEWDATA/lixora/datafile/users.260.929568783"
datafile 8 switched to datafile copy "+NEWDATA/lixora/datafile/users.261.929568783"
datafile 9 switched to datafile copy "+NEWDATA/lixora/datafile/users.262.929568783"
datafile 10 switched to datafile copy "+NEWDATA/lixora/datafile/users.263.929568783"
datafile 11 switched to datafile copy "+NEWDATA/lixora/datafile/users.264.929569509"
datafile 12 switched to datafile copy "+NEWDATA/lixora/datafile/users.265.929569509"
datafile 13 switched to datafile copy "+NEWDATA/lixora/datafile/users.266.929569513"
datafile 14 switched to datafile copy "+NEWDATA/lixora/datafile/users.267.929569515"
datafile 15 switched to datafile copy "+NEWDATA/lixora/datafile/users.268.929570251"
datafile 16 switched to datafile copy "+NEWDATA/lixora/datafile/users.269.929570251"
datafile 17 switched to datafile copy "+NEWDATA/lixora/datafile/users.270.929570251"
datafile 18 switched to datafile copy "+NEWDATA/lixora/datafile/users.271.929570251"
datafile 19 switched to datafile copy "+NEWDATA/lixora/datafile/users.272.929571027"
datafile 20 switched to datafile copy "+NEWDATA/lixora/datafile/users01.273.929571027"
datafile 21 switched to datafile copy "+NEWDATA/lixora/datafile/users01.274.929571027"
datafile 22 switched to datafile copy "+NEWDATA/lixora/datafile/users01.275.929571031"
datafile 23 switched to datafile copy "+NEWDATA/lixora/datafile/users01.276.929571837"
datafile 24 switched to datafile copy "+NEWDATA/lixora/datafile/users02.277.929571837"
datafile 25 switched to datafile copy "+NEWDATA/lixora/datafile/users02.278.929571837"
datafile 26 switched to datafile copy "+NEWDATA/lixora/datafile/users02.279.929571837"
datafile 27 switched to datafile copy "+NEWDATA/lixora/datafile/users02.280.929572663"
datafile 28 switched to datafile copy "+NEWDATA/lixora/datafile/users03.297.929575401"
datafile 29 switched to datafile copy "+NEWDATA/lixora/datafile/users03.298.929575401"
datafile 30 switched to datafile copy "+NEWDATA/lixora/datafile/users03.299.929575401"
datafile 31 switched to datafile copy "+NEWDATA/lixora/datafile/users03.300.929575787"
datafile 32 switched to datafile copy "+NEWDATA/lixora/datafile/users04.288.929574281"
datafile 33 switched to datafile copy "+NEWDATA/lixora/datafile/users04.289.929574293"
datafile 34 switched to datafile copy "+NEWDATA/lixora/datafile/users04.290.929574293"
datafile 35 switched to datafile copy "+NEWDATA/lixora/datafile/users04.291.929574293"
datafile 36 switched to datafile copy "+NEWDATA/lixora/datafile/users05.301.929575787"
datafile 37 switched to datafile copy "+NEWDATA/lixora/datafile/users05.302.929575789"
datafile 38 switched to datafile copy "+NEWDATA/lixora/datafile/users05.303.929575867"
datafile 39 switched to datafile copy "+NEWDATA/lixora/datafile/users05.304.929576161"
datafile 40 switched to datafile copy "+NEWDATA/lixora/datafile/users06.311.929576269"
datafile 41 switched to datafile copy "+NEWDATA/lixora/datafile/users06.312.929576271"
datafile 42 switched to datafile copy "+NEWDATA/lixora/datafile/users06.313.929576275"
datafile 43 switched to datafile copy "+NEWDATA/lixora/datafile/users06.314.929576275"
datafile 44 switched to datafile copy "+NEWDATA/lixora/datafile/users07.307.929576219"
datafile 45 switched to datafile copy "+NEWDATA/lixora/datafile/users07.308.929576237"
datafile 46 switched to datafile copy "+NEWDATA/lixora/datafile/users07.309.929576257"
datafile 47 switched to datafile copy "+NEWDATA/lixora/datafile/users07.310.929576269"
datafile 48 switched to datafile copy "+NEWDATA/lixora/datafile/popdata.281.929572663"
datafile 49 switched to datafile copy "+NEWDATA/lixora/datafile/popdata.282.929572663"
datafile 50 switched to datafile copy "+NEWDATA/lixora/datafile/users.292.929574853"
datafile 51 switched to datafile copy "+NEWDATA/lixora/datafile/users.293.929574855"
datafile 52 switched to datafile copy "+NEWDATA/lixora/datafile/users.294.929574855"
datafile 53 switched to datafile copy "+NEWDATA/lixora/datafile/users.295.929574855"
datafile 54 switched to datafile copy "+NEWDATA/lixora/datafile/users.283.929572663"
datafile 55 switched to datafile copy "+NEWDATA/lixora/datafile/users.284.929573479"
datafile 56 switched to datafile copy "+NEWDATA/lixora/datafile/users.285.929573479"
datafile 57 switched to datafile copy "+NEWDATA/lixora/datafile/users.286.929573481"
datafile 58 switched to datafile copy "+NEWDATA/lixora/datafile/users.287.929573481"
datafile 64 switched to datafile copy "+NEWDATA/lixora/datafile/zcf6.296.929575401"
---恢复数据库,打开数据库
RMAN> run
{
recover database;
alter database open;
}
Starting recover at 2016-12-03 00:00:05
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=3902 instance=lixora1 device type=DISK
starting media recovery
archived log for thread 1 with sequence 20885 is already on disk as file +ARCHDG/lixora/archivelog/2016_12_02/thread_1_seq_20885.799.929572247
archived log for thread 1 with sequence 20886 is already on disk as file +ARCHDG/lixora/archivelog/2016_12_02/thread_1_seq_20886.735.929574767
archived log for thread 1 with sequence 20887 is already on disk as file +ARCHDG/lixora/archivelog/2016_12_02/thread_1_seq_20887.822.929576417
archived log for thread 1 with sequence 20888 is already on disk as file +ARCHDG/lixora/archivelog/2016_12_02/thread_1_seq_20888.812.929576723
archived log for thread 2 with sequence 12639 is already on disk as file +ARCHDG/lixora/archivelog/2016_12_02/thread_2_seq_12639.1427.929576341
archived log for thread 2 with sequence 12640 is already on disk as file +ARCHDG/lixora/archivelog/2016_12_02/thread_2_seq_12640.888.929577207
archived log file name=+ARCHDG/lixora/archivelog/2016_12_02/thread_1_seq_20885.799.929572247 thread=1 sequence=20885
archived log file name=+ARCHDG/lixora/archivelog/2016_12_02/thread_1_seq_20886.735.929574767 thread=1 sequence=20886
media recovery complete, elapsed time: 00:02:24
Finished recover at 2016-12-03 00:02:41
database opened
RMAN>
----结果确认:
select file_name from dba_data_files;
后续要做的事情:
在新dg 上创建temp 文件;redo log 切换到新dg;spfile 位置dg上的位置调整;
————————————————
版权声明:本文为CSDN博主「lixora」的原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/lixora/article/details/53453191