Oracle的家目录进行快速克隆,对同类型机器配置很高效的!

01、确认你在克隆数据库时,原数据库已经关闭

sqlplus   /   as sysdba;

shutdown immediate ;

lsnrctl stop

ps –ef|grep ora_    ###查看oracle进程

02、 对$ORACLE_BASE目录下的product进行备份

zip  –r product.zip    product

03、移动到目标机器或目标目录解压

unzip   –d  target_path   product.zip    # 或者在目标目录下   unzip product.zip

04、删除解压后的product/network/admin下面的ora文件

rm  *.ora     ###清理监听文件

05、运行runinstaller

$ORACLE_HOME/oui/bin/runinstaller  –silent –clone  ORACLE_BASE='productd的当前目录'   ORACLE_HOME='oracle_home目录'    ORACLE_HOME_NAME='这个名字随便取一个'

注:运行以上命令,会出现一个字符界面的进度条,全部运行完后。你运行一个脚本root.sh,以root 运行,一路回车就ok了。

cd product/11.2.0/dbhome_1/oui/bin
[oracle@oracle-111 bin]$ ./runInstaller -silent -clone ORACLE_HOME='/data/clone_oracle/product/11.
2.0/dbhome_1' ORACLE_HOME_NAME='clone' Starting Oracle Universal Installer... Checking swap space: must be greater than 500 MB. Actual 1535 MB Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2017-02-27_06-41-44AM. Please w
ait ...[oracle@oracle-111 bin]$ Oracle Universal Installer, Version 11.2.0.4.0 ProductionCopyright (C) 1999, 2013, Oracle. All rights reserved. You can find the log of this install session at:
/data/oraInventory/logs/cloneActions2017-02-27_06-41-44AM.log
Values for the following variables could not be obtained from the command line or response file(s)
: ORACLE_BASE
Cloning cannot
continue. ###第一次没指定ORACLE_BASE目录导致的错误 [oracle@oracle-111 bin]$ ./runInstaller -silent -clone ORACLE_BASE='/data/clone_oracle' ORACLE_H
OME=
'/data/clone_oracle/product/11.2.0/dbhome_1' ORACLE_HOME_NAME='clone' -noConfig -nowaitStarting Oracle Universal Installer... Checking swap space: must be greater than 500 MB. Actual 1535 MB Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2017-02-27_06-43-34AM. Please w
ait ...[oracle@oracle-111 bin]$ Oracle Universal Installer, Version 11.2.0.4.0 ProductionCopyright (C) 1999, 2013, Oracle. All rights reserved. You can find the log of this install session at:
/data/oraInventory/logs/cloneActions2017-02-27_06-43-34AM.log
..................................................................................................
.. 100% Done. Installation in progress (Monday, February 27, 2017 6:43:59 AM CST)
..............................................................................
78% Done.Install successful Linking in progress (Monday, February 27, 2017 6:44:08 AM CST)
Link successful Setup in progress (Monday, February 27, 2017 6:46:56 AM CST)
Setup successful End of install phases.(Monday, February 27, 2017 6:47:47 AM CST)
WARNING:
The following configuration scripts need to be executed as the "root" user.
/data/clone_oracle/product/11.2.0/dbhome_1/root.sh  ###以root身份运行root.sh文件
To execute the configuration scripts:
1. Open a terminal window
2. Log in as "root"
3. Run the scripts The cloning of clone was successful.
Please check '/data/oraInventory/logs/cloneActions2017-02-27_06-43-34AM.log' for more details. [oracle@oracle-111 bin]$ cd ..

 06、设置oracle环境变量

cd ~

vim .bash_profile  ###根据需求进行修改

#export ORACLE_SID=mvp

export ORACLE_BASE=/data/clone_oracle

export ORACLE_HOME=$ORACLE_BASE/product/11.2./dbhome_1

export LD_LIBRARY_PATH=$ORACLE_HOME/lib

export NLS_DATE_FORMAT='yyyy-mm-dd hh24:mi:ss'

export PATH=$ORACLE_HOME/bin:/usr/local/bin:$PATH:$HOME/bin

07、建立数据库实例及监听

netca  ###监听

dbca   ###实例

####启动新建的实例

sqlplus / as  sysdba;

startup

exit;

Oracle快速克隆安装的更多相关文章

  1. Oracle 11g静默安装简明版

    环境:RHEL 6.5 + Oracle 11.2.0.4 1. 初步处理应答文件 2. 静默安装软件 3. 静默安装监听 4. 静默dbca建库 说明: 本文默认安装软件前的步骤已经设置完毕 如果没 ...

  2. Solaris 和linux 之oracle 数据库的安装

    本篇博文前面是一些基础知识介绍,后面才是总结篇. 一.在solaris上面装oracle 10g教程 目前官网已经没有32位的oracle11g了,取而代之的都是64位的oracle11g,为了能在3 ...

  3. Linux 6.x 下Oracle 11g R2 安装配置

    Oracle 11g R2 数据库安装硬件配置要求: 最小内存 1 GB of RAM 虚拟内存容量,这个oracle也有要求,不用担心此时的swap分区不够oracle的要求 .虚拟内存swap如何 ...

  4. Linux平台 Oracle 11gR2 RAC安装Part1:准备工作

    一.实施前期准备工作 1.1 服务器安装操作系统 1.2 Oracle安装介质 1.3 共享存储规划 1.4 网络规范分配 二.安装前期准备工作 2.1 各节点系统时间校对 2.2 各节点关闭防火墙和 ...

  5. Linux平台 Oracle 11gR2 RAC安装Part2:GI安装

    三.GI(Grid Infrastructure)安装 3.1 解压GI的安装包 3.2 安装配置Xmanager软件 3.3 共享存储LUN的赋权 3.4 使用Xmanager图形化界面安装GI 3 ...

  6. Linux平台 Oracle 11gR2 RAC安装Part3:DB安装

    四.DB(Database)安装 4.1 解压DB的安装包 4.2 DB软件安装 4.3 ASMCA创建磁盘组 4.4 DBCA建库 4.5 验证crsctl的状态 Linux平台 Oracle 11 ...

  7. Oracle 数据库基础——安装

    一.数据库基础知识 1.概念 数据库全称数据库管理系统,简称DBMS,是一种在计算机中,针对数据进行管理.存储.共享的一种技术. 2.分类 数据库的发展过程中,按逻辑模型可分为以下几种: 3.关系型数 ...

  8. 一、oracle数据库成功安装步骤 (11gR2)

    下载安装包 从Oracle官方网站下载数据库软件安装包:http://www.oracle.com/technetwork/cn/database/enterprise-edition/downloa ...

  9. Oracle 11gR2静默安装 & 命令行安装

    静默安装 经常搭建Oracle测试环境,有时候觉得OUI(即图形界面)方式甚是繁琐,你得一步一步进行确认,所幸,Oracle支持静默安装.在我看来,它主要有两方面的好处:一.极大地提升了效率,尤其是批 ...

随机推荐

  1. Tomcat – java.lang.OutOfMemoryError: PermGen space Cause and Solution

    Read more: http://javarevisited.blogspot.com/2012/01/tomcat-javalangoutofmemoryerror-permgen.html#ix ...

  2. html实现带斜线的表头

    在html.jsp中经常用到table,但在table中如何实现标题表格中画斜线的操作呢?从网上查了很多资料,可以实现的方法有好几种,现在提供一种简单的操作方法,而且不用考虑分辨率的问题,如图: 方法 ...

  3. mysql访问权限GRANT ALL PRIVILEGES ON,访问权限表

    开启远程连接:2, 修改 Mysql-Server 用户配置mysql> USE mysql; -- 切换到 mysql DBDatabase changedmysql> SELECT U ...

  4. Objective-C:ARC自动释放对象内存

    ARC是cocoa系统帮你完成对象内存释放的引用计数机制 .h文件 // Person.h // 01-ARC // // Created by ma c on 15/8/13. // Copyrig ...

  5. OTL翻译(10) -- OTL的流缓冲池

    OTL的流缓冲池 一般来讲,流一般作为一个局部的变量被使用,当使用完毕后就立刻关闭,如果需要再次使用就需要再次的声明变量,如此循环.OTL流的缓冲池(内存池)是一个解决以往的流性能低下的一个机制.当流 ...

  6. 又议android中的manifest清单文件

    写过java程序的人,都知道了配置文件时java实现各种各样的框架的一大利器,manifest清单文件对android的作用自然不言而喻,然而他里面究竟定义了些什么,并且他是如何加载到程序中的. 他里 ...

  7. Mac下如何进行端口转发,方便一系列需要使用80端口进行的调试工作

    上篇文章介绍到,可以在本地hosts文件中添加一条记录将微信公众号中的可信域名解析道本地127.0.0.1,但tomcat在Mac下非root权限80端口是启动不了的,所以我们可以利用pfctl端口转 ...

  8. 初探 hexo博客

    近期两天迷上了hexo和gitcafe.最终搭建好了自己的个人主页.以后也能够用那个来写博客啦~直接用的gitcafe的二级域名和server,(gitcafe的server在国外.速度也挺快的),h ...

  9. BZOJ 1264 AHOI2006 基因匹配Match 动态规划+树状数组

    题目大意:给定n个数和两个长度为n*5的序列,每一个数恰好出现5次,求两个序列的LCS n<=20000.序列长度就是10W.朴素的O(n^2)一定会超时 所以我们考虑LCS的一些性质 LCS的 ...

  10. centos+apache+mod_ssl

    参考网站:配置Apache建立openssl证书实现SSL访问:http://blog.51yip.com/apachenginx/958.html用ca工具生成证书的方法:http://hi.bai ...