测试环境ORACLE 11g单实例打11.2.0.3.13 p19769496 PSU操作流程

2024-05-10 05:48

本文主要是介绍测试环境ORACLE 11g单实例打11.2.0.3.13 p19769496 PSU操作流程,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!


1.停止监听  
[oracle@localhost admin]$ lsnrctl stop LISTENER


LSNRCTL for Linux: Version 11.2.0.3.0 - Production on 25-JAN-2015 22:50:17


Copyright (c) 1991, 2011, Oracle.  All rights reserved.


Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost)(PORT=1521)))
The command completed successfully 


2、检查数据库是否还存在连接。
[oracle@localhost ~]$ps -ef |grep LOCAL=NO  
oracle    4377  2979  1 22:48 pts/1    00:00:00 grep LOCAL=NO


3、切换日志,关闭数据库。
SQL> alter system checkpoint;


System altered.


SQL> alter system switch logfile;


System altered.


SQL> shutdown immediate;
Database closed.
Database dismounted.
ORACLE instance shut down.


4、备份ORACLE_HOME目录
cp -R <ORACLE_HOME> <ORACLE_HOME_BAK>


5.进入19769496 psu 解压目录,确保19769496权限为oracle:oinstall  
[oracle@localhost patch]$ cd 19769496/
[oracle@localhost 19769496]$ ll
total 112
drwxr-xr-x. 4 oracle oinstall  4096 Dec  9 22:41 13343438
drwxrwxr-x. 4 oracle oinstall  4096 Dec  9 22:41 13696216
drwxrwxr-x. 4 oracle oinstall  4096 Dec  9 22:41 13923374
drwxrwxr-x. 4 oracle oinstall  4096 Dec  9 22:41 14275605
drwxrwxr-x. 5 oracle oinstall  4096 Dec  9 22:41 14727310
drwxrwxr-x. 4 oracle oinstall  4096 Dec  9 22:41 16056266
drwxrwxr-x. 4 oracle oinstall  4096 Dec  9 22:41 16619892
drwxrwxr-x. 4 oracle oinstall  4096 Dec  9 22:41 16902043
drwxrwxr-x. 5 oracle oinstall  4096 Dec  9 22:41 17540582
drwxrwxr-x. 4 oracle oinstall  4096 Dec  9 22:41 18031683
drwxrwxr-x. 4 oracle oinstall  4096 Dec  9 22:41 18522512
drwxrwxr-x. 4 oracle oinstall  4096 Dec  9 22:41 19121548
drwxrwxr-x. 4 oracle oinstall  4096 Dec  9 22:41 19769496
-rw-rw-r--. 1 oracle oinstall 51692 Jan 17 08:30 README.html
-rw-r--r--. 1 oracle oinstall    21 Dec  9 22:41 README.txt
-rw-r--r--. 1 oracle oinstall  2872 Dec  9 22:42 patchmd.xml


6、检查OPATCH版本,如果版本过低需要到metalink下载最近的OPATCH psu号为为6880880。
OPatch Version: 11.2.0.1.7


OPatch succeeded.


7、下载最近的OPATCH psu号为为6880880,备份原先的OPatch目录,并解压到ORACLE_HOME目录下。
[oracle@localhost ~]$cd $ORACLE_HOME
[oracle@localhost db_1]$ mv OPatch/ OPatch_bak/
[oracle@localhost db_1]$ unzip p6880880_112000_Linux-x86-64.zip


8、再次检查OPATCH版本。
OPatch Version: 11.2.0.3.6


OPatch succeeded.


9、检查是否有与19769496有冲突的PSU。
[oracle@localhost ~]$ cd /home/oracle/patch/19769496/
[oracle@localhost 19769496]$ $ORACLE_HOME/OPatch/opatch prereq CheckConflictAgainstOHWithDetail -ph ./ 
Oracle Interim Patch Installer version 11.2.0.3.6
Copyright (c) 2013, Oracle Corporation.  All rights reserved.


PREREQ session


Oracle Home       : /opt/app/oracle/product/11.2.0/db_1
Central Inventory : /opt/app/oraInventory
   from           : /opt/app/oracle/product/11.2.0/db_1/oraInst.loc
OPatch version    : 11.2.0.3.6
OUI version       : 11.2.0.3.0
Log file location : /opt/app/oracle/product/11.2.0/db_1/cfgtoollogs/opatch/opatch2015-01-25_22-25-34PM_1.log


Invoking prereq "checkconflictagainstohwithdetail"


Prereq "checkConflictAgainstOHWithDetail" passed.


OPatch succeeded.


10、安装补丁号为19769496的PSU。
[oracle@localhost ~]$ cd /home/oracle/patch/19769496/
[oracle@localhost 19769496]$ /opt/app/oracle/product/11.2.0/db_1/OPatch/opatch apply
Oracle Interim Patch Installer version 11.2.0.3.6
Copyright (c) 2013, Oracle Corporation.  All rights reserved.




Oracle Home       : /opt/app/oracle/product/11.2.0/db_1
Central Inventory : /opt/app/oraInventory
   from           : /opt/app/oracle/product/11.2.0/db_1/oraInst.loc
OPatch version    : 11.2.0.3.6
OUI version       : 11.2.0.3.0
Log file location : /opt/app/oracle/product/11.2.0/db_1/cfgtoollogs/opatch/opatch2015-01-25_19-18-41PM_1.log


Verifying environment and performing prerequisite checks...
OPatch continues with these patches:   13343438  13696216  13923374  14275605  14727310  16056266  16619892  16902043  17540582  18031683  18522512  19121548  19769496  


Do you want to proceed? [y|n]
y
User Responded with: Y
All checks passed.
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






Please shutdown Oracle instances running out of this ORACLE_HOME on the local system.
(Oracle Home = '/opt/app/oracle/product/11.2.0/db_1')




Is the local system ready for patching? [y|n]
y
User Responded with: Y
Backing up files...
Applying sub-patch '13343438' to OH '/opt/app/oracle/product/11.2.0/db_1'


Patching component oracle.rdbms.rsf, 11.2.0.3.0...


Patching component oracle.rdbms, 11.2.0.3.0...


Patching component oracle.rdbms.dbscripts, 11.2.0.3.0...


Verifying the update...
Applying sub-patch '13696216' to OH '/opt/app/oracle/product/11.2.0/db_1'


Patching component oracle.rdbms.rsf, 11.2.0.3.0...


Patching component oracle.rdbms, 11.2.0.3.0...


Patching component oracle.sdo.locator, 11.2.0.3.0...


Patching component oracle.sysman.console.db, 11.2.0.3.0...


Patching component oracle.sysman.oms.core, 10.2.0.4.4...


Verifying the update...
Applying sub-patch '13923374' to OH '/opt/app/oracle/product/11.2.0/db_1'
ApplySession: Optional component(s) [ oracle.network.cman, 11.2.0.3.0 ]  not present in the Oracle Home or a higher version is found.


Patching component oracle.rdbms.rsf, 11.2.0.3.0...


Patching component oracle.rdbms, 11.2.0.3.0...


Patching component oracle.rdbms.dbscripts, 11.2.0.3.0...


Patching component oracle.network.rsf, 11.2.0.3.0...


Patching component oracle.network.listener, 11.2.0.3.0...


Patching component oracle.sysman.console.db, 11.2.0.3.0...


Verifying the update...
Applying sub-patch '14275605' to OH '/opt/app/oracle/product/11.2.0/db_1'
ApplySession: Optional component(s) [ oracle.precomp.lang, 11.2.0.3.0 ]  not present in the Oracle Home or a higher version is found.


Patching component oracle.network.client, 11.2.0.3.0...


Patching component oracle.network.rsf, 11.2.0.3.0...


Patching component oracle.precomp.common, 11.2.0.3.0...


Patching component oracle.rdbms, 11.2.0.3.0...


Patching component oracle.rdbms.dbscripts, 11.2.0.3.0...


Patching component oracle.rdbms.rman, 11.2.0.3.0...


Patching component oracle.rdbms.rsf, 11.2.0.3.0...


Patching component oracle.rdbms.util, 11.2.0.3.0...


Verifying the update...
Applying sub-patch '14727310' to OH '/opt/app/oracle/product/11.2.0/db_1'


Patching component oracle.rdbms, 11.2.0.3.0...


Patching component oracle.rdbms.dbscripts, 11.2.0.3.0...


Patching component oracle.rdbms.rsf, 11.2.0.3.0...


Patching component oracle.sdo.locator, 11.2.0.3.0...


Patching component oracle.sysman.console.db, 11.2.0.3.0...


Patching component oracle.sysman.oms.core, 10.2.0.4.4...


Verifying the update...
Applying sub-patch '16056266' to OH '/opt/app/oracle/product/11.2.0/db_1'
ApplySession: Optional component(s) [ oracle.network.cman, 11.2.0.3.0 ]  not present in the Oracle Home or a higher version is found.


Patching component oracle.network.listener, 11.2.0.3.0...


Patching component oracle.network.rsf, 11.2.0.3.0...


Patching component oracle.ovm, 11.2.0.3.0...


Patching component oracle.rdbms, 11.2.0.3.0...


Patching component oracle.rdbms.rman, 11.2.0.3.0...


Patching component oracle.rdbms.rsf, 11.2.0.3.0...


Patching component oracle.sdo.locator, 11.2.0.3.0...


Patching component oracle.rdbms.deconfig, 11.2.0.3.0...


Verifying the update...
Applying sub-patch '16619892' to OH '/opt/app/oracle/product/11.2.0/db_1'
ApplySession: Optional component(s) [ oracle.precomp.lang, 11.2.0.3.0 ]  not present in the Oracle Home or a higher version is found.


Patching component oracle.marvel, 11.2.0.3.0...


Patching component oracle.precomp.common, 11.2.0.3.0...


Patching component oracle.rdbms, 11.2.0.3.0...


Patching component oracle.rdbms.rman, 11.2.0.3.0...


Patching component oracle.rdbms.rsf, 11.2.0.3.0...


Patching component oracle.sysman.agent, 10.2.0.4.3...


Patching component oracle.sysman.console.db, 11.2.0.3.0...


Patching component oracle.sysman.repository.core, 10.2.0.4.4...


Patching component oracle.xdk, 11.2.0.3.0...


Patching component oracle.xdk.parser.java, 11.2.0.3.0...


Patching component oracle.xdk.rsf, 11.2.0.3.0...


Verifying the update...
Applying sub-patch '16902043' to OH '/opt/app/oracle/product/11.2.0/db_1'
ApplySession: Optional component(s) [ oracle.idm.oid, 11.2.0.3.0 ]  not present in the Oracle Home or a higher version is found.


Patching component oracle.ldap.rsf, 11.2.0.3.0...


Patching component oracle.ldap.rsf.ic, 11.2.0.3.0...


Patching component oracle.owb.rsf, 11.2.0.3.0...


Patching component oracle.rdbms, 11.2.0.3.0...


Patching component oracle.rdbms.rsf, 11.2.0.3.0...


Patching component oracle.sysman.console.db, 11.2.0.3.0...


Verifying the update...
Applying sub-patch '17540582' to OH '/opt/app/oracle/product/11.2.0/db_1'
ApplySession: Optional component(s) [ oracle.precomp.lang, 11.2.0.3.0 ]  not present in the Oracle Home or a higher version is found.


Patching component oracle.rdbms, 11.2.0.3.0...


Patching component oracle.rdbms.rsf, 11.2.0.3.0...


Patching component oracle.sdo, 11.2.0.3.0...


Patching component oracle.ldap.rsf, 11.2.0.3.0...


Patching component oracle.precomp.common, 11.2.0.3.0...


Patching component oracle.ordim.client, 11.2.0.3.0...


Patching component oracle.rdbms.util, 11.2.0.3.0...


Patching component oracle.rdbms.dbscripts, 11.2.0.3.0...


Patching component oracle.sdo.locator, 11.2.0.3.0...


Patching component oracle.rdbms.rman, 11.2.0.3.0...


Patching component oracle.ordim.jai, 11.2.0.3.0...


Verifying the update...
Applying sub-patch '18031683' to OH '/opt/app/oracle/product/11.2.0/db_1'
ApplySession: Optional component(s) [ oracle.precomp.lang, 11.2.0.3.0 ]  not present in the Oracle Home or a higher version is found.


Patching component oracle.rdbms.rsf, 11.2.0.3.0...


Patching component oracle.rdbms, 11.2.0.3.0...


Patching component oracle.ldap.rsf, 11.2.0.3.0...


Patching component oracle.precomp.common, 11.2.0.3.0...


Patching component oracle.rdbms.rman, 11.2.0.3.0...


Patching component oracle.rdbms.util, 11.2.0.3.0...


Patching component oracle.rdbms.dbscripts, 11.2.0.3.0...


Verifying the update...
Applying sub-patch '18522512' to OH '/opt/app/oracle/product/11.2.0/db_1'


Patching component oracle.rdbms.rsf, 11.2.0.3.0...


Patching component oracle.rdbms, 11.2.0.3.0...


Patching component oracle.network.rsf, 11.2.0.3.0...


Patching component oracle.precomp.common, 11.2.0.3.0...


Patching component oracle.rdbms.rman, 11.2.0.3.0...


Patching component oracle.rdbms.dbscripts, 11.2.0.3.0...


Verifying the update...
Applying sub-patch '19121548' to OH '/opt/app/oracle/product/11.2.0/db_1'


Patching component oracle.sysman.console.db, 11.2.0.3.0...


Patching component oracle.rdbms.rsf, 11.2.0.3.0...


Patching component oracle.rdbms.rman, 11.2.0.3.0...


Patching component oracle.rdbms, 11.2.0.3.0...


Patching component oracle.rdbms.dbscripts, 11.2.0.3.0...


Patching component oracle.ordim.client, 11.2.0.3.0...


Patching component oracle.ordim.jai, 11.2.0.3.0...


Verifying the update...
Applying sub-patch '19769496' to OH '/opt/app/oracle/product/11.2.0/db_1'


Patching component oracle.sysman.agent, 10.2.0.4.3...


Patching component oracle.ovm, 11.2.0.3.0...


Patching component oracle.xdk, 11.2.0.3.0...


Patching component oracle.rdbms.util, 11.2.0.3.0...


Patching component oracle.rdbms, 11.2.0.3.0...


Patching component oracle.rdbms.dbscripts, 11.2.0.3.0...


Patching component oracle.xdk.parser.java, 11.2.0.3.0...


Patching component oracle.oraolap, 11.2.0.3.0...


Patching component oracle.rdbms.rsf, 11.2.0.3.0...


Patching component oracle.xdk.rsf, 11.2.0.3.0...


Verifying the update...


OPatch found the word "warning" in the stderr of the make command.
Please look at this stderr. You can re-run this make command.
Stderr output:
ins_precomp.mk:19: warning: overriding commands for target `pcscfg.cfg'
/opt/app/oracle/product/11.2.0/db_1/precomp/lib/env_precomp.mk:2160: warning: ignoring old commands for target `pcscfg.cfg'
/opt/app/oracle/product/11.2.0/db_1/precomp/lib/ins_precomp.mk:19: warning: overriding commands for target `pcscfg.cfg'
/opt/app/oracle/product/11.2.0/db_1/precomp/lib/env_precomp.mk:2160: warning: ignoring old commands for target `pcscfg.cfg'






OPatch found the word "warning" in the stderr of the make command.
Please look at this stderr. You can re-run this make command.
Stderr output:
ins_emagent.mk:113: warning: overriding commands for target `nmosudo'
ins_emagent.mk:52: warning: ignoring old commands for target `nmosudo'
/opt/app/oracle/product/11.2.0/db_1/sysman/lib/ins_emagent.mk:113: warning: overriding commands for target `nmosudo'
/opt/app/oracle/product/11.2.0/db_1/sysman/lib/ins_emagent.mk:52: warning: ignoring old commands for target `nmosudo'




Composite patch 19769496 successfully applied.
OPatch Session completed with warnings.
Log file location: /opt/app/oracle/product/11.2.0/db_1/cfgtoollogs/opatch/opatch2015-01-25_19-18-41PM_1.log


OPatch completed with warnings.


11、进入admin目录,执行catbundle.sql脚本更新数据字典。
[oracle@localhost ~]$ cd $ORACLE_HOME/rdbms/admin
[oracle@localhost admin]$ sqlplus '/as sysdba'


SQL*Plus: Release 11.2.0.3.0 Production on Sun Jan 25 22:01:32 2015


Copyright (c) 1982, 2011, Oracle.  All rights reserved.


Connected to an idle instance.


SQL> 
SQL> 
SQL> 
SQL> startup
ORACLE instance started.


Total System Global Area  780824576 bytes
Fixed Size    2232432 bytes
Variable Size  562040720 bytes
Database Buffers  213909504 bytes
Redo Buffers    2641920 bytes
Database mounted.
Database opened.
SQL> @catbundle.sql psu apply  


12、查询registry$history 来查看PSU级别。
SQL>select substr(action_time,1,30) action_time,   
    substr(id,1,8) id,   
    substr(action,1,10) action,   
    substr(version,1,8) version,   
    substr(comments,1,20) comments   
    from registry$history; 


ACTION_TIME ID  ACTION     VERSION  COMMENTS
---------------------------------------- ---------------- ---------- -------------------- ------------------------------
17-SEP-11 10.21.11.595816 AM 0  APPLY      11.2.0.3  Patchset 11.2.0.2.0
19-JAN-15 12.02.35.037223 AM 0  APPLY      11.2.0.3  Patchset 11.2.0.2.0
25-JAN-15 08.04.12.093341 PM 13  APPLY      11.2.0.3  PSU 11.2.0.3.13


13.执行完catbundle.sql后,会在$ORACLE_HOME/rdbms/admin目录下生成catbundle_PSU_<database SID>_APPLY.sql,catbundle_PSU_<database SID>_ROLLBACK.sql两个脚本。  
[oracle@localhost admin]$ cd $ORACLE_HOMErdbms/admin/
[oracle@localhost admin]$ ll catbundle_*
-rw-r-----. 1 oracle oinstall 2262 Jan 25 19:54 catbundle_PSU_ORCL_APPLY.sql
-rw-r-----. 1 oracle oinstall 2311 Jan 25 19:54 catbundle_PSU_ORCL_ROLLBACK.sql
  
catbundle_PSU_ORCL_ROLLBACK.sql用于回滚PSU时使用  

这篇关于测试环境ORACLE 11g单实例打11.2.0.3.13 p19769496 PSU操作流程的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!



http://www.chinasem.cn/article/975606

相关文章

Mysql表的简单操作(基本技能)

《Mysql表的简单操作(基本技能)》在数据库中,表的操作主要包括表的创建、查看、修改、删除等,了解如何操作这些表是数据库管理和开发的基本技能,本文给大家介绍Mysql表的简单操作,感兴趣的朋友一起看... 目录3.1 创建表 3.2 查看表结构3.3 修改表3.4 实践案例:修改表在数据库中,表的操作主要

C# WinForms存储过程操作数据库的实例讲解

《C#WinForms存储过程操作数据库的实例讲解》:本文主要介绍C#WinForms存储过程操作数据库的实例,具有很好的参考价值,希望对大家有所帮助,如有错误或未考虑完全的地方,望不吝赐教... 目录一、存储过程基础二、C# 调用流程1. 数据库连接配置2. 执行存储过程(增删改)3. 查询数据三、事务处

Java使用Curator进行ZooKeeper操作的详细教程

《Java使用Curator进行ZooKeeper操作的详细教程》ApacheCurator是一个基于ZooKeeper的Java客户端库,它极大地简化了使用ZooKeeper的开发工作,在分布式系统... 目录1、简述2、核心功能2.1 CuratorFramework2.2 Recipes3、示例实践3

Java利用JSONPath操作JSON数据的技术指南

《Java利用JSONPath操作JSON数据的技术指南》JSONPath是一种强大的工具,用于查询和操作JSON数据,类似于SQL的语法,它为处理复杂的JSON数据结构提供了简单且高效... 目录1、简述2、什么是 jsONPath?3、Java 示例3.1 基本查询3.2 过滤查询3.3 递归搜索3.4

springboot security验证码的登录实例

《springbootsecurity验证码的登录实例》:本文主要介绍springbootsecurity验证码的登录实例,具有很好的参考价值,希望对大家有所帮助,如有错误或未考虑完全的地方,... 目录前言代码示例引入依赖定义验证码生成器定义获取验证码及认证接口测试获取验证码登录总结前言在spring

tomcat多实例部署的项目实践

《tomcat多实例部署的项目实践》Tomcat多实例是指在一台设备上运行多个Tomcat服务,这些Tomcat相互独立,本文主要介绍了tomcat多实例部署的项目实践,具有一定的参考价值,感兴趣的可... 目录1.创建项目目录,测试文China编程件2js.创建实例的安装目录3.准备实例的配置文件4.编辑实例的

python+opencv处理颜色之将目标颜色转换实例代码

《python+opencv处理颜色之将目标颜色转换实例代码》OpenCV是一个的跨平台计算机视觉库,可以运行在Linux、Windows和MacOS操作系统上,:本文主要介绍python+ope... 目录下面是代码+ 效果 + 解释转HSV: 关于颜色总是要转HSV的掩膜再标注总结 目标:将红色的部分滤

Python使用DrissionPage中ChromiumPage进行自动化网页操作

《Python使用DrissionPage中ChromiumPage进行自动化网页操作》DrissionPage作为一款轻量级且功能强大的浏览器自动化库,为开发者提供了丰富的功能支持,本文将使用Dri... 目录前言一、ChromiumPage基础操作1.初始化Drission 和 ChromiumPage

利用Go语言开发文件操作工具轻松处理所有文件

《利用Go语言开发文件操作工具轻松处理所有文件》在后端开发中,文件操作是一个非常常见但又容易出错的场景,本文小编要向大家介绍一个强大的Go语言文件操作工具库,它能帮你轻松处理各种文件操作场景... 目录为什么需要这个工具?核心功能详解1. 文件/目录存javascript在性检查2. 批量创建目录3. 文件

Redis中管道操作pipeline的实现

《Redis中管道操作pipeline的实现》RedisPipeline是一种优化客户端与服务器通信的技术,通过批量发送和接收命令减少网络往返次数,提高命令执行效率,本文就来介绍一下Redis中管道操... 目录什么是pipeline场景一:我要向Redis新增大批量的数据分批处理事务( MULTI/EXE