一、Inventory的定义与作用

oraInventory存放的是Oracle软件安装的目录信息,Oralce的安装升级都需要用到这个目录,来看看Oracle文档中对这个目录的一点说明:
All Oracle software installations rely on this directory. 
Ensure that you back it up regularly. 
Do not delete this directory unless you have completely removed 
all Oracle software from the system.

oraInventory目录的位置是由oraInst.loc文件决定的:
/etc/oraInst.loc (AIX and Linux Platform)
/var/opt/oracle/OraInst.loc (Solaris and HP-UX platform)

$cat /etc/oraInst.loc 
inventory_loc=/app/oracle/oraInventory
inst_group=dba
删除或丢失oraInventory目录的内容,都有可能导致升级报错,例如在运行opatch时就有可能遇到以下报错:
10G中:
$opatch lsinventory
Invoking OPatch 10.2.0.4.3

整理自:

https://blog.csdn.net/caomiao2006/article/details/11901063/
OPatch failed to locate Central Inventory.
Possible causes are: 
    The Central Inventory is corrupted
    The oraInst.loc file specified is not valid.
LsInventorySession failed: OPatch failed to locate Central Inventory.
Possible causes are: 
    The Central Inventory is corrupted
    The oraInst.loc file specified is not valid.

OPatch failed with error code 73
$opatch lsinventory
Invoking OPatch 10.2.0.4.3

List of Homes on this system:

Inventory load failed... OPatch cannot load inventory for the given Oracle Home.
Possible causes are:
   Oracle Home dir. path does not exist in Central Inventory
   Oracle Home is a symbolic link
   Oracle Home inventory is corrupted
LsInventorySession failed: OracleHomeInventory gets null oracleHomeInfo

OPatch failed with error code 73
9I中报错:
OPATCH_JAVA_ERROR  : An exception of type "OPatchException" has occurred: 
OPatch Exception:
  Can not lock OUI inventory (READ/WRITE Level)
  An exception occurs
  The inventory pointed at location /app/oraInventory is not valid

There is no Interim Patch

Can not get a list of inventory on this home.
LsInventory: OPatch Exception while accessing O2O

OPATCH_JAVA_ERROR  : An exception of type "OPatchException" has occurred: 
OPatch Exception:
  OUI found no such ORACLE_HOME set in the environment
  Can not get details for given Oracle Home
  An exception occurs
  null

There is no Interim Patch

Can not get a list of inventory on this home.

ERROR: OPatch failed because of Inventory problem.

二、Inventory重建

1、在10G中可以运行以下命令进行oraInventory目录重建

$cd $ORACLE_HOME/oui/bin
$./runInstaller -silent -attachHome  ORACLE_HOME=$ORACLE_HOME ORACLE_HOME_NAME="ORACLE_HOME"

Starting Oracle Universal Installer...
No pre-requisite checks found in oraparam.ini, 
no system pre-requisite checks will be executed.
The inventory pointer is located at /etc/oraInst.loc
The inventory is located at /app/oracle/oraInventory
'AttachHome' was successful.
js_znjh_1./app/oracle/product/10.2.0/db_1/oui/bin$

2、10.2.0.2以上的版本,还可以直接运行attachHome.sh脚本

$cd $ORACLE_HOME/oui/bin    
$./attachHome.sh

Starting Oracle Universal Installer...
No pre-requisite checks found in oraparam.ini, 
no system pre-requisite checks will be executed.
The inventory pointer is located at /etc/oraInst.loc
The inventory is located at /app/oracle/oraInventory
'AttachHome' was successful.

Oracle 物理结构(一) 文件-Inventory的更多相关文章

  1. ORACLE体系结构一 (物理结构)- 数据文件、日志文件、控制文件和参数文件

    一.物理结构Oracle物理结构包含了数据文件.日志文件.控制文件和参数文件 1.数据文件每一个ORACLE数据库有一个或多个物理的数据文件(data file).一个数据库的数据文件包含全部数据库数 ...

  2. Oracle 物理结构(七) 文件-归档日志文件

    Oracle 物理结构(七) 文件-归档日志文件

  3. Oracle 物理结构(六) 文件-数据文件

    Oracle 物理结构(六) 文件-数据文件

  4. Oracle 物理结构(二) 文件-口令文件

    一.口令文件作用 1.口令文件基本介绍 Oracle数据库口令文件存放有超级用户的口令及其他特殊用户的用户名/口令. 口令文件在数据库创建时,自动创建,存放在$ORACLE_HOME/dbs. 此文件 ...

  5. Oracle物理结构与逻辑结构

    有一张图能非常清晰的表示出Oracle物理结构与逻辑结构的区别:如下图:   对上图的解释:每个数据库都必须由一个或多个表空间组成.(一对多关系)每个表空间都必须由一个或多个数据文件(data fil ...

  6. 【静默】Oracle各类响应文件何在?

    [静默]Oracle各类响应文件何在? --root用户下执行: find -name *.rsp  / 1.创建数据库的响应文件:$ORACLE_HOME/assistants/dbca/dbca. ...

  7. Linux服务器磁盘扩展和oracle表空间文件迁移操作记录

    1.环境介绍 服务器硬件:Dell R710 服务器OS:红帽子Linux   RHEL4.8 数据库:Oracle 10g 2.出现的问题 因为数据表每天有上百万的数据写入表,加上建立索引,导致表空 ...

  8. oracle表分区、表分析及oracle数据泵文件导入导出开心版

    1.先说oracle表分区是什么吧,这样吧我们来举个桃子,栗子太小,我们就不举了,我们来举个桃子. 你有500万份文件,你要把他存在磁盘上,好嘛,我们就一个文件夹,500万分文件在那儿杵着,我们想找到 ...

  9. Oracle----SQL语句积累 (Oracle 导入 dmp文件)

    Oracle----SQL语句积累 (Oracle 导入 dmp文件) Oracle SQL PL  导入dum文件 1.数据库DBA权限: 注意:这个是在cmd命令行中直接输入,不需要进入Oracl ...

  10. Oracle表空间数据文件移动的方法

    最近遇到这样的一个问题,Oracle存放表空间文件的盘符 空间不够了,必须把部分表空间迁移出去, [转]http://www.jb51.net/article/77026.htm 实现把用户表空间中的 ...

随机推荐

  1. Python 安装包时选择 python版本

    安装了两个版本的python 其中一个版本为2.7 专门为python 2.7安装包使用的语句为 升级pip E:\Python27\python -m pip install --upgrade p ...

  2. popcorn-js视频Video框架简单用法

    <div> <video class="video" id="ourvideobig" preload="auto" co ...

  3. atomikos 优化JDBC性能

    JDBC performance comes for free with our pooling DataSource classes: AtomikosDataSourceBean for XA-e ...

  4. ggplot2|详解八大基本绘图要素

    本文首发于微信公众号 *“ 生信补给站 ” ,期待您的关注!!!* 原文链接:https://mp.weixin.qq.com/s?__biz=MzIyNDI1MzgzOQ==&mid=265 ...

  5. (二)发布第一个WebService服务与DSWL文档解析

    1. 编写接口 package service; import javax.jws.WebService; /** * 第一个webservice服务, * @WebService注解表示这是一个we ...

  6. Swiper 轮播插件 之 动态加载无法滑动

    1.原因:轮播图未完全动态加载完成,即初始化 2.方法一:ajax链式编程 $.ajax({ type: "get", url: serviceURL + "/listB ...

  7. C# 第一次做项目。一些经验总结。

    这是我的第一篇博客,写得不好望大家多多包涵. 初学C#2个多月,拿着老师给的项目,试着做了做,发现自己在编程方面有很多陋习与编程知识方面的不足. 首先是没有遵守某一个设计模式,这导致我想到哪里就做到了 ...

  8. 转录组测序(RNA-seq)技术

        转录组是某个物种或者特定细胞类型产生的所有转录本的集合.转录组研究能够从整体水 平研究基因功能以及基因结构,揭示特定生物学过程以及疾病发生过程中的分子机理,已广泛应 用于基础研究.临床诊断和药 ...

  9. Trie树(字典树)-题解 P2580 【于是他错误的点名开始了】

    此题可以用STL中的map做,但是了解一下Trie树这个数据结构也是必须的. Trie树(又称字典树)有以下特点: 根节点不包含字符,除它之外的每一个节点都包含一个字符. 从根节点到某一节点,路径上经 ...

  10. C# List<> Find相关接口学习

    参考 http://blog.csdn.net/daigualu/article/details/54315564 示例: List<int> test = new List<int ...