说明:数据库环境为Oracle11.2.0.4.0双节点RAC,升级到11.2.0.4的最新版本
准备升级包:p6880880_112000_Linux-x86-64.zip
p23615403_112040_Linux-x86-64.zip
一、查看当前版本更新情况
SQL> select * from dba_registry_history;
ACTION_TIME ACTION NAMESPACE VERSION ID BUNDLE_SERIES COMMENTS
------------------------------ ---------- ------------------------------ ------------------------------ ---------- ------------------------------ ---------------------
24-AUG-13 12.03.45.119862 PM APPLY SERVER 11.2.0.4 0 PSU Patchset 11.2.0.2.0
07-JUN-16 08.16.23.118433 PM APPLY SERVER 11.2.0.4 0 PSU Patchset 11.2.0.2.0
二、升级OPatch(节点1和2分别做下面的操作)
1、查看当前OPatch版本
[grid@rac1 ~]$ /u01/app/11.2.0/grid/OPatch/opatch version
OPatch Version: 11.2.0.3.4
OPatch succeeded.
2、升级OPatch
[root@rac1 ~]# cd /tmp/
[root@rac1 tmp]# unzip p6880880_112000_Linux-x86-64.zip
[root@rac1 tmp]# mv /u01/app/11.2.0/grid/OPatch /u01/app/11.2.0/grid/OPatch_bak
[root@rac1 tmp]# cp -rp /tmp/OPatch /u01/app/11.2.0/grid/
[root@rac1 tmp]# chown -R grid:oinstall /u01/app/11.2.0/grid/OPatch
[root@rac1 tmp]# mv /u01/app/oracle/product/11.2.0/db_1/OPatch /u01/app/oracle/product/11.2.0/db_1/OPatch_bak
[root@rac1 tmp]# cp -rp /tmp/OPatch /u01/app/oracle/product/11.2.0/db_1/
[root@rac1 tmp]# chown -R oracle:oinstall /u01/app/oracle/product/11.2.0/db_1/OPatch
3、验证升级
[grid@rac1 ~]$ /u01/app/11.2.0/grid/OPatch/opatch version
OPatch Version: 11.2.0.3.12
OPatch succeeded.
[oracle@rac1 ~]$ /u01/app/oracle/product/11.2.0/db_1/OPatch/opatch version
OPatch Version: 11.2.0.3.12
OPatch succeeded.
三、生成ocm文件(节点1和2分别做下面的操作)
[grid@rac1 ~]$ cd /tmp/
[grid@rac1 tmp]$ /u01/app/11.2.0/grid/OPatch/ocm/bin/emocmrsp
OCM Installation Response Generator 10.3.7.0.0 - Production
Copyright (c) 2005, 2012, Oracle and/or its affiliates. All rights reserved.
Provide your email address to be informed of security issues, install and
initiate Oracle Configuration Manager. Easier for you if you use your My
Oracle Support Email address/User Name.
Visit http://www.oracle.com/support/policies.html for details.
Email address/User Name:
You have not provided an email address for notification of security issues.
Do you wish to remain uninformed of security issues ([Y]es, [N]o) [N]: y
The OCM configuration response file (ocm.rsp) was successfully created.
[grid@rac1 tmp]$ chmod 777 ocm.rsp
[grid@rac1 tmp]$ ll ocm.rsp
-rwxrwxrwx 1 grid oinstall 621 Sep 1 11:32 ocm.rsp
四、升级database和grid软件(节点1和2分别做下面的操作)
1、解压升级包
[root@rac1 tmp]# mkdir 23615403
[root@rac1 tmp]# unzip p23615403_112040_Linux-x86-64.zip -d 23615403
[root@rac1 tmp]# chmod -R 777 23615403
2、开始升级
[root@rac1 ~]# /u01/app/11.2.0/grid/OPatch/opatch auto /tmp/23615403/ -ocmrf /tmp/ocm.rsp
Executing /u01/app/11.2.0/grid/perl/bin/perl /u01/app/11.2.0/grid/OPatch/crs/patch11203.pl -patchdir /tmp -patchn 23615403 -ocmrf /tmp/ocm.rsp -paramfile /u01/app/11.2.0/grid/crs/install/crsconfig_params
This is the main log file: /u01/app/11.2.0/grid/cfgtoollogs/opatchauto2016-09-01_13-48-42.log
This file will show your detected configuration and all the steps that opatchauto attempted to do on your system:
/u01/app/11.2.0/grid/cfgtoollogs/opatchauto2016-09-01_13-48-42.report.log
2016-09-01 13:48:42: Starting Clusterware Patch Setup
Using configuration parameter file: /u01/app/11.2.0/grid/crs/install/crsconfig_params
Stopping RAC /u01/app/oracle/product/11.2.0/db_1 ...
Stopped RAC /u01/app/oracle/product/11.2.0/db_1 successfully
patch /tmp/23615403/23054359 apply successful for home /u01/app/oracle/product/11.2.0/db_1
patch /tmp/23615403/23054319/custom/server/23054319 apply successful for home /u01/app/oracle/product/11.2.0/db_1
patch /tmp/23615403/23177551 apply successful for home /u01/app/oracle/product/11.2.0/db_1
Stopping CRS...
Stopped CRS successfully
patch /tmp/23615403/23054359 apply successful for home /u01/app/11.2.0/grid
patch /tmp/23615403/23054319 apply successful for home /u01/app/11.2.0/grid
patch /tmp/23615403/22502505 apply successful for home /u01/app/11.2.0/grid
Starting CRS...
Installing Trace File Analyzer
CRS-4123: Oracle High Availability Services has been started.
Starting RAC /u01/app/oracle/product/11.2.0/db_1 ...
Started RAC /u01/app/oracle/product/11.2.0/db_1 successfully
opatch auto succeeded.
3、验证升级情况
[grid@rac1 ~]$ /u01/app/11.2.0/grid/OPatch/opatch lspatches
22502505;ACFS Patch Set Update : 11.2.0.4.160419 (22502505)
23054319;OCW Patch Set Update : 11.2.0.4.160719 (23054319)
23054359;Database Patch Set Update : 11.2.0.4.160719 (23054359)
OPatch succeeded.
[oracle@rac1 ~]$ /u01/app/oracle/product/11.2.0/db_1/OPatch/opatch lspatches
23177551;OJVM PATCH SET UPDATE 11.2.0.4.160719
23054319;OCW Patch Set Update : 11.2.0.4.160719 (23054319)
23054359;Database Patch Set Update : 11.2.0.4.160719 (23054359)
OPatch succeeded.
五、升级数据库数据字典(只需要在其中一个节点上执行)
SQL> select instance_name,status from gv$instance;
INSTANCE_NAME STATUS
---------------- ------------
eisoo1 OPEN
eisoo2 OPEN
SQL> @?/rdbms/admin/catbundle.sql psu apply
SQL> select * from dba_registry_history;
ACTION_TIME ACTION NAMESPACE VERSION ID BUNDLE_SERIES COMMENTS
------------------------------ -------------------- ------------------------------ ------------------------------ ---------- ------------------------------ ------------------------------
24-AUG-13 12.03.45.119862 PM APPLY SERVER 11.2.0.4 0 PSU Patchset 11.2.0.2.0
07-JUN-16 08.16.23.118433 PM APPLY SERVER 11.2.0.4 0 PSU Patchset 11.2.0.2.0
01-SEP-16 03.08.44.107705 PM jvmpsu.sql SERVER 11.2.0.4.160719OJVMPSU 0 RAN jvmpsu.sql
01-SEP-16 03.10.20.906687 PM APPLY SERVER 11.2.0.4 160719 PSU PSU 11.2.0.4.160719
准备升级包:p6880880_112000_Linux-x86-64.zip
p23615403_112040_Linux-x86-64.zip
一、查看当前版本更新情况
SQL> select * from dba_registry_history;
ACTION_TIME ACTION NAMESPACE VERSION ID BUNDLE_SERIES COMMENTS
------------------------------ ---------- ------------------------------ ------------------------------ ---------- ------------------------------ ---------------------
24-AUG-13 12.03.45.119862 PM APPLY SERVER 11.2.0.4 0 PSU Patchset 11.2.0.2.0
07-JUN-16 08.16.23.118433 PM APPLY SERVER 11.2.0.4 0 PSU Patchset 11.2.0.2.0
二、升级OPatch(节点1和2分别做下面的操作)
1、查看当前OPatch版本
[grid@rac1 ~]$ /u01/app/11.2.0/grid/OPatch/opatch version
OPatch Version: 11.2.0.3.4
OPatch succeeded.
2、升级OPatch
[root@rac1 ~]# cd /tmp/
[root@rac1 tmp]# unzip p6880880_112000_Linux-x86-64.zip
[root@rac1 tmp]# mv /u01/app/11.2.0/grid/OPatch /u01/app/11.2.0/grid/OPatch_bak
[root@rac1 tmp]# cp -rp /tmp/OPatch /u01/app/11.2.0/grid/
[root@rac1 tmp]# chown -R grid:oinstall /u01/app/11.2.0/grid/OPatch
[root@rac1 tmp]# mv /u01/app/oracle/product/11.2.0/db_1/OPatch /u01/app/oracle/product/11.2.0/db_1/OPatch_bak
[root@rac1 tmp]# cp -rp /tmp/OPatch /u01/app/oracle/product/11.2.0/db_1/
[root@rac1 tmp]# chown -R oracle:oinstall /u01/app/oracle/product/11.2.0/db_1/OPatch
3、验证升级
[grid@rac1 ~]$ /u01/app/11.2.0/grid/OPatch/opatch version
OPatch Version: 11.2.0.3.12
OPatch succeeded.
[oracle@rac1 ~]$ /u01/app/oracle/product/11.2.0/db_1/OPatch/opatch version
OPatch Version: 11.2.0.3.12
OPatch succeeded.
三、生成ocm文件(节点1和2分别做下面的操作)
[grid@rac1 ~]$ cd /tmp/
[grid@rac1 tmp]$ /u01/app/11.2.0/grid/OPatch/ocm/bin/emocmrsp
OCM Installation Response Generator 10.3.7.0.0 - Production
Copyright (c) 2005, 2012, Oracle and/or its affiliates. All rights reserved.
Provide your email address to be informed of security issues, install and
initiate Oracle Configuration Manager. Easier for you if you use your My
Oracle Support Email address/User Name.
Visit http://www.oracle.com/support/policies.html for details.
Email address/User Name:
You have not provided an email address for notification of security issues.
Do you wish to remain uninformed of security issues ([Y]es, [N]o) [N]: y
The OCM configuration response file (ocm.rsp) was successfully created.
[grid@rac1 tmp]$ chmod 777 ocm.rsp
[grid@rac1 tmp]$ ll ocm.rsp
-rwxrwxrwx 1 grid oinstall 621 Sep 1 11:32 ocm.rsp
四、升级database和grid软件(节点1和2分别做下面的操作)
1、解压升级包
[root@rac1 tmp]# mkdir 23615403
[root@rac1 tmp]# unzip p23615403_112040_Linux-x86-64.zip -d 23615403
[root@rac1 tmp]# chmod -R 777 23615403
2、开始升级
[root@rac1 ~]# /u01/app/11.2.0/grid/OPatch/opatch auto /tmp/23615403/ -ocmrf /tmp/ocm.rsp
Executing /u01/app/11.2.0/grid/perl/bin/perl /u01/app/11.2.0/grid/OPatch/crs/patch11203.pl -patchdir /tmp -patchn 23615403 -ocmrf /tmp/ocm.rsp -paramfile /u01/app/11.2.0/grid/crs/install/crsconfig_params
This is the main log file: /u01/app/11.2.0/grid/cfgtoollogs/opatchauto2016-09-01_13-48-42.log
This file will show your detected configuration and all the steps that opatchauto attempted to do on your system:
/u01/app/11.2.0/grid/cfgtoollogs/opatchauto2016-09-01_13-48-42.report.log
2016-09-01 13:48:42: Starting Clusterware Patch Setup
Using configuration parameter file: /u01/app/11.2.0/grid/crs/install/crsconfig_params
Stopping RAC /u01/app/oracle/product/11.2.0/db_1 ...
Stopped RAC /u01/app/oracle/product/11.2.0/db_1 successfully
patch /tmp/23615403/23054359 apply successful for home /u01/app/oracle/product/11.2.0/db_1
patch /tmp/23615403/23054319/custom/server/23054319 apply successful for home /u01/app/oracle/product/11.2.0/db_1
patch /tmp/23615403/23177551 apply successful for home /u01/app/oracle/product/11.2.0/db_1
Stopping CRS...
Stopped CRS successfully
patch /tmp/23615403/23054359 apply successful for home /u01/app/11.2.0/grid
patch /tmp/23615403/23054319 apply successful for home /u01/app/11.2.0/grid
patch /tmp/23615403/22502505 apply successful for home /u01/app/11.2.0/grid
Starting CRS...
Installing Trace File Analyzer
CRS-4123: Oracle High Availability Services has been started.
Starting RAC /u01/app/oracle/product/11.2.0/db_1 ...
Started RAC /u01/app/oracle/product/11.2.0/db_1 successfully
opatch auto succeeded.
3、验证升级情况
[grid@rac1 ~]$ /u01/app/11.2.0/grid/OPatch/opatch lspatches
22502505;ACFS Patch Set Update : 11.2.0.4.160419 (22502505)
23054319;OCW Patch Set Update : 11.2.0.4.160719 (23054319)
23054359;Database Patch Set Update : 11.2.0.4.160719 (23054359)
OPatch succeeded.
[oracle@rac1 ~]$ /u01/app/oracle/product/11.2.0/db_1/OPatch/opatch lspatches
23177551;OJVM PATCH SET UPDATE 11.2.0.4.160719
23054319;OCW Patch Set Update : 11.2.0.4.160719 (23054319)
23054359;Database Patch Set Update : 11.2.0.4.160719 (23054359)
OPatch succeeded.
五、升级数据库数据字典(只需要在其中一个节点上执行)
SQL> select instance_name,status from gv$instance;
INSTANCE_NAME STATUS
---------------- ------------
eisoo1 OPEN
eisoo2 OPEN
SQL> @?/rdbms/admin/catbundle.sql psu apply
SQL> select * from dba_registry_history;
ACTION_TIME ACTION NAMESPACE VERSION ID BUNDLE_SERIES COMMENTS
------------------------------ -------------------- ------------------------------ ------------------------------ ---------- ------------------------------ ------------------------------
24-AUG-13 12.03.45.119862 PM APPLY SERVER 11.2.0.4 0 PSU Patchset 11.2.0.2.0
07-JUN-16 08.16.23.118433 PM APPLY SERVER 11.2.0.4 0 PSU Patchset 11.2.0.2.0
01-SEP-16 03.08.44.107705 PM jvmpsu.sql SERVER 11.2.0.4.160719OJVMPSU 0 RAN jvmpsu.sql
01-SEP-16 03.10.20.906687 PM APPLY SERVER 11.2.0.4 160719 PSU PSU 11.2.0.4.160719
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/30373263/viewspace-2124358/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/30373263/viewspace-2124358/