Oracle 之 Cloning $oracle_home (克隆安裝oracle軟體)
用途:Cloning an Oracle Home , 可以免去多臺機器重複安裝oracle軟體
1、停止相關程式
[root@node1 bin]# ./crsctl stop cluster -all
2、打包 dbhome_1 目錄
[root@node1 11.2.0]# cd /u01/app/oracle/product/11.2.0/
[root@node1 11.2.0]# tar -zcvpf db_1.bak db_1/
[root@node1 11.2.0]# ls
db_1 db_1.bak
補充:
Create a ZIP file with the Oracle home (but not the Oracle base) directory.
# zip -r dbhome_1.zip /u01/app/oracle/product/11.2.0/dbhome_1
Do not include the admin, fast_recovery_area, and oradata directories that are under the Oracle base directory. These directories are created in the target installation later, when you create a new database there.
3、(如果是異機克隆) 將ZIP檔案複製到目標計算機的相應目錄。
4、 解壓 tar 包
# tar zxvf db_1.bak -C /app/oracle/product/11.2.0/
注意:
如果有多個節點則所有節點重複2、3、4步驟 。
5、 清除$ORACLE_HOME/network/admin下的*.ora
6、 跑 $ORACLE_HOME/perl/bin/perl clone.pl 指令碼
node1-> $ORACLE_HOME/perl/bin/perl clone.pl ORACLE_BASE="/u01/app/oracle/" ORACLE_HOME="/app/oracle/product/11.2.0/db_1" OSDBA_GROUP=dba OSOPER_GROUP=oper -defaultHomeName
./runInstaller -clone -waitForCompletion "ORACLE_BASE=/u01/app/oracle/" "ORACLE_HOME=/app/oracle/product/11.2.0/db_1" "oracle_install_OSDBA=dba" "oracle_install_OSOPER=oper" -defaultHomeName -defaultHomeName -silent -noConfig -nowait
Starting Oracle Universal Installer...
Checking swap space: must be greater than 500 MB. Actual 6999 MB Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2017-09-06_04-30-28AM. Please wait ...Oracle Universal Installer, Version 11.2.0.4.0 Production
Copyright (C) 1999, 2013, Oracle. All rights reserved.
You can find the log of this install session at:
/u01/app/oraInventory/logs/cloneActions2017-09-06_04-30-28AM.log
.................................................................................................... 100% Done.
Installation in progress (Wednesday, September 6, 2017 4:31:02 AM CST)
.............................................................................. 78% Done.
Install successful
Setup in progress (Wednesday, September 6, 2017 4:33:11 AM CST)
Setup successful
End of install phases.(Wednesday, September 6, 2017 4:33:49 AM CST)
WARNING:
The following configuration scripts need to be executed as the "root" user.
/app/oracle/product/11.2.0/db_1/root.sh
To execute the configuration scripts:
1. Open a terminal window
2. Log in as "root"
3. Run the scripts
The cloning of OraHome1 was successful.
Please check '/u01/app/oraInventory/logs/cloneActions2017-09-06_04-30-28AM.log' for more details.
-- 含義:
Use the following syntax:
$ORACLE_HOME/perl/bin/perl clone.pl ORACLE_BASE="target_oracle_base" ORACLE_HOME="target_oracle_home"
OSDBA_GROUP=OSDBA_privileged_group OSOPER_GROUP=OSOPER_privileged_group -defaultHomeName
補充:
Oracle Universal Installer starts, and then records the cloning actions in the cloneActionstimestamp.log file. This log file is typically located in /orainventory_location/logs directory.
7、 重建監聽與dbca建庫
To configure the connection information for the new database, run Net Configuration Assistant:
$ cd $ORACLE_HOME/bin
$ ./netca
To create a new database for the newly cloned Oracle home, run Database Configuration Assistant:
$ cd $ORACLE_HOME/bin
$ ./dbca
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/31383567/viewspace-2144547/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- 【配置上線】Linux克隆安裝Oracle資料庫軟體LinuxOracle資料庫
- $ORACLE_HOME/OPatch/opatch prereq CheckConflictAgainstOHWithOracleAI
- 備份與恢復oracle_homeOracle
- 2.2. 安裝Oracle軟體Oracle
- 靜默方式安裝、升級oracle(一): 安裝oracle軟體Oracle
- 11. Oracle for Linux安裝和配置—11.3. Oracle安裝和配置—11.3.1. Oracle軟體安裝OracleLinux
- 【BUILD_ORACLE】Oracle 19c RAC搭建(五)DB軟體安裝UIOracle
- 【BUILD_ORACLE】Oracle 19c RAC搭建(四)Grid軟體安裝UIOracle
- oracle之 11.2.0.4 bbed安裝Oracle
- 【ASK_ORACLE】安裝Oracle RAC 12.2的GI軟體時報錯CLSRSC-614Oracle
- GI PSU打補丁之opatch auto 自動方式分別打GI_HOME和ORACLE_HOMEOracle
- Oracle軟體許可權修復Oracle
- 「Oracle」Oracle 資料庫安裝Oracle資料庫
- 在Centos 上安裝oracle-database-preinstall-19c軟體包CentOSOracleDatabase
- ORACLE基礎之oracle鎖(oracle lock mode)詳解Oracle
- ORACLE SQL解析之硬解析和軟解析OracleSQL
- ORACLE的軟 軟 軟 解析!Oracle
- 【配置安裝】靜默安裝Oracle資料庫軟體12c&19cOracle資料庫
- [重慶思莊每日技術分享]-$ORACLE_HOME/OPatch/ocm/bin/emocmrsp 不再有了Oracle
- Oracle 18c安裝初體驗Oracle
- Oracle 11G RAC叢集安裝(3)——安裝OracleOracle
- 使用Xmanager軟體遠端呼叫圖形化安裝Oracle資料庫Oracle資料庫
- oracle之 安裝oracle指定jdk 或者如何解決提示框顯示不全OracleJDK
- 【TUNE_ORACLE】Oracle Hint之概念與用法Oracle
- oracle安裝配置Oracle
- Oracle RUR 安裝Oracle
- Linux安裝oracleLinuxOracle
- golang oracle 安裝GolangOracle
- 如何用靜默方式刪除oracle軟體Oracle
- Oracle之結構Oracle
- Oracle Linux 6.5 安裝Oracle 10gR2LinuxOracle 10g
- Oracle調優之看懂Oracle執行計劃Oracle
- Linux環境安裝Oracle11g(四)——軟體安裝及引數最佳化LinuxOracle
- 11. Oracle for Linux安裝和配置—11.3. Oracle安裝和配置—11.3.3. Oracle net配置OracleLinux
- Oracle叢集軟體管理-OCR和Voting Files管理Oracle
- 【Oracle】Windows安裝oracle11gR1 database 11.1.0.6OracleWindowsDatabase
- oracleLinux下安裝oracleOracleLinux
- ubuntu下安裝oracleUbuntuOracle
- Oracle 12.2 OJVM安裝OracleJVM