个人总结
Oracle® Database Administrator's Guide 10g Release 2 (10.2)的时候文档中Tasks of a Database Administrator有提到DBA的一个task 是 Roll Out to Additional Hosts.里面有提到这样操作的大致方法.但没有详细操作.所以查到这个文档贴出来.以备后期使用.这里只给出了single DB的clone.
20111013 后期实验中发现此文档有不足的地方.实验不通过,还在探索ing,待续.
步骤
注意 tar解压缩添加 -p 参数.用以保存解压后的权限.

Cloning A Database Home And Changing The User/Group That Owns It [ID 558478.1]

  Modified 07-SEP-2011     Type BULLETIN     Status PUBLISHED  

In this Document
  Purpose
  Scope and Application
  Cloning A Database Home And Changing The User/Group That Owns It
  References


Applies to:

Oracle Server - Enterprise Edition - Version: 10.2.0.1 to 11.1.0.7 - Release: 10.2 to 11.1
Information in this document applies to any platform.
The information supplied in this bulletin is applicable to Oracle10g Release 2 (10.2) and Oracle11g Release 1 (11.1) installations on any Unix/Linux platform.

It is not applicable to Oracle on any Windows platform.

Purpose

Support previously created Note:300062.1 to help customers to clone their Oracle database installations. This bulletin is an extension to the above note.

The purpose of this bulletin is to provide a list of the steps required to clone an Oracle10g Release 2 (10.2) or Oracle11g Release 1 (11.1) installation from a source home to a target location (on the same server, or on another server) and simultaneously change the user/group that owns the software installation.

Oracle Development have reviewed these steps and confirmed that the procedure is supported.

Scope and Application

This bulletin is intended for anyone responsible for installing/cloning Oracle software on a Unix/Linux server

The procedure below assumes that Oracle10g Release 2 (10.2) or Oracle11g Release 1 (11.1) is already installed in a source home on a server.

If you are cloning to a separate server, verify that the server meets all of the defined requirements (see Note:169706.1 for a list of these)

If you are cloning to an AIX server that has not previously had any Oracle software installed on it, download patch 6613550 and run the supplied rootpre.sh script. so that the server is configured ready for the Oracle software.

Cloning A Database Home And Changing The User/Group That Owns It

1. Create a tarball of the source home

% cd
% tar cvf /tmp/source.tar .

NOTE: Do not use the command "tar cvf /tmp/source.tar $ORACLE_HOME" because the full path for the $ORACLE_HOME will be included in the source.tar file and this will cause problems in step 3

2. Optionally, use binary transfer to move /tmp/source.tar to the target server. If you are cloning on the same server, go to step 3.

3. Unpack the tarball into the target location

% cd
% tar xvf /tmp/source.tar

NOTE: Check that any symbolic links in the target home have been preserved so that they link to the same locations as they did in the source home. If necessary, re-create the links.

4. As the 'root' user, use the 'chown' command to change the ownership of any files owned by user A to be owned by user B

% find . -user -exec chown {} \;

NOTE: Do not use "chown -R $ORACLE_HOME" because this will change the ownership of some files that were not previously owned by . For example, $ORACLE_HOME/bin/oradism

5. As the 'root' user, use the 'chgrp' command to change the group ownership of any files owned by group A to be owned by group B

% find . -group -exec chgrp {} \;

NOTE: Do not use "chgrp -R $ORACLE_HOME" because this will change the ownership of some files that were not previously owned by . For example, $ORACLE_HOME/bin/extjob

6. Rename the $ORACLE_HOME/rdbms/lib/config.o file

% cd $ORACLE_HOME/rdbms/lib
% mv config.o config.o_backup

7. The next step is dependant on which Operating System (OS) is being used

On Linux and HPUX, edit the $ORACLE_HOME/rdbms/lib/config.c file to change the group that owns the installation

% vi config.c

Find the following lines at the end of the file:

#define SS_DBA_GRP "dba"
    #define SS_OPER_GRP "dba"

Replace "dba" with the name of the group that will own the target installation

Save the changes to the config.c file

On Solaris, edit the $ORACLE_HOME/rdbms/lib/config.s file:

% vi config.s

Find the following lines within the file:

/* 0x0008 15 */ .ascii "dba\0"
    :
    /* 0x0014 22 */ .ascii "dba\0"

Replace "dba" with the name of the group that will own the target installation

Save the changes to the config.s file

On AIX, edit the $ORACLE_HOME/rdbms/lib/config.s file:

% vi config.s

Find the following lines within the file:

.csect H.12.NO_SYMBOL{RO}, 3
    .string "dba
    :
    .csect H.14.NO_SYMBOL{RO}, 3
    .string "dba"

Replace "dba" with the name of the group that will own the target installation

Save the changes to the config.s file

See Note:50507.1 for further details

8. Set any environment variables (for example, LD_LIBRARY_PATH) to point to the target home rather than the source home

9. Optionally, regenerate config.o and relink the 'oracle' binary

% make -f ins_rdbms.mk config.o
% make -f ins_rdbms.mk ioracle

These commands are also executed during the relinking phase at the end of the cloning process (step 10)

NOTE: On Sun SPARC Solaris (64-bit), the command to regenerate config.o may fail with the following errors:

/usr/ccs/bin/as -P -K PIC -o config.o config.s
/usr/ccs/bin/as: "config.s", line 12: error: cannot use v9 instructions in a non-v9 target binary
/usr/ccs/bin/as: "config.s", line 14: error: cannot use v9 instructions in a non-v9 target binary
*** Error code 1
make: Fatal error: Command failed for target `config.o'

To workaround this problem, rename $ORACLE_HOME/rdbms/lib/config.o (if it exists) and just relink the 'oracle' binary. Relinking the 'oracle' binary should also regenerate the config.o file.

10. Run the $ORACLE_HOME/clone/bin/clone.pl script. (or ./runInstaller -clone) to clone the installation

% cd $ORACLE_HOME/clone/bin
% perl clone.pl ORACLE_HOME="" ORACLE_HOME_NAME=""

or

% cd $ORACLE_HOME/oui/bin
% ./runInstaller -clone -silent -ignorePreReq ORACLE_HOME="" ORACLE_HOME_NAME=""

If you wish to use an oraInst.loc file in a non-default location, update the "clone_command_line" in $ORACLE_HOME/clone/config/cs.properties so that it includes "-invPtrLoc /oraInst.loc"

See Note:559304.1 and Note:559305.1 for further details about the cloning process

11. Run the $ORACLE_HOME/root.sh script. as the 'root' user

12. Optionally, run the $ORACLE_HOME/install/changePerm.sh script. to relax permissions on the home

13. DB Console users may need to refer to Note:467598.1 and/or Note:278100.1 to enable them to startup the console on the new server

References

NOTE:278100.1 - How To Drop, Create And Recreate the Database Control (DB Control) Release 10g and 11g
NOTE:300062.1 - How To Clone An Existing RDBMS Installation Using OUI
NOTE:467598.1 - The Database Console Fails to Start After a Change in the Hostname
NOTE:50507.1 - SYSDBA and SYSOPER Privileges in Oracle
NOTE:559304.1 - Cloning An Existing Oracle10g Release 2 (10.2.0.x) RDBMS Installation Using OUI
NOTE:559305.1 - Cloning An Existing Oracle11g Release 1 (11.1.0.x) RDBMS Installation Using OUI
PATCH:6613550 - ROOTPRE.SH CHANGE FOR AIX 6.1 (UPDATED AIO CONFIG STEPS)

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/11780477/viewspace-709028/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/11780477/viewspace-709028/

Cloning A Database Home And Changing The User/Group That Owns It相关推荐

  1. Oracle的C 模板,Oracle 19c 官方文档系列-《Database Administrator’s Guide》

    Oracle 19c 官方文档系列-<Database Administrator's Guide> 免费 专栏简介 19c 作为 Oracle Database 12c 的最终稳定版版, ...

  2. Oracle Database 12c Security - 12. Audit for Accountability

    Oracle Unified Audit Trail (OUA)是12c新增功能. THE SECURITY CYCLE 审计使安全更完整,审计是事后行为,不能预防. 访问控制并不能保证非授权访问,人 ...

  3. dbv数据库乱码_使用DBV进行数据库版本控制

    dbv数据库乱码 It's good practice to always use a version control system in any of your projects. Be it a ...

  4. 【11g】屏蔽敏感数据 (Masking Sensitive Data)

    16 Masking Sensitive Data 本章提供了关于组成Oracle数据屏蔽的组件的概念信息,以及关于执行任务序列的过程信息,例如创建屏蔽格式和屏蔽定义.讨论的主题包括: Overvie ...

  5. firebase_Firebase真的像它看起来那样很棒

    firebase Don't get me wrong, I like Firebase - but with everything dev related, there's always a goo ...

  6. 大量数据转移_大量数据

    大量数据转移 by BerkeleyTrue 由BerkeleyTrue 大量数据 (A Flood of Data) Free Code Camp's data has been doubling ...

  7. mvp内粗泄露问题_如何在一小时内启动MVP服务器

    mvp内粗泄露问题 by Yisroel Yakovson 通过伊斯洛尔·雅科夫森 如何在一小时内启动MVP服务器 (How to Launch Your MVP Server in an Hour) ...

  8. oracle中的fetchsize,oracle setFetchsize() 优化查询速度

    实践分析: 最开始在statement 上面设置fetchsize的原因是想增加查询结果返回的速度,因为这样一下子就可以返回更多的数据,但是实际上当我们加上这个条件的时候,没有起到效果,反而慢了下来, ...

  9. 7月最新发布10.2.0.4.5 Patch Set Update

    同11.2.0.1.2 psu同时发布的还有10.2.0.4.5 psu,值得注意的是这2个psu都包括了针对ora-600/7445错误出现时信息显示的原因和调用(cause/action). 附该 ...

最新文章

  1. 构建区块链数字货币交易平台服务器的选择
  2. 阔步向前冲,拥抱云计算-【软件和信息服务】2012.10
  3. 将一个键值对添加入一个对象_细品Redis高性能数据结构之hash对象
  4. eplan怎样创建和修改图框_EPLAN标题页及图框的设计
  5. 信息学奥赛C++语言: 区间内的真素数
  6. opencv_modules.hpp 头文件
  7. Netgear业务交换机被曝15个漏洞,有些不修复
  8. Kubernetes中StatefulSet介绍
  9. UVALive5461 UVA615 POJ1308 Is It A Tree?(解法二)【废除!!!】
  10. 剑指offer例题分享--6
  11. 常用著名网络教学平台
  12. 中标麒麟7.0+linux内核版本,中标麒麟7.0下载
  13. java的listroots_Java File listRoots()用法及代码示例
  14. CVPR 2019 论文汇总(按方向划分,0514 更新中)-转载
  15. 计算视频的信息传输速率
  16. 夜天之书 #78 共建的神话
  17. 视频压缩编码参考软件代码入门
  18. 【ADNI】对 nii 3D 数据进行裁剪(Matlab)待完善...
  19. 横河川仪压力变送器故障代码_EJA压力变送器常见故障处理方法
  20. 考研线性代数(矩阵)

热门文章

  1. Qiyuan-接小球游戏3.0
  2. 手机电话本怎么导入另一个手机
  3. APP爬虫之央视新闻
  4. JAVA JNI调用科大讯飞离线语音合成(Linux篇)
  5. CentOS 7 下的软件安装方法及策略
  6. 云计算企业级小架构部署应用综合练习-二- Ansible 部署 Elastic Stack(ELK)
  7. 从事SQL相关工作者可以成为数据科学家吗
  8. 分享Silverlight/Windows8/WPF/WP7/HTML5周学习导读(5月27日-6月3日)
  9. 基于网络小型文件型的数据管理系统
  10. 用户留存统计 java_用户留存率以及DNU、DAU、WAU、MAU关系