OPatch error: “Unable to lock Central Inventory”

13 Okt

Oracle Database – Enterprise Edition – Version 9.2.0.1 to 12.1.0.2 [Release 9.2 to 12.1] – alle Plattformen

Fehleranzeige:
Opatch apply failing with following errors
Unable to lock Central Inventory. OPatch will attempt to re-lock.
Do you want to proceed? [y|n]

[oracle@ccuine19 5596276]$ opatch apply
Invoking OPatch 10.2.0.4.7
Oracle Interim Patch Installer version 10.2.0.4.7
Copyright (c) 2009, Oracle Corporation. All rights reserved.
Oracle Home : /db/dr/drdb/10.2.0
Central Inventory : /etc/oraInventory
from : /etc/oraInst.loc
OPatch version : 10.2.0.4.7
OUI version : 10.2.0.4.0
OUI location : /db/dr/drdb/10.2.0/oui
Log file location : /db/dr/drdb/10.2.0/cfgtoollogs/opatch/opatch2009-07-22_10-
50-24AM.log
Patch history file: /db/dr/drdb/10.2.0/cfgtoollogs/opatch/opatch_history.txt
ApplySession applying interim patch ‘5596276’ to OH ‘/db/dr/drdb/10.2.0’
Unable to lock Central Inventory. OPatch will attempt to re-lock.
Do you want to proceed? [y|n]
y
User Responded with: Y
OPatch will sleep for few seconds, before re-trying to get the lock…
Unable to lock Central Inventory. OPatch will attempt to re-lock.
Do you want to proceed? [y|n]

Begründung:
a) Oracle hat keine Schreibberechtigung auf <oraInventory>/locks
[oracle@ccuine19 oraInventory]$ ls -la
total 40
drwxrwxrwx 6 oracle oinstall 4096 Jul 20 14:27 .
drwxr-xr-x 116 root root 12288 Jul 21 15:42 ..
drwxrwxrwx 2 oracle oinstall 4096 Jul 8 18:28 Contents
drwxrwxrwx 2 oracle oinstall 4096 Jul 14 12:00 ContentsXML
-rwxrwxrwx 1 oracle oinstall 37 Jul 21 14:27 install.platform
drwxr-xr-x 2 testdb oinstall 4096 Jul 21 14:28 locks
drwxrwx— 2 oracle oinstall 4096 Jul 22 12:20 logs

— Lösung a) $ ls -la <oraInventory>  — Berechtigung oracle nachziehen

b) Mehrfache Patchversuche mit Einträgen in oraInventory>/locks/ oder $ORACLE_HOME/.patch_storage/
[oracle@ccuine19 5596276]$ cat /etc/oraInst.loc
inventory_loc=/etc/oraInventory
inst_group=oinstall
[oracle@ccuine19 5596276]$ ls /etc/oraInventory/locks
[oracle@ccuine19 5596276]$ ls $ORACLE_HOME/.patch_storage
5596276_Apr_22_2008_05_54_46/

— Lösung b) Gruppenrechte auf das Inventory setzen
$ cat /etc/oraInst.loc
inventory_loc=/etc/oraInventory
inst_group=oinstall
# chmod -R g+w /etc/oraInventory

c) Ein Platzproblem
/dev/mapper/vg_bmlpc10001-lvol0 4.8G 4.8G 0 100% /u01 <<<<<<<<<<< oraInventory located
in /u01 directory
/dev/mapper/vg_bmlpc10001-lvol1 20G 18G 1.1G 95% /u01/app/grid <<< software is located in
/u01/app/grid

— Lösung c) Platz schaffen

Diesen Artikel teilen :Share on Google+Share on LinkedInTweet about this on TwitterShare on Facebook