码迷,mamicode.com
首页 > 其他好文 > 详细

关于rman duplicate 一些比较重要的知识点--系列三

时间:2015-07-13 20:40:40      阅读:133      评论:0      收藏:0      [点我收藏+]

标签:


FYI:

http://docs.oracle.com/cd/E11882_01/backup.112/e10643/rcmsynta020.htm#RCMRF126


rman duplicate database 必须是相同的平台,但是支持32bit\64bit 间复制,在复制完成后需要运行¥ORACLE_HOME/rdbms/admin/utlirp.sql
脚本来转换pl/sql 代码



The DUPLICATE command requires one or more auxiliary channels. These channels perform the work of the duplication on the auxiliary database instance. 
rman duplicate 命令需要在备库上至少要分配一个以上辅助通道(auxiliary channels)


If the source database files are in the Oracle Managed Files (OMF) format, then you cannot use the DB_FILE_NAME_CONVERT and 
LOG_FILE_NAME_CONVERT initialization parameters or the fileNameConversionSpec clause to generate new OMF file names for the 
duplicate database. If you do not follow this rule, the new OMF files generated from these three methods can cause problems
  使用duplicate 时必须要注意,如果源库使用OMF,那么我们就不能使用 DB_FILE_NAME_CONVERT 和 LOG_FILE_NAME_CONVERT 和其他的文件转
换方式,否者就会出问题;例如,备库的控制文件里的数据文件名是根据DB_FILE_NAME_CONVERT 和 LOG_FILE_NAME_CONVERT 转换而来,但是实际

数据文件求不在对应的路径下,实际文件会采用OMF来管理;这时需要使用:

1》RMAN catalog 和 switch database to copy

2》alter database rename file to 和 

3》switch datafile file# to copy 来修正控制文件的信息;

                                      


当然也有例外,如果只是换个asm 磁盘组名,其他路径名不变,可以使用DB_FILE_NAME_CONVERT
The only exception to this rule is when changing only an ASM disk group name. Assume that source data files and online redo 
log files are stored in ASM disk group +SOURCEDSK. You want to store the duplicate database files in ASM disk group +DUPDSK. 
In this case, you can set the initialization parameters as follows:
DB_FILE_NAME_CONVERT = ("+SOURCEDSK","+DUPDSK")
LOG_FILE_NAME_CONVERT = ("+SOURCEDSK","+DUPDSK") 


RMAN uses DB_FILE_NAME_CONVERT or LOG_FILE_NAME_CONVERT to convert the disk group name, and then generates a new, valid file 
name based on the converted disk group name.


-如果源库使用OMF,建议使用以下参数配置:
You have the following other supported options for naming data files when the source files are in the Oracle Managed Files format:

1.Use SET NEWNAME to specify names for individual data files. 
2.Set DB_FILE_CREATE_DEST to make all data files of the new database Oracle-managed files, except the files for which SET 



NEWNAME is used. You should not set DB_FILE_NAME_CONVERT if you set DB_FILE_CREATE_DEST.
DB_CREATE_FILE_DEST 
DB_RECOVERY_FILE_DEST 


对于redolog 如果没有设置DB_RECOVERY_FILE_DEST, or DB_CREATE_ONLINE_LOG_DEST_n. 则会使用DB_CREATE_FILE_DEST 参数指定的目录来存放

SQL> show parameter DB_CREATE_ONLINE_LOG_DEST
NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
db_create_online_log_dest_1          string
db_create_online_log_dest_2          string
db_create_online_log_dest_3          string
db_create_online_log_dest_4          string
db_create_online_log_dest_5          string

若单独指定 db_create_online_log_dest_* 参数,则redolog member 会冗余放到这些单独指定的目录下

Supported options for naming online redo logs duplicated from Oracle-managed files are DB_CREATE_FILE_DEST, 

DB_RECOVERY_FILE_DEST, or DB_CREATE_ONLINE_LOG_DEST_n.


----DB_CREATE_ONLINE_LOG_DEST_n 参数解释,为redolog,control file指定存放目录,指定多个则多路复用
DB_CREATE_ONLINE_LOG_DEST_n (where n = 1, 2, 3, ... 5) specifies the default location for Oracle-managed control files and online redo logs. If more than one DB_CREATE_ONLINE_LOG_DEST_n parameter is specified, then the control file or online redo log is multiplexed across the locations of the other DB_CREATE_ONLINE_LOG_DEST_n parameters. One member of each online redo log is created in each location, and one control file is created in each location.


Specifying at least two parameters provides greater fault tolerance for the control files and online redo logs if one of the locations should fail.

If a file system directory is specified as the default location, then the directory must already exist; Oracle does not create it. The directory must have appropriate permissions that allow Oracle to create files in it. Oracle generates unique names for the files, and a file thus created is an Oracle Managed File.

对于文件系统而言,指定的目录必须权限准确,且已经存在;如果没有,oracle 不会自动创建


版权声明:本文为博主原创文章,未经博主允许不得转载。

关于rman duplicate 一些比较重要的知识点--系列三

标签:

原文地址:http://blog.csdn.net/lixora/article/details/46866793

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!