Oracle如何检查当前数据库CPU和PSU补丁信息?

数据库 Oracle
本文我们主要介绍了Oracle数据库中检查当前数据库的CPU和PSU补丁安装情况的两种方法,希望能够对您有所帮助。

Oracle数据库中,我们如何检查当前数据库的CPU和PSU补丁安装情况呢?本文我们主要就介绍这部分内容,希望能够对您有所帮助。

正常情况下有两种方法:

一种是登录数据库检查DBA_REGISTRY_HIST视图:

 

  1. MODDB2:[/home/oracle]$sqlplus / as sysdba  
  2. SQL*Plus: Release 10.2.0.4.0 - Production on Thu Aug 18 13:04:43 2011  
  3. Copyright (c) 1982, 2007, Oracle. All Rights Reserved.  
  4. Connected to:  
  5. Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production  
  6. With the Partitioning, Real Application Clusters, Oracle Label Security, Data Mining  
  7. and Real Application Testing options  
  8. SQL> set pages 100 lines 120  
  9. SQL> col action format a6  
  10. SQL> col namespace format a10  
  11. SQL> col version format a10  
  12. SQL> col comments format a15  
  13. SQL> col action_time format a30  
  14. SQL> col bundle_series format a15  
  15. SQL> alter session set nls_timestamp_format = 'yyyy-mm-dd hh24:mi:ss.ff';  
  16. Session altered.  
  17. SQL> select * from dba_registry_history;  
  18. ACTION_TIME ACTION NAMESPACE VERSION ID BUNDLE_SERIES COMMENTS  
  19. --------------------------- ------ ---------- -------------- -------------- ---------------  
  20. 2011-06-02 16:54:21.301023 APPLY SERVER 10.2.0.4 4 PSU PSU 10.2.0.4.4  
  21. 2011-06-02 16:54:42.711877 APPLY SERVER 10.2.0.4 1 OPSU PSU 10.2.0.4.5 

 

另一种方式是通过opatch lsinventory方式:

 

  1. MODDB2:[/home/oracle]$opatch lsinventory  
  2. Invoking OPatch 10.2.0.5.0  
  3. Oracle Interim Patch Installer version 10.2.0.5.0  
  4. Copyright (c) 2010, Oracle Corporation. All rights reserved.  
  5. Oracle Home : /oracle/db  
  6. Central Inventory : /oracle/oraInventory  
  7. from : /var/opt/oracle/oraInst.loc  
  8. OPatch version : 10.2.0.5.0  
  9. OUI version : 10.2.0.4.0  
  10. OUI location : /oracle/db/oui  
  11. Log file location : /oracle/db/cfgtoollogs/opatch/opatch2011-08-18_11-18-30AM.log  
  12. Patch history file: /oracle/db/cfgtoollogs/opatch/opatch_history.txt  
  13. Lsinventory Output file location : /oracle/db/cfgtoollogs/opatch/lsinv/lsinventory2011-08-18_11-18-30AM.txt  
  14. --------------------------------------------------------------------------------  
  15. Installed Top-level Products (2):  
  16. Oracle Database 10g 10.2.0.1.0  
  17. Oracle Database 10g Release 2 Patch Set 3 10.2.0.4.0  
  18. There are 2 products installed in this Oracle Home.  
  19. Interim patches (4) :  
  20. Patch 6367097 : applied on Tue Sep 14 22:08:15 GMT+08:00 2010  
  21. Created on 20 Jul 2008, 23:37:14 hrs US/Pacific  
  22. Bugs fixed:  
  23. 6367097  
  24. ......  
  25. Bugs fixed:  
  26. 9294403  
  27. OPatch succeeded. 

 

注意:CPU和PSU补丁分为两部分,首先通过opatch命令,随后还需要运行cat_bundle.sql。如果没有运行这个SQL,则补丁不算安装成功,这时通过OPATCH命令检查可以看到补丁的安装信息,但是在数据库的DBA_REGISTRY_HISTORY中是找不到对应的信息的。

以上就是Oracle数据库中检查当前数据库CPU和PSU补丁信息的两种方法,本文就介绍到这里了,希望本次的介绍能够对您有所收获!

【编辑推荐】

  1. Oracle临时表在实际开发中的应用详解
  2. Oracle 11g R2数据库示例用户安装说明
  3. Oracle 11g数据库审计功能应用实例解析
  4. Oracle 11g数据库默认审计选项说明详解
  5. Oracle 11g数据库使用XML Table的BUG解决
责任编辑:赵鹏 来源: CSDN博客
相关推荐

2011-08-23 15:55:40

数据库CPUPSU

2011-05-17 14:34:24

2022-06-06 08:21:13

MySQL数据库命令

2021-09-21 15:39:30

rpm-ostree数据库更新日志

2011-07-27 13:22:35

检查索引碎片Oracle数据库重建索引

2010-04-19 16:01:54

2011-03-29 10:47:49

ORACLE数据库

2023-09-05 08:40:57

删除数据库Oracle

2011-04-12 10:59:46

Oracle数据库

2011-08-29 14:00:26

MySQL主从延时

2009-11-20 14:08:39

Oracle数据库备份

2011-05-19 13:25:12

Oracle数据库碎片

2011-04-13 14:58:16

Oracle数据库删除

2015-07-23 17:02:55

oracle创建数据库

2011-08-02 16:44:00

Oracle数据库角色权限默认表空间

2011-08-02 17:06:29

Oracle远程数据库创建DB Link

2010-04-29 11:53:42

Oracle数据库

2010-05-05 14:44:50

Oracle数据库

2010-04-29 08:52:29

Oracle数据库

2019-07-03 09:35:20

Oracle数据库监听
点赞
收藏

51CTO技术栈公众号