[Oracle] upgrades RAC10.2.0.1 to 10.2.0.5
Environment:
OS: OEL5.6
RAC: 10.2.0.1.0
Related environment variables:
CRS_HOME/u01/app/oracle/product/10.2.0/db_1
ORACLE_HOME/u01/app/oracle/product/10.2.0/db_2
Crs_stop-all close all resources
[Oracle @ rac1 ~] $ Crs_stat-t
Name Type Target State Host
------------------------------------------------------------
Ora... B1.inst application OFFLINE
Ora... B2.inst application OFFLINE
Ora. RACDB. db application OFFLINE
Ora... SM1.asm application OFFLINE
Ora... C1.lsnr application OFFLINE
Ora. rac1.gsd application OFFLINE
Ora. rac1.ons application OFFLINE
Ora. rac1.vip application OFFLINE
Ora... SM2.asm application OFFLINE
Ora... C2.lsnr application OFFLINE
Ora. rac2.gsd application OFFLINE
Ora. rac2.ons application OFFLINE
Ora. rac2.vip application OFFLINE
1. decompress the patch package required for upgrade: p8202632_10205_LINUX.zip
[Oracle @ rac1 soft] $ unzip p8202632_10205_LINUX.zip
2. Start upgrading cluster Software
[Oracle @ rac1 Disk1] $./runInstaller
Then run the script as required:
Rac1 Node
[Root @ rac1 ~] # Cd/u01/app/oracle/product/10.2.0/db_1/bin/
[Root @ rac1 bin] #./crsctl stop crs
Stopping resources.
Successfully stopped CRS resources
Stopping CSSD.
Shutting down CSS daemon.
Shutdown request successfully issued.
[Root @ rac1 bin] #/u01/app/oracle/product/10.2.0/db_1/install/root102.sh
Creating pre-patch directory for saving pre-patch clusterware files
Completed patching clusterware files to/u01/app/oracle/product/10.2.0/db_1
Relinking some shared libraries.
Relinking of patched files is complete.
WARNING: directory '/u01/app/oracle/product/10.2.0' is not owned by root
WARNING: directory '/u01/app/oracle/product' is not owned by root
WARNING: directory '/u01/app/oracle' is not owned by root
WARNING: directory '/u01/app' is not owned by root
WARNING: directory '/u01' is not owned by root
Preparing to recopy patched init and RC scripts.
Recopying init and RC scripts.
Startup will be queued to init within 30 seconds.
Starting up the CRS daemons.
Waiting for the patched CRS daemons to start.
This may take a while on some systems.
.
10205 patch successfully applied.
Clscfg: EXISTING configuration version 3 detected.
Clscfg: version 3 is 10G Release 2.
Successfully deleted 1 values from OCR.
Successfully deleted 1 keys from OCR.
Successfully accumulated necessary OCR keys.
Using ports: CSS = 49895 CRS = 49896 EVMC = 49898 and EVMR = 49897.
Node <nodenumber>: <nodename> <private interconnect name>
Node 1: rac1 rac1-priv rac1
Creating OCR keys for user 'root', privgrp 'root '..
Operation successful.
Clscfg-upgrade completed successfully
Creating '/u01/app/oracle/product/10.2.0/db_1/install/paramfile. crs' with data used for CRS configuration
Setting CRS configuration values in/u01/app/oracle/product/10.2.0/db_1/install/paramfile. crs
Rac2 node:
[Root @ rac2 ~] # Cd/u01/app/oracle/product/10.2.0/db_1/bin/
[Root @ rac2 bin] #./crsctl stop crs
Stopping resources.
Successfully stopped CRS resources
Stopping CSSD.
Shutting down CSS daemon.
Shutdown request successfully issued.
[Root @ rac2 bin] #/u01/app/oracle/product/10.2.0/db_1/install/root102.sh
Creating pre-patch directory for saving pre-patch clusterware files
Completed patching clusterware files to/u01/app/oracle/product/10.2.0/db_1
Relinking some shared libraries.
Relinking of patched files is complete.
WARNING: directory '/u01/app/oracle/product/10.2.0' is not owned by root
WARNING: directory '/u01/app/oracle/product' is not owned by root
WARNING: directory '/u01/app/oracle' is not owned by root
WARNING: directory '/u01/app' is not owned by root
WARNING: directory '/u01' is not owned by root
Preparing to recopy patched init and RC scripts.
Recopying init and RC scripts.
Startup will be queued to init within 30 seconds.
Starting up the CRS daemons.
Waiting for the patched CRS daemons to start.
This may take a while on some systems.
.
10205 patch successfully applied.
Clscfg: EXISTING configuration version 3 detected.
Clscfg: version 3 is 10G Release 2.
Successfully deleted 1 values from OCR.
Successfully deleted 1 keys from OCR.
Successfully accumulated necessary OCR keys.
Using ports: CSS = 49895 CRS = 49896 EVMC = 49898 and EVMR = 49897.
Node <nodenumber>: <nodename> <private interconnect name>
Node 2: rac2 rac2-priv rac2
Creating OCR keys for user 'root', privgrp 'root '..
Operation successful.
Clscfg-upgrade completed successfully
Creating '/u01/app/oracle/product/10.2.0/db_1/install/paramfile. crs' with data used for CRS configuration
Setting CRS configuration values in/u01/app/oracle/product/10.2.0/db_1/install/paramfile. crs
Up to now, the Clusterware software has been upgraded
[Oracle @ rac1 Disk1] $ crs_stat-t
Name Type Target State Host
------------------------------------------------------------
Ora... B1.inst application ONLINE rac1
Ora... B2.inst application ONLINE rac2
Ora. RACDB. db application ONLINE rac1
Ora... SM1.asm application ONLINE rac1
Ora... C1.lsnr application ONLINE rac1
Ora. rac1.gsd application ONLINE rac1
Ora. rac1.ons application ONLINE rac1
Ora. rac1.vip application ONLINE rac1
Ora... SM2.asm application ONLINE rac2
Ora... C2.lsnr application ONLINE rac2
Ora. rac2.gsd application ONLINE rac2
Ora. rac2.ons application ONLINE rac2
Ora. rac2.vip application ONLINE rac2
Upgrade the database software now:
Before upgrading the database software, we need to disable various CRS services.
[Oracle @ rac1 Disk1] $ srvctl stop db-d RACDB-o immediate
[Oracle @ rac1 Disk1] $ srvctl stop asm-n rac1-o immediate
[Oracle @ rac1 Disk1] $ srvctl stop asm-n rac2-o immediate
[Oracle @ rac1 Disk1] $ srvctl stop listener-n rac1
[Oracle @ rac1 Disk1] $ srvctl stop listener-n rac2
[Oracle @ rac1 Disk1] $ crs_stop-all
[Root @ rac1 ~] # Cd/u01/app/oracle/product/10.2.0/db_1/bin/
[Root @ rac1 bin] #./crsctl stop crs
Rac2 node:
[Root @ rac2 ~] # Cd/u01/app/oracle/product/10.2.0/db_1/bin/
[Root @ rac2 bin] #./crsctl stop crs
Run the patch package (the same as the patch package used to upgrade the cluster software)
[Oracle @ rac1 Disk1] $./runInstaller
This time, select the ORACLE_HOME directory.
Rac1 node:
[Root @ rac1 ~] #/U01/app/oracle/product/10.2.0/db_2/root. sh
Running Oracle 10g root. sh script...
The following environment variables are set:
ORACLE_OWNER = oracle
ORACLE_HOME =/u01/app/oracle/product/10.2.0/db_2
Enter the full pathname of the local bin directory: [/usr/local/bin]:
The file "dbhome" already exists in/usr/local/bin. Overwrite it? (Y/n)
[N]:
The file "oraenv" already exists in/usr/local/bin. Overwrite it? (Y/n)
[N]:
The file "coraenv" already exists in/usr/local/bin. Overwrite it? (Y/n)
[N]:
Entries will be added to the/etc/oratab file as needed
Database Configuration Assistant when a database is created
Finished running generic part of root. sh script.
Now product-specific root actions will be saved med.
Rac2 node:
[Root @ rac2 ~] #/U01/app/oracle/product/10.2.0/db_2/root. sh
Running Oracle 10g root. sh script...
The following environment variables are set:
ORACLE_OWNER = oracle
ORACLE_HOME =/u01/app/oracle/product/10.2.0/db_2
Enter the full pathname of the local bin directory: [/usr/local/bin]:
The file "dbhome" already exists in/usr/local/bin. Overwrite it? (Y/n)
[N]:
The file "oraenv" already exists in/usr/local/bin. Overwrite it? (Y/n)
[N]:
The file "coraenv" already exists in/usr/local/bin. Overwrite it? (Y/n)
[N]:
Entries will be added to the/etc/oratab file as needed
Database Configuration Assistant when a database is created
Finished running generic part of root. sh script.
Now product-specific root actions will be saved med.
Upgrade the database after the database software is upgraded:
After the version upgrade, the attributes of some objects in the dictionary table need to be changed in the new version. Therefore, you need to upgrade the database and update the database dictionary.
Rac1 node:
[Root @ rac1 ~] # Cd/u01/app/oracle/product/10.2.0/db_1/bin/
[Root @ rac1 bin] #./crsctl start crs
Attempting to start CRS stack
The CRS stack will be started shortly
Rac2 node:
[Root @ rac1 ~] # Cd/u01/app/oracle/product/10.2.0/db_1/bin/
[Root @ rac1 bin] #./crsctl start crs
Attempting to start CRS stack
The CRS stack will be started shortly
[Oracle @ rac1 ~] $ Crs_stat-t
Name Type Target State Host
------------------------------------------------------------
Ora... B1.inst application ONLINE OFFLINE
Ora... B2.inst application ONLINE OFFLINE
Ora. RACDB. db application ONLINE OFFLINE
Ora... SM1.asm application ONLINE rac1
Ora... C1.lsnr application ONLINE rac1
Ora. rac1.gsd application ONLINE rac1
Ora. rac1.ons application ONLINE rac1
Ora. rac1.vip application ONLINE rac1
Ora... SM2.asm application ONLINE rac2
Ora... C2.lsnr application ONLINE rac2
Ora. rac2.gsd application ONLINE rac2
Ora. rac2.ons application ONLINE rac2
Ora. rac2.vip application ONLINE rac2
[Oracle @ rac1 ~] $ Dbua
Now the upgrade is complete:
[Oracle @ rac1 ~] $ Crs_stat-t
Name Type Target State Host
------------------------------------------------------------
Ora... B1.inst application ONLINE rac1
Ora... B2.inst application ONLINE rac2
Ora. RACDB. db application ONLINE rac2
Ora... SM1.asm application ONLINE rac1
Ora... C1.lsnr application ONLINE rac1
Ora. rac1.gsd application ONLINE rac1
Ora. rac1.ons application ONLINE rac1
Ora. rac1.vip application ONLINE rac1
Ora... SM2.asm application ONLINE rac2
Ora... C2.lsnr application ONLINE rac2
Ora. rac2.gsd application ONLINE rac2
Ora. rac2.ons application ONLINE rac2
Ora. rac2.vip application ONLINE rac2
SQL> select comp_name, version, status from dba_registry;
COMP_NAME VERSION STATUS
---------------------------------------------------------------------------------
Oracle Enterprise Manager 10.2.0.5.0 VALID
Spatial 10.2.0.5.0 VALID
Oracle interMedia 10.2.0.5.0 VALID
OLAP Catalog 10.2.0.5.0 VALID
Oracle XML Database 10.2.0.5.0 VALID
Oracle Text 10.2.0.5.0 VALID
Oracle Expression Filter 10.2.0.5.0 VALID
Oracle Rule Manager 10.2.0.5.0 VALID
Oracle Workspace Manager 10.2.0.5.0 VALID
Oracle Data Mining 10.2.0.5.0 VALID
Oracle Database Catalog Views 10.2.0.5.0 VALID
Oracle Database Packages and Types 10.2.0.5.0 VALID
JServer JAVA Virtual Machine 10.2.0.5.0 VALID
Oracle XDK 10.2.0.5.0 VALID
Oracle Database Java Packages 10.2.0.5.0 VALID
OLAP Analytic Workspace 10.2.0.5.0 VALID
Oracle olap api 10.2.0.5.0 VALID
Oracle Real Application Clusters 10.2.0.5.0 VALID
18 rows selected.
SQL> select * from v $ version;
BANNER
----------------------------------------------------------------
Oracle Database 10g Enterprise Edition Release 10.2.0.5.0-Prod
PL/SQL Release 10.2.0.5.0-Production
CORE 10.2.0.5.0 Production
TNS for Linux: Version 10.2.0.5.0-Production
NLSRTL Version 10.2.0.5.0-Production