Clone Oracle Home (10g2)

Source: Internet
Author: User

Clone an existing Oracle Home without the trouble of installing the new oracle10g software. If the original Oracle Home has installed a patch, you can skip patch.

1. Prepare for installation on the target host 172.19.111.37
1. Add a group and a user (the directory structure of the clone host is the same)
# Groupadd oinstall
# Groupadd dba
# Userdel oracle10
# Useradd-g oinstall-G dba-d/opt/oracle/oracle10-m-s/bin/ksh oracle10
# Passwd-r files oracle10
2. Create a directory
# Mkdir/opt/oracle/oradata/oracle10_data (store data files for future database creation)
# Chown oracle10: oinstall/opt/oracle/oradata/oracle10_data
# Chmod 755/opt/oracle/oradata/oracle10_data
# Mkdir/opt/oracle/oradata/flash_recovery_area)
# Chown oracle10: oinstall/opt/oracle/oradata/flash_recovery_area
# Chmod 755/opt/oracle/oradata/flash_recovery_area
3. Modify the oratab File Permission
# More/var/opt/oracle/oratab
# Chown oracle10: oinstall/var/opt/oracle/oratab
# Chmod 755/var/opt/oracle/oratab
4. Stop the existing oracle listening process.
# Su-oracle
$ Lsnrctl stop
$ Sqlplus '/as sysdba'
SQL> shutdown immediate

2. Stop and clone all processes related to ORACLE_HOME on host 172.19.111.38
$ Emctl stop dbconsole (stop Database Control)
$ Lsnrctl stop (stop Net Listener)
$ Isqlplusctl stop (stop iSQL * PLUS)
$ Searchctl stop (stop Ultra Search)

3. zip the content in the cloned host ORACLE_HOME directory
$ Cd $ ORACLE_HOME /../
$ Zip-r db_1.zip/opt/oracle/oracle10/app/product/10.2.0/Db_1
Note: Do not package the admin, flash_recovery_area, and oradata directories. Clone them and generate them again.

4. Copy the zip package and. profile file to the target host.
$ Ftp 172.19.111.37
Ftp> user oracle10 oracle10
Upload db_1.zip and. profile

5. decompress the zip package to the target host.
$ .. Profile
$ Unzip-d/db_1.zip

6. Go to the decompressed ORACLE_HOME directory and delete all the $ ORACLE_HOME/network/admin/*. ora files.
$ Cd $ ORACLE_HOME/network/admin
$ Rm *. ora

7. Start OUI in clone mode (XBrower login is not required). ORACLE_HOME_NAME must be unique.
$ ORACLE_HOME/oui/bin/runInstaller-silent-clone ORACLE_HOME = "/opt/oracle/oracle10/app/product/10.2.0/Db_1" ORACLE_HOME_NAME = "db_1"

8. Create a database (use XBrower to log on)
$ Cd $ ORACLE_HOME/bin
$./Dbca

9. Network Configuration Assistant (use XBrower to log on)
$ Cd $ ORACLE_HOME/bin
$./Netca
Listener configuration and Local net service name configuration (assuming the configuration is orcl10)

10. Test
$ Ps-ef | grep ora _ (check whether oracle10g is started)
$ Lsnrctl status (check whether the listener is started)
$ Tnsping orcl10 (check whether the configured network service name is correct)
$ Emctl start dbconsole (start database console)
$ Isqlplusctl start (start isqlplus)
Go to http: // 172.19.111.37: 5500/em/to view the database status.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.