Tales From A Lazy Fat DBA

Its all about Databases & their performance, troubleshooting & much more …. ¯\_(ツ)_/¯

  • Prashant Dixit is the 'FatDBA' ...
  • Follow me on Twitter

Posts Tagged ‘Errors’

A Day tried to fix the infamous ORA-00600 [kqlnrc_1] from our DB systems.

Posted by FatDBA on February 16, 2014

ORA-00600 [kqlnrc_1] most of the times is about an invalid object in the Library Cache of the database.
An Oracle Trace file is always generated during the time of this error. Below provided are few of the steps that you can try atleast before you passon the case to Oracle Support team.

Open the trace file with an editor (The following lines are from an 11.2.0.3 trace file) :

1. Find the first ORA_600 error argument
ORA-00600: internal error code, arguments: [kqlnrc_1], [0x143C6DAD0], [], [], [], [], [], [], [], [], [], []

2. Search the trace file for 0x143c6dad0 (its the first argument in lower case):

DDE: Problem Key ‘ORA 600 [kqlnrc_1]’ was flood controlled (0x2) (incident: 35561)
ORA-00600: internal error code, arguments: [kqlnrc_1], [0x143C6DAD0], [], [], [], [], [], [], [], [], [], []

LibraryHandle:  Address=0x143c6dad0 Hash=cd3b674a LockMode=S PinMode=S LoadLockMode=0 Status=INVL
ObjectName:  Name=PUBLIC.TEST
FullHashValue=5c820441b24ce2df1d9a0971cd3b674a Namespace=TABLE/PROCEDURE(01) Type=SYNONYM(05) Identifier=0 OwnerIdn=2147483644
Statistics:  InvalidationCount=2 ExecutionCount=0 LoadCount=1 ActiveLocks=1 TotalLockCount=6 TotalPinCount=6
Counters:  BrokenCount=1 RevocablePointer=1 KeepDependency=0 BucketInUse=6 HandleInUse=6 HandleReferenceCount=0
Concurrency:  DependencyMutex=0x143c6db80(0, 8, 0, 0) Mutex=0x143c6dc00(233, 45, 0, 6)
Flags=REM/PIN/TIM/[00022801]
WaitersLists:
Lock=0x143c6db60[0x143c6db60,0x143c6db60]
Pin=0x143c6db40[0x143c6db40,0x143c6db40]
LoadLock=0x143c6dbb8[0x143c6dbb8,0x143c6dbb8]
Timestamp:  Current=04-25-2013 09:41:24
HandleReference:  Address=0x143c6dc90 Handle=(nil) Flags=[00]
ReferenceList:
Reference:  Address=0x145badf28 Handle=0x12d7be980 Flags=DEP[01]
Timestamp=04-25-2013 09:41:24 InvalidatedFrom=0
LibraryObject:  Address=0x10dbe40b0 HeapMask=0000-0001-0001-0000 Flags=EXS/LOC[0004] Flags2=[0000] PublicFlags=[0000]
DataBlocks:
Block:  #=’0′ name=KGLH0^cd3b674a pins=0 Change=NONE
Heap=0x12297cc10 Pointer=0x10dbe4150 Extent=0x10dbe4030 Flags=I/-/P/A/-/-
FreedLocation=0 Alloc=0.257812 Size=4.000000 LoadTime=15174108210

3. Find the object :

SELECT object_name,object_type,owner,status
FROM dba_objects
WHERE object_name=’TEST’ and owner=’PUBLIC’;

OBJECT_NAME OBJECT_TYPE OWNER STATUS
————– ————- —————- ——-
TEST SYNONYM PUBLIC VALID
4. Compile the synonym owned by public.

As sys :

SQL> alter public synonym TEST compile;

or Recreate it

SQL> create or replace public synonym xyz for xyz@javadb@testlab;

And That’s Fixed,

Hope That Helps
Prashant Dixit

Posted in Advanced | Tagged: | Leave a Comment »

RMAN Error: ORA-01152: file 1 was not restored from a sufficiently old backup & ORA-01110:

Posted by FatDBA on January 15, 2014

RMAN Scenario:
DB: Oracle 11g r2
OS: Linux – RHEL 5
Error: “ORA-01152: file 1 was not restored from a sufficiently old backup” when tried to open the database.

STATUS
==============
SQL> @db

NAME      ROLE       LOG_MODE     OPEN_MODE      DG_BROKE FORC_LGNG   CUR_SCN        CKPT_CHG        CTRLFIL_SEQ CTRLFL_CNG      ARCH_CNG       PROT_MOD
——— ———- ———— ————– ——– ———– ————– ————— ———– ————— ————– ——————–
SAIRAM     PRIMARY    ARCHIVELOG   MOUNTED        DISABLED YES         0              32913920280       795938526 32913922263     32913811789    MAXIMUM PERFORMANCE

SQL> select open_mode from v$database;
OPEN_MODE
————–
MOUNTED

This is what’s happening with the database when tried to open it.
Throwing error which reads System datafile is restored from an old backup.

SQL> alter database open resetlogs;
alter database open resetlogs
*
ERROR at line 1:
ORA-01152: file 1 was not restored from a sufficiently old backup
ORA-01110: data file 1: ‘/dbmount212/sairam/datafiles/system01.dbf’

When tried to recover the database it’s asking for sequence number 75, which is not available (Conformed, as asked sequence is not available in ARCHIVE destination).

SQL> recover database until cancel using backup controlfile;
ORA-00279: change 32913922263 generated at 01/14/2014 10:57:39 needed for thread 1
ORA-00289: suggestion : /dbmount212/oracle/sairam/archivelog/1_75_833707787.arc
ORA-00280: change 32913922263 for thread 1 is in sequence #75

Specify log: {<RET>=suggested | filename | AUTO | CANCEL}
AUTO
ORA-00308: cannot open archived log ‘/dbmount212/oracle/sairam/archivelog/1_75_833707787.arc’
ORA-27037: unable to obtain file status
Linux-x86_64 Error: 2: No such file or directory
Additional information: 3

ORA-00308: cannot open archived log ‘/dbmount212/oracle/sairam/archivelog/1_75_833707787.arc’
ORA-27037: unable to obtain file status
Linux-x86_64 Error: 2: No such file or directory
Additional information: 3

ORA-01547: warning: RECOVER succeeded but OPEN RESETLOGS would get error below
ORA-01152: file 1 was not restored from a sufficiently old backup
ORA-01110: data file 1: ‘/dbmount212/sairam/system01.dbf’

There is a possibility that the sequence might be struck inside of any redo log file and has not been archived.
Let’s query required sequence number (75) using one of the dynamic view v$log

SQL> select * from v$log where SEQUENCE#=’75’;

GROUP#    THREAD#  SEQUENCE#      BYTES  BLOCKSIZE    MEMBERS ARC STATUS           FIRST_CHANGE#
———- ———- ———- ———- ———- ———- — —————- ————-
FIRST_TIM NEXT_CHANGE# NEXT_TIME
——— ———— ———
9          1         75  524288000        512          1 NO  CURRENT             3.2914E+10
14-JAN-14   2.8147E+14

Yes,the log is inside group number 9. Let’s check the location of the related log file using v$logfile;

SQL> SELECT * FROM V$LOGFILE where group#=’9′;

GROUP# STATUS  TYPE
———- ——- ——-
MEMBER
—————————————————————————————————-
IS_

9         ONLINE
/var/log/oracle/redo/onlinelog/redo07.log
NO

Let’s try to recover the database again.

SQL> recover database until cancel using backup controlfile;

ORA-00279: change 32913922872 generated at 01/14/2014 11:17:33 needed for thread 1
ORA-00289: suggestion : /dbmount212/oracle/sairam/archivelog/1_75_833707787.arc
ORA-00280: change 32913922872 for thread 1 is in sequence #75Specify log: {<RET>=suggested | filename | AUTO | CANCEL}
/var/log/oracle/redo/onlinelog/redo09.log
ORA-00283: recovery session canceled due to errors
ORA-01111: name for data file 69 is unknown – rename to correct file
ORA-01110: data file 69: ‘/dbmnt12/oracle/product/11.2.0/dbhome_1/dbs/UNNAMED00069’
ORA-01157: cannot identify/lock data file 69 – see DBWR trace file
ORA-01111: name for data file 69 is unknown – rename to correct file
ORA-01110: data file 69: ‘/dbmnt12/oracle/product/11.2.0/dbhome_1/dbs/UNNAMED00069’

Alright, it’s asking for one datafile (69) which is unknown to the controlfile. Yes, this is right. As we have created a test datafile before that controlfile backup.
As it’s of no importance, we’d dropped the datafile.

SQL> alter database datafile 69 offline drop;
Database altered.

Let’s try again to recover the database using the log file ‘/var/log/oracle/redo/onlinelog/redo09.log’.

SQL> recover database using backup controlfile ;
ORA-00279: change 32913922872 generated at 01/14/2014 11:17:33 needed for thread 1
ORA-00289: suggestion : /dbmount212/oracle/sairam/archivelog/1_75_833707787.arc
ORA-00280: change 32913922872 for thread 1 is in sequence #75

Specify log: {<RET>=suggested | filename | AUTO | CANCEL}
/var/log/oracle/redo/onlinelog/redo09.log
Log applied.
Media recovery complete.

Okay, when provided exact filename of the logfile, it has accepted it and applied and came up, hence media recovery is completed.
Now we can go and try to open the database.

SQL> alter database open resetlogs;
Database altered.

SQL> archive log list;
Database log mode              Archive Mode
Automatic archival             Enabled
Archive destination            /dbmount212/oracle/sairam/archivelog/
Oldest online log sequence     1
Next log sequence to archive   1
Current log sequence           1

And we are up!
Below provided is the list of incarnation of the database and the last line with a new incarnation created on today’s date.

SQL> select * from V$DATABASE_INCARNATION;

INCARNATION# RESETLOGS_CHANGE# RESETLOGS PRIOR_RESETLOGS_CHANGE# PRIOR_RES STATUS  RESETLOGS_ID PRIOR_INCARNATION# FLASHBACK_DATABASE_ALLOWED
———— —————– ——— ———————– ——— ——- ———— —————— ————————–
1            602821 05-MAY-10                       1 12-MAR-08 PARENT     718177612                  0 NO
2         148027929 19-MAY-10                  602821 05-MAY-10 PARENT     719411741                  1 NO
3        9199856900 28-AUG-11               148027929 29-MAY-10 PARENT     760357356                  2 NO
4        1.9412E+10 11-AUG-12              9199856900 28-AUG-11 PARENT     791021290                  3 NO
5        3.2910E+10 09-DEC-13              1.9412E+10 1-AUG-12 PARENT     833707787                  4 NO
6        3.2914E+10 15-JAN-14              3.2910E+10 09-DEC-13 CURRENT    836892925                  5 YES

6 rows selected.

Hope That Helps
Prashant Dixit

Posted in Advanced | Tagged: , | 4 Comments »

Something Strikingly odd with Oracle: DB with Two ‘Current’ log-files!!

Posted by FatDBA on January 8, 2014

Something real uncanny happened with one of our databases recently: There were 2 log-files with CURRENT status: Strange right!!!

SQL> select GROUP#,SEQUENCE#,BYTES/1024/1024 as SIZE_MB,MEMBERS,STATUS from v$log;
GROUP#  SEQUENCE#      SIZE_MB    MEMBERS STATUS
———- ———- ———- ———-   —————
1       15651       50          2 INACTIVE
3       15653       50          2 CURRENT
2       15652       50          2 CURRENT
4       15650       50          2 INACTIVE

Found the ‘Notorious’ Generic error ORA-600 in alert log :
ORA-00600: internal error code, arguments: [3705], [1], [3], [2], [8], [], [], []

We had to perform point-in-time recovery up to 15652 sequence and we were all good.

Hope That Helps
Prashant Dixit

Posted in Uncategorized | Tagged: | Leave a Comment »

RMAN-06900/RMAN-06901 and ORA-19921: maximum number of 64 rows exceeded

Posted by FatDBA on November 22, 2013

Received one of the odd and obscure RMAN/ORA errors of its kind While trying to connect with RMAN in Red Hat Enterprise Linux 5 and have wasted almost several minutes of my precious time, until i realized that there is one old RMAN session alive and was connected from the another terminal and was one day old before getting this error.

Okay so here is the case, while trying to connect with the target database in RMAN we have started recieving several RMAN and ORA errors …

[oracle@prashant1 ~]$ rman target /
Recovery Manager: Release 10.2.0.1.0 – Production on Fri Nov 22 21:30:38 2013
Copyright (c) 1982, 2005, Oracle.  All rights reserved.

connected to target database: QRCL (DBID=859215136)
RMAN-06900: WARNING: unable to generate V$RMAN_STATUS or V$RMAN_OUTPUT row
RMAN-06901: WARNING: disabling update of the V$RMAN_STATUS and V$RMAN_OUTPUT rows
ORACLE error from target database:
ORA-19921: maximum number of 64 rows exceeded

RMAN> host;

Let’s explore more aboput the ora error using my favorite utility OERR

[oracle@prashant1 ~]$ oerr ORA 19921
19921, 00000, “maximum number of %s rows exceeded”
// *Cause:  The maximum number of rows in the V$RMAN_STATUS or V$RMAN_OUTPUT
//          table has been exceeded.
// *Action: Close some of existing and unused RMAN connections and sessions.

Let’s check how many and how old the rman sessions exists in my database.

[oracle@prashant1 ~]$ ps -ef|grep rman
oracle   25970 25861  0 Nov21 pts/1    00:00:50 rman target /
oracle   29999 29863  0 21:30 pts/4    00:00:00 rman target /
oracle   30113 30088  0 21:33 pts/4    00:00:00 grep rman

[oracle@prashant1 ~]$ date
Fri Nov 22 21:34:05 IST 2013

Alright, so there is one of the session with OS ID – 25970 running from November 21 from Terminal (tty 1) –
Let’s kill the session and try to connect with the Recovery Manager once again.

[oracle@prashant1 ~]$ kill -9 25970

[oracle@prashant1 ~]$ ps -ef|grep rman
oracle   29999 29863  0 21:30 pts/4    00:00:00 rman target /
oracle   30115 30088  0 21:34 pts/4    00:00:00 grep rman

Okay, so it’s gone and no more under the process list.

[oracle@prashant1 ~]$ rman target /
Recovery Manager: Release 10.2.0.1.0 – Production on Fri Nov 22 21:34:15 2013
Copyright (c) 1982, 2005, Oracle.  All rights reserved.
connected to target database: QRCL (DBID=859215136)
RMAN>

Okay and we have not getting list of those errors what we previously encountered and issue is F.I.X.E.D

Hope That Helps
Prashant Dixit

Posted in Advanced | Tagged: , | 1 Comment »

Standby/Dataguard:– RFS Process not working.

Posted by FatDBA on November 12, 2013

Not feeling well today!! 😦 , but as  It’s been a long time since i wrote my last article on Oracle database issues … here i am back again with one of the problem that we faced in our production database of our erstwhile customer, some time ago.
It was a typical Physical Standby environment with Maximum Performance model set. This is a story happened on one fine day when we started receiving some issues after a small network outage which blocked the redo stream to transfer logs from Production to standby server. ** * The bad part was  – the issue had happened during peak hours where we had confined amount of time to rectify the case.

Issue: RFS Process not working
Problem Description:
The filesystem containing the archive destination in DR server was not accessible. As a result the log shipping got stopped. We deferred the log shipping in the production server. After the filesystem was back, we enabled the log shipping but the RFS process in DR server was not running…The problem occurred when the log 24717 was being shipped… When we queried

SQL> Select status, sequence# from v$managed_standby;

The status for MRP showed that it was waiting for gap…We then manually shipped the log file and then applied… When we enabled the shipping we found that the RFS process was still not started…..There were no error in the alert log of DR…We found a trace file in the production server with the following message..

tkcrrsarc: (WARN) Failed to find ARCH for message (message:0xa)
tkcrrpa: (WARN) Failed initial attempt to send ARCH message (message:0xa)

So we thought that the issue is with the archiver process….

Solution:
Check whether the archiver process is available for shipping log files. You can identify this by querying V$ARCHIVE_PROCESSES view.
SQL> Select * from v$archive_processes;

The output have the following columns:
Process: Indicates the process number.
Status: This should be ACTIVE
Log Sequence: Log sequence number of the log that is being shipped by the archiver. If it is not shipping any log then it should be 0.
State: This should be IDLE if the archiver is not shipping any log. If it is shipping any log then its state is BUSY.

In our case we had two archiver process running.

The status of both the arch process is ACTIVE.
The log sequence of First arch process is 0 and its state is IDLE. Hence it is healthy. However the log sequence of 2nd arch process is 24717 and its state is BUSY.

This was interesting because the problem occurred when the arch process was transferring the log 24717. This log was then manually shipped and applied. But the process still shows that it was shipping the 24717 log…
So we thought of increasing the arch processes. We increased the arch process from two to four.
SQL> alter system set log_archive_max_processes=4 scope=both;

We queried the v$archive_processes, the 3rd and 4th arch process was ready to ship the log files 24718 and 24719 logs respectively with their corresponding state as IDLE…
We enabled the log shipping and the RFS process in DR was started and the log shipping went smoothly.

However the 2nd arch process still was showing the same log sequence (24717) and state (BUSY)…. We then killed that archiver process…. And we were all good!

Hope That Helped
Prashant Dixit

Posted in Advanced | Tagged: , | 5 Comments »

PRVF-7531 – Oracle 11.2 Prerequisite Checks fail (MS Windows Error)

Posted by FatDBA on October 8, 2013

Today i got a call from one of my good friend who was trying to install Oracle 11g on Windows 7 platform (And was very furious about — Why oracle website don’t have version 10g available anymore, after the release of latest 12c … 🙂 … ) and was getting errors during pre checks during OUI calls.

Exact Error:
On  Step 7 of 10,

All Prerequisite Checks fail.

Physical Memory                        Failed
Available Physical Memory         Failed
Swap Size                                  Failed
Free Space                                 Failed
Architecture                                Failed
Environment variable PATH        Failed

Clicking on the more details link, shows:
– PRVF-7531 : Physical memory check cannot be performed on node “machine-name”
– Cause: Could not perform check of physical memory on the node indicated.
– Action: Ensure ability to access the node specified and view memory information.

 

image001

 

image002
With many errors related to Physical/Swap Size, initially i thought that i could be due to insufficient memory on the system, But he has 4GB of RAM available.
Next i asked if he is trying to install the software on any Admin controlled machine, and my guess was right – He was.

So, all of these errors left us bewildered and with very less details available. Ultimately, MOS came to rescue.
Found one of the Metalink note for his issue — Doc ID 1086063.1

Cause
The Workstation or Server services have not been started.

Solution
Make sure both the “WORKSTATION” and “SERVER” services are started.
Rerun the setup program.
Now all the Prerequisite Checks Succeed.

– The Workstation or Server services need to be started for Oracle to communicate with the machine, to make sure all the prerequisite checks are performed.
– It has been reported, the TCP/IP NetBIOS Helper service should also be started, to pass the Pre-Req checks.

Found SERVER service disabled on his machine and is the reason which is obstructing the pre checks to complete.

Posted in Advanced | Tagged: | 6 Comments »

ORA-00904: “POLTYP”: invalid identifier — During EXPORT

Posted by FatDBA on October 6, 2013

Error:
EXP-00008: ORACLE error 904 encountered
ORA-00904: “POLTYP”: invalid identifier

When:  During EXPORT operations.
This Scenario: During export of rman recovery catalog (Production).

$ exp rman/xxxxxx@rxxxxxx FILE=catalogexport.dmp OWNER=rman

Export: Release 11.2.0.3.0 – Production on Sun Oct 6 10:50:22 2013
Copyright (c) 1982, 2011, Oracle and/or its affiliates.  All rights reserved.

Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 – 64bit Production
With the Partitioning, OLAP and Data Mining options
Export done in US7ASCII character set and AL16UTF16 NCHAR character set
server uses AL32UTF8 character set (possible charset conversion)
. exporting pre-schema procedural objects and actions
. exporting foreign function library names for user RMAN
. exporting PUBLIC type synonyms
. exporting private type synonyms
. exporting object type definitions for user RMAN
About to export RMAN’s objects …
. exporting database links
. exporting sequence numbers
. exporting cluster definitions
. about to export RMAN’s tables via Conventional Path …
EXP-00008: ORACLE error 904 encountered
ORA-00904: “POLTYP”: invalid identifier
EXP-00000: Export terminated unsuccessfully

This error occurs if you try the old export command from an 11g client against a database on version 10g or lower. The export command runs a query against a table called EXU9RLS in the SYS schema. On 11g this table was expanded with the column POLTYP and the export command (exp) expects to find this column. This should not be much of a problem since Data Pump export can be used.

SQL> desc EXU9RLS
Name                                                                                                  Null?    Type
—————————————————————————————————– ——– ——————————————————————–
OBJOWN                                                                                                NOT NULL VARCHAR2(30)
OBJNAM                                                                                                NOT NULL VARCHAR2(30)
POLGRP                                                                                                NOT NULL VARCHAR2(30)
POLICY                                                                                                NOT NULL VARCHAR2(30)
POLOWN                                                                                                NOT NULL VARCHAR2(30)
POLSCH                                                                                                         VARCHAR2(30)
POLFUN                                                                                                NOT NULL VARCHAR2(30)
STMT                                                                                                           VARCHAR2(34)
CHKOPT                                                                                                NOT NULL NUMBER
ENABLED                                                                                               NOT NULL NUMBER
SPOLICY                                                                                                        NUMBER
 POLTYP                                                                                                         VARCHAR2(33)

Resolution:
Since there was no code added in export to extract the RLS policy type, the fix for Bug 7568350 introduces a new column POLTYP in EXU9RLS view that is associated with the RLS policy type.

Fixed: Patch 7568350
Link:
https://support.oracle.com/epmos/faces/ui/patch/PatchDetail.jspx?_afrLoop=15303088597334&patchId=7568350&_afrWindowMode=0&_adf.ctrl-state=x42u0k77b_206

Doc ID: Doc ID 784038.1

Posted in Advanced | Tagged: | Leave a Comment »

VMWare: Reason: “Cannot open the disk, Reason: Failed to lock the file”.

Posted by FatDBA on August 25, 2013

Today while starting one of my Test machine/instance which is a part of an VMWare (This Team includes a total of 3 virtual machines) has started giving an error message which reads:

“Cannot open the disk: ‘H:\Machine ………….’ or one of the snapshot disks it depends on.Reason: Failed to lock the file”.

errrrrrro
And this error restricts us to open the same machine and kept on throwing the same again and again.

Error:
After reading errors it seems to be related with the locks that machines acquire in VMWare Team environment in order to access resources.

Resolution:
While we start our virtual machines there are many different folders related to locks created which contains .lck (Lock Files) and are used by the machine during the operation i.e M30076.lck, Mx456.lck et.
These locks are dynamic in nature and auto refreshes after some time. So, i removed/renamed all of the lock files (.lck) existed under all of these folder and tried the machine again and as what i’ve expected, it started working back again.

* Note: Performing these steps on PROD systems could be dangerous and can cause serious performance/hang issues. Performing such steps always requires recommendations from the VMWARE support.

Thanks
Prashant Dixit
“Sharing is Good”

Posted in Advanced | Tagged: , , | Leave a Comment »

OPatch: ApplySession failed: Patch ID is null (OPatch failed with error code 73).

Posted by FatDBA on August 20, 2013

Going to discuss one of the most recent issue that I’ve faced while applying PSU patch for the month of July on one of our Pre-Prod Database. I’ve tried to reproduce the similar situation on one of my test machine.

We were trying to apply it (Patch) on our databse which is running on 11.2.0.1.0.  After sucessfully passed all prechecks of the patch we downloaded from Metalink

Prechecks:
1. Setting Env Variables (ORACLE_SID, ORACLE_HOME, PATH etc.)
2. Shutting down DB and Listener (No RAC Env)
3. Uncompressed zip file to the OPatch directory.

ORACLE_SID = [orcl] ? sairam
The Oracle base for ORACLE_HOME=/u01/app/oracle/product/11.2.0/db_1 is /u01/app/oracle

[oracle@prashant ~]$ sqlplus / as sysdba

SQL*Plus: Release 11.2.0.1.0 Production on Tue Aug 20 22:00:32 2013
Copyright (c) 1982, 2009, Oracle.  All rights reserved.
Connected to an idle instance.
SQL> exit

[oracle@prashant ~]$ cd /u01/app/oracle/product/11.2.0/db_1/OPatch/
[oracle@prashant OPatch]$ cd 12419378/
[oracle@prashant 12419378]$ ls
custom  etc  files  patchmd.xml  README.html  README.txt

[oracle@prashant 12419378]$ opatch apply
Invoking OPatch 11.1.0.6.6

Oracle Interim Patch Installer version 11.1.0.6.6
Copyright (c) 2009, Oracle Corporation.  All rights reserved.

Oracle Home       : /u01/app/oracle/product/11.2.0/db_1
Central Inventory : /u01/app/oraInventory
from           : /etc/oraInst.loc
OPatch version    : 11.1.0.6.6
OUI version       : 11.2.0.1.0
OUI location      : /u01/app/oracle/product/11.2.0/db_1/oui
Log file location : /u01/app/oracle/product/11.2.0/db_1/cfgtoollogs/opatch/opatch2013-08-20_22-02-22PM.log

Patch history file: /u01/app/oracle/product/11.2.0/db_1/cfgtoollogs/opatch/opatch_history.txt

ApplySession failed: Patch ID is null.
System intact, OPatch will not attempt to restore the system

OPatch failed with error code 73

* After Checking the current OPatch Version it Looks like we will need a higher version of OPatch utility to apply this patch.
[oracle@prashant 12419378]$ opatch version
Invoking OPatch 11.1.0.6.6
OPatch Version: 11.1.0.6.6

OPatch succeeded.

Hence downloaded latest version of Opatch from My Oracle Support (patch 6880880).
1. Downloaded Patch 6880880.
2. Took a backup of $ORACLE_HOME/OPatch into a dedicated backup location.
3. Removed the contents of $ORACLE_HOME/OPatch directory (Please do not
remove $ORACLE_HOME/OPatch directory itself).
4. Unzipped the OPatch downloaded zip into $ORACLE_HOME directory.

[oracle@prashant OPatch]$ ls
p6880880_112000_Linux-x86-64.zip
[oracle@prashant OPatch]$ unzip p6880880_112000_Linux-x86-64.zip
Archive:  p6880880_112000_Linux-x86-64.zip
creating: OPatch/
creating: OPatch/oplan/
……….

……….

[oracle@prashant OPatch]$ ls -ltr
total 32408
-rw-rw—- 1 oracle oinstall       26 Jun 26 11:54 version.txt
-rwxrwxr-x 1 oracle oinstall     2991 Jun 26 11:54 README.txt
-rw-rw-r– 1 oracle oinstall     2576 Jun 26 11:54 opatch.pl
-rw-rw-r– 1 oracle oinstall       49 Jun 26 11:54 opatch.ini
-rwxrwxr-x 1 oracle oinstall     9352 Jun 26 11:54 opatchdiag.bat
-rwxrwxr-x 1 oracle oinstall    10056 Jun 26 11:54 opatchdiag
-rwxrwxr-x 1 oracle oinstall    19867 Jun 26 11:54 opatch.bat
-rwx–x— 1 oracle oinstall    31493 Jun 26 11:54 opatch
-rw-rw-r– 1 oracle oinstall    23695 Jun 26 11:54 emdpatch.pl
drwxrwxr-x 2 oracle oinstall     4096 Jun 26 11:54 docs
drwxrwxr-x 3 oracle oinstall     4096 Jun 26 11:54 oplan
drwxrwxr-x 3 oracle oinstall     4096 Jun 26 11:54 jlib
drwxrwxr-x 3 oracle oinstall     4096 Jun 26 11:54 crs
drwxrwxr-x 4 oracle oinstall     4096 Jun 26 11:54 opatchprereqs
drwxrwxr-x 5 oracle oinstall     4096 Jun 26 11:54 ocm
-rw-rw-r– 1 oracle oinstall     2147 Aug 20 02:22 PatchSearch.xml
-rw-r–r– 1 oracle oinstall 32996451 Aug 20 22:07 p6880880_112000_Linux-x86-64.zip

And finally after deploying last patch, we have the latest OPatch version available.

[oracle@prashant OPatch]$ opatch version
OPatch Version: 11.2.0.3.5

OPatch succeeded.

Now, we can go and deploy our PSU Patch.

[oracle@prashant OPatch]$ cd 12419378/
[oracle@prashant 12419378]$ opatch apply

Oracle Interim Patch Installer version 11.2.0.3.5
Copyright (c) 2013, Oracle Corporation.  All rights reserved.

Oracle Home       : /u01/app/oracle/product/11.2.0/db_1
Central Inventory : /u01/app/oraInventory
from           : /u01/app/oracle/product/11.2.0/db_1/oraInst.loc
OPatch version    : 11.2.0.3.5
OUI version       : 11.2.0.1.0
Log file location : /u01/app/oracle/product/11.2.0/db_1/cfgtoollogs/opatch/12419

Applying interim patch ‘12419378’ to OH ‘/u01/app/oracle/product/11.2.0/db_1’
Verifying environment and performing prerequisite checks…
Patch 12419378: Optional component(s) missing : [ oracle.client, 11.2.0.1.0 ]
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 = ‘/u01/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…

Patching component oracle.rdbms.rsf, 11.2.0.1.0…

Patching component oracle.rdbms.dbscripts, 11.2.0.1.0…

Patching component oracle.rdbms, 11.2.0.1.0…

Patching component oracle.oraolap, 11.2.0.1.0…

Patching component oracle.rdbms.deconfig, 11.2.0.1.0…

Patching component oracle.javavm.server, 11.2.0.1.0…

Patching component oracle.precomp.common, 11.2.0.1.0…

Patching component oracle.network.rsf, 11.2.0.1.0…

Patching component oracle.network.listener, 11.2.0.1.0…

Patching component oracle.rdbms.dv.oc4j, 11.2.0.1.0…

Patching component oracle.sdo.locator, 11.2.0.1.0…

Patching component oracle.sysman.console.db, 11.2.0.1.0…

Patching component oracle.sysman.oms.core, 10.2.0.4.2…

Patching component oracle.rdbms.dv, 11.2.0.1.0…

Patching component oracle.xdk.rsf, 11.2.0.1.0…

Patching component oracle.ldap.rsf.ic, 11.2.0.1.0…

Patching component oracle.ldap.rsf, 11.2.0.1.0…

Patching component oracle.sysman.plugin.db.main.repository, 11.2.0.1.0…

Verifying the update…
Patch 12419378 successfully applied
Log file location: /u01/app/oracle/product/11.2.0/db_1/cfgtoollogs/opatch/12419378_Aug_20_2013_22_38_06/apply2013-08-20_22-38-06PM_1.log

OPatch succeeded.

Let’s Check the status of patch applied.
[oracle@prashant OPatch]$ opatch lsinventory
Oracle Interim Patch Installer version 11.2.0.3.5
Copyright (c) 2013, Oracle Corporation.  All rights reserved.

Oracle Home       : /u01/app/oracle/product/11.2.0/db_1
Central Inventory : /u01/app/oraInventory
from           : /u01/app/oracle/product/11.2.0/db_1/oraInst.loc
OPatch version    : 11.2.0.3.5
OUI version       : 11.2.0.1.0
Log file location : /u01/app/oracle/product/11.2.0/db_1/cfgtoollogs/opatch/opatch2013-08-20_22-56-30PM_1.log

Lsinventory Output file location : /u01/app/oracle/product/11.2.0/db_1/cfgtoollogs/opatch/lsinv/lsinventory2013-08-20_22-56-30PM.txt

——————————————————————————–
Installed Top-level Products (1):

Oracle Database 11g                                                  11.2.0.1.0
There are 1 products installed in this Oracle Home.

Interim patches (1) :

Patch  12419378     : applied on Tue Aug 20 22:41:38 IST 2013
Unique Patch ID:  13710328
Created on 8 Jul 2011, 02:48:54 hrs PST8PDT
Bugs fixed:
9068088, 9363384, 8865718, 8898852, 8801119, 9054253, 8725286, 8974548
9093300, 8909984, 8755082, 8780372, 9952216, 8664189, 8769569, 7519406
9302343, 9471411, 8822531, 7705591, 8650719, 10205230, 9637033, 8883722
8639114, 8723477, 8729793, 8919682, 8856478, 9001453, 8733749, 8565708
8735201, 8684517, 8870559, 8773383, 8981059, 8812705, 9488887, 12534742
8813366, 12534743, 9242411, 12534745, 12534746, 12534747, 8822832
12534748, 8897784, 8760714, 12534749, 8775569, 8671349, 8898589, 9714832
8642202, 9011088, 9369797, 9170608, 9165206, 8834636, 8891037, 8431487
8570322, 8685253, 8872096, 8718952, 8799099, 12534750, 9032717, 9399090
12534751, 12534752, 9713537, 9546223, 12534753, 12534754, 8588519
8783738, 12534755, 12534756, 8834425, 9454385, 8856497, 8890026, 8721315
10248516, 8818175, 8674263, 10249532, 9145541, 8720447, 9272086, 9467635
9010222, 9102860, 9197917, 8991997, 8661168, 8803762, 12419378, 8769239
9654983, 8706590, 8546356, 10408903, 8778277, 9058865, 8815639, 11724991
9971778, 9971779, 9027691, 9454036, 9454037, 9454038, 8761974, 9255542
9275072, 8496830, 8702892, 8818983, 8475069, 8875671, 9328668, 8891929
8798317, 9971780, 8782959, 8774868, 8820324, 8544696, 8702535, 9952260
9406607, 8268775, 9036013, 9363145, 8933870, 8405205, 9467727, 8822365
9676419, 11724930, 8761260, 8790767, 8795418, 8913269, 8717461, 8861700
9531984, 8607693, 8780281, 8330783, 8784929, 8780711, 9341448, 9015983
10323077, 8828328, 9119194, 10323079, 8832205, 8717031, 8665189, 9482399
9676420, 9399991, 8821286, 8633358, 9321701, 9655013, 9231605, 8796511
9167285, 8782971, 8756598, 8703064, 9390484, 9066116, 9007102, 9461782
10323080, 10323081, 10323082, 8753903, 8505803, 9382101, 9352237, 9216806
8918433, 11794163, 9057443, 8790561, 11794164, 8733225, 8795792, 11794165
11794167, 9067282, 8928276, 8837736, 9210925

——————————————————————————–

OPatch succeeded.

 

MOSC Note: 1066937.1

Thanks
Prashant Dixit
“Sharing is Good”

Posted in Advanced | Tagged: , | Leave a Comment »

EMCTL Error (OC4J Configuration Issue)

Posted by FatDBA on April 12, 2013

Noticed that some of my test databases monitored in OEM Grid Control started showing status of ‘Agent Unreachable’. This is what we are getting when we tried checking status of the Agent on the servers …

[oracle@prashant ~]$ emctl status dbconsole
OC4J Configuration issue. /u01/app/oracle/product/11.2.0/db_1/oc4j/j2ee/OC4J_DBConsole_prashant_orcl not found.

Below provided steps are sequence of steps that we should adopt in such scenario and will help us to fix the issue most of the times.

  • Set the SID
  • Drop/Deconfig current EM repository.
  • Recreate EM repository for the same DB.
  • Re-check the Status using EMCTL commands for both Dbconsole & Agent

1. Set the SID
[oracle@prashant ~]$ echo $ORACLE_SID
orcl

2. Drop/Deconfig current EM repository.
This step will require you to feed deconfig process following details.
SID, Listener Port Number, SYS and SYSMAN Password.

[oracle@prashant ~]$ emca -deconfig dbcontrol db -repos drop;

STARTED EMCA at Apr 12, 2013 10:40:14 PM
EM Configuration Assistant, Version 11.2.0.0.2 Production
Copyright (c) 2003, 2005, Oracle.  All rights reserved.

Enter the following information:
Database SID: orcl
Listener port number: 1521
Password for SYS user:
Password for SYSMAN user:

Do you wish to continue? [yes(Y)/no(N)]: Y

Apr 12, 2013 10:41:14 PM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /u01/app/oracle/cfgtoollogs/emca/REDANT/emca_2013_04_12_22_40_14.log.
Apr 12, 2013 10:41:14 PM oracle.sysman.emcp.EMDBPreConfig performDeconfiguration
WARNING: EM is not configured for this database. No EM-specific actions can be performed.
Apr 12, 2013 10:41:14 PM oracle.sysman.emcp.ParamsManager checkListenerStatusForDBControl
WARNING: Error initializing SQL connection. SQL operations cannot be performed
Apr 12, 2013 10:41:14 PM oracle.sysman.emcp.EMReposConfig invoke
INFO: Dropping the EM repository (this may take a while) …

Apr 12, 2013 10:45:42 PM oracle.sysman.emcp.EMReposConfig invoke
INFO: Repository successfully dropped
Enterprise Manager configuration completed successfully
FINISHED EMCA at Apr 12, 2013 10:45:43 PM

3. Recreate EM repository for the same DB.
This step will require you to feed config process following details.
SID, Listener Port Number, Email address (Optional), SMTP server details (Optional) along with SYS and DBSNMP and SYSMAN Password.

[oracle@prashant ~]$ emca -config dbcontrol db -repos create;

STARTED EMCA at Apr 12, 2013 10:46:17 PM
EM Configuration Assistant, Version 11.2.0.0.2 Production
Copyright (c) 2003, 2005, Oracle.  All rights reserved.

Enter the following information:
Database SID: orcl
Listener port number: 1521
Listener ORACLE_HOME [ /u01/app/oracle/product/11.2.0/db_1 ]:
Password for SYS user:
Password for DBSNMP user:
Password for SYSMAN user:
Email address for notifications (optional):
Outgoing Mail (SMTP) server for notifications (optional):
—————————————————————–

You have specified the following settings

Database ORACLE_HOME ……………. /u01/app/oracle/product/11.2.0/db_1

Local hostname ……………. prashant
Listener ORACLE_HOME ……………. /u01/app/oracle/product/11.2.0/db_1
Listener port number ……………. 1521
Database SID ……………. orcl
Email address for notifications ……………
Outgoing Mail (SMTP) server for notifications ……………

—————————————————————–
Do you wish to continue? [yes(Y)/no(N)]:

Apr 12, 2013 10:46:59 PM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /u01/app/oracle/cfgtoollogs/emca/REDANT/emca_2013_04_12_22_46_16.log.
Apr 12, 2013 10:47:00 PM oracle.sysman.emcp.EMReposConfig createRepository
INFO: Creating the EM repository (this may take a while) …

Apr 12, 2013 10:54:15 PM oracle.sysman.emcp.EMReposConfig invoke
INFO: Repository successfully created
Apr 12, 2013 10:54:28 PM oracle.sysman.emcp.EMReposConfig uploadConfigDataToRepository
INFO: Uploading configuration data to EM repository (this may take a while) …
Apr 12, 2013 10:55:43 PM oracle.sysman.emcp.EMReposConfig invoke
INFO: Uploaded configuration data successfully
Apr 12, 2013 10:55:47 PM oracle.sysman.emcp.util.DBControlUtil configureSoftwareLib
INFO: Software library configured successfully.
Apr 12, 2013 10:55:47 PM oracle.sysman.emcp.EMDBPostConfig configureSoftwareLibrary
INFO: Deploying Provisioning archives …
Apr 12, 2013 10:56:06 PM oracle.sysman.emcp.EMDBPostConfig configureSoftwareLibrary
INFO: Provisioning archives deployed successfully.
Apr 12, 2013 10:56:06 PM oracle.sysman.emcp.util.DBControlUtil secureDBConsole
INFO: Securing Database Control (this may take a while) …
Apr 12, 2013 10:56:40 PM oracle.sysman.emcp.util.DBControlUtil secureDBConsole
INFO: Database Control secured successfully.
Apr 12, 2013 10:56:40 PM oracle.sysman.emcp.util.DBControlUtil startOMS
INFO: Starting Database Control (this may take a while) …

Apr 12, 2013 10:57:23 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration
INFO: Database Control started successfully
Apr 12, 2013 10:57:23 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration
INFO: >>>>>>>>>>> The Database Control URL is https://prashant:5500/em <<<<<<<<<<<
Apr 12, 2013 10:57:32 PM oracle.sysman.emcp.EMDBPostConfig invoke
WARNING:
************************  WARNING  ************************

Management Repository has been placed in secure mode wherein Enterprise Manager data will be encrypted.  The encryption key has been placed in the file: /u01/app/oracle/product/11.2.0/db_1/prashant_REDANT/sysman/config/emkey.ora.   Please ensure this file is backed up as the encrypted data will become unusable if this file is lost.

***********************************************************
Enterprise Manager configuration completed successfully

4. Re-check the Status using EMCTL commands for both Dbconsole & Agent.

[oracle@prashant ~]$ emctl status dbconsole
Oracle Enterprise Manager 11g Database Control Release 11.2.0.1.0
Copyright (c) 1996, 2009 Oracle Corporation.  All rights reserved.
https://prashant:5500/em/console/aboutApplication
Oracle Enterprise Manager 11g is running.
——————————————————————
Logs are generated in directory /u01/app/oracle/product/11.2.0/db_1/prashant_REDANT/sysman/log

[oracle@prashant ~]$ emctl status agent
Oracle Enterprise Manager 11g Database Control Release 11.2.0.1.0
Copyright (c) 1996, 2009 Oracle Corporation.  All rights reserved.
—————————————————————
Agent Version     : 10.2.0.4.2
OMS Version       : 10.2.0.4.2
Protocol Version  : 10.2.0.4.2
Agent Home        : /u01/app/oracle/product/11.2.0/db_1/prashant_REDANT
Agent binaries    : /u01/app/oracle/product/11.2.0/db_1
Agent Process ID  : 26794
Parent Process ID : 26757
Agent URL         : https://prashant:3938/emd/main
Repository URL    : https://prashant:5500/em/upload/
Started at        : 2013-04-12 22:56:42
Started by user   : oracle
Last Reload       : 2013-04-12 22:56:42
Last successful upload                       : 2013-04-12 22:58:34
Total Megabytes of XML files uploaded so far :    10.04
Number of XML files pending upload           :        0
Size of XML files pending upload(MB)         :     0.00
Available disk space on upload filesystem    :    26.87%
Data channel upload directory                : /u01/app/oracle/product/11.2.0/db_1/prashant_REDANT/sysman/recv
Last successful heartbeat to OMS             : 2013-04-12 22:58:24
—————————————————————
Agent is Running and Ready

 

OEM Final screen is up!

Untitled

Posted in Advanced | Tagged: , | Leave a Comment »

 
%d bloggers like this: