测试环境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

相关文章

SpringBoot整合Flowable实现工作流的详细流程

《SpringBoot整合Flowable实现工作流的详细流程》Flowable是一个使用Java编写的轻量级业务流程引擎,Flowable流程引擎可用于部署BPMN2.0流程定义,创建这些流程定义的... 目录1、流程引擎介绍2、创建项目3、画流程图4、开发接口4.1 Java 类梳理4.2 查看流程图4

Python实例题之pygame开发打飞机游戏实例代码

《Python实例题之pygame开发打飞机游戏实例代码》对于python的学习者,能够写出一个飞机大战的程序代码,是不是感觉到非常的开心,:本文主要介绍Python实例题之pygame开发打飞机... 目录题目pygame-aircraft-game使用 Pygame 开发的打飞机游戏脚本代码解释初始化部

SQL中JOIN操作的条件使用总结与实践

《SQL中JOIN操作的条件使用总结与实践》在SQL查询中,JOIN操作是多表关联的核心工具,本文将从原理,场景和最佳实践三个方面总结JOIN条件的使用规则,希望可以帮助开发者精准控制查询逻辑... 目录一、ON与WHERE的本质区别二、场景化条件使用规则三、最佳实践建议1.优先使用ON条件2.WHERE用

java Long 与long之间的转换流程

《javaLong与long之间的转换流程》Long类提供了一些方法,用于在long和其他数据类型(如String)之间进行转换,本文将详细介绍如何在Java中实现Long和long之间的转换,感... 目录概述流程步骤1:将long转换为Long对象步骤2:将Longhttp://www.cppcns.c

Linux链表操作方式

《Linux链表操作方式》:本文主要介绍Linux链表操作方式,具有很好的参考价值,希望对大家有所帮助,如有错误或未考虑完全的地方,望不吝赐教... 目录一、链表基础概念与内核链表优势二、内核链表结构与宏解析三、内核链表的优点四、用户态链表示例五、双向循环链表在内核中的实现优势六、典型应用场景七、调试技巧与

Oracle修改端口号之后无法启动的解决方案

《Oracle修改端口号之后无法启动的解决方案》Oracle数据库更改端口后出现监听器无法启动的问题确实较为常见,但并非必然发生,这一问题通常源于​​配置错误或环境冲突​​,而非端口修改本身,以下是系... 目录一、问题根源分析​​​二、保姆级解决方案​​​​步骤1:修正监听器配置文件 (listener.

Java Multimap实现类与操作的具体示例

《JavaMultimap实现类与操作的具体示例》Multimap出现在Google的Guava库中,它为Java提供了更加灵活的集合操作,:本文主要介绍JavaMultimap实现类与操作的... 目录一、Multimap 概述Multimap 主要特点:二、Multimap 实现类1. ListMult

Spring组件实例化扩展点之InstantiationAwareBeanPostProcessor使用场景解析

《Spring组件实例化扩展点之InstantiationAwareBeanPostProcessor使用场景解析》InstantiationAwareBeanPostProcessor是Spring... 目录一、什么是InstantiationAwareBeanPostProcessor?二、核心方法解

java String.join()方法实例详解

《javaString.join()方法实例详解》String.join()是Java提供的一个实用方法,用于将多个字符串按照指定的分隔符连接成一个字符串,这一方法是Java8中引入的,极大地简化了... 目录bVARxMJava String.join() 方法详解1. 方法定义2. 基本用法2.1 拼接

Python中文件读取操作漏洞深度解析与防护指南

《Python中文件读取操作漏洞深度解析与防护指南》在Web应用开发中,文件操作是最基础也最危险的功能之一,这篇文章将全面剖析Python环境中常见的文件读取漏洞类型,成因及防护方案,感兴趣的小伙伴可... 目录引言一、静态资源处理中的路径穿越漏洞1.1 典型漏洞场景1.2 os.path.join()的陷