Friday, February 8, 2019

Oracle XML Database invalid, could not find xdbconfig

Hello Guys,


In one of our EBS customer have many invalids in database and we try to compile them using utrp.sql and eventually failed with below error.


DECLARE
*
ERROR at line 1:
ORA-04063: package body "SYS.DBMS_SQLTUNE" has errors
ORA-06508: PL/SQL: could not find program unit being called: "SYS.DBMS_SQLTUNE"
ORA-06512: at "SYS.UTL_RECOMP", line 875
ORA-06512: at line 4


We've found few components in dba_registry shows INVALID.


COMP_NAME           COMP_ID  VERSION  STATUS
------------------------------ ---------- ---------- ----------
Oracle XML Database      XDB    12.1.0.2.0 INVALID
Oracle Database Packages and T CATPROC  12.1.0.2.0 INVALID
Oracle OLAP API        XOQ    12.1.0.2.0 INVALID


To over come the issue. Please follow below steps.


For CATPROC component:
If there has been no recent database upgrade taking place, the following set of commands may help validating them:
$ sqlplus / as sysdba
@$ORACLE_HOME/rdbms/admin/catalog.sql
@$ORACLE_HOME/rdbms/admin/catproc.sql
@$ORACLE_HOME/rdbms/admin/utlrp.sql
--
-- usually, <utlrp.sql> has to be executed couple of more times for dependency reasons
--
@$ORACLE_HOME/rdbms/admin/utlrp.sql
@$ORACLE_HOME/rdbms/admin/utlrp.sql


for Rest of component:
start up the database in UPGRADE mode and connect ‘/as sysdba’ to execute any of the following scripts.


Oracle XML Database
SQL> @?/rdbms/admin/xdbpatch.sql


OLAP API
SQL> @?/olap/admin/xoqpatch.sql




How to Diagnose Components with NON VALID Status in DBA_REGISTRY after an Upgrade (Doc ID 753041.1)
IF: Invalid Catalog and/or Catproc Database Registry Components (Doc ID 2358487.1)


Thanks.
Sreeharsha


3 comments:

  1. Hello,

    I would like to say you THANK YOU SO MUCH!!! After a lot of hours trying to solve the same problem with XML (LOADED status) and OLAP (INVALID status) with none result, I have found your note and it was my salvation. :D

    Thanks for sharing it!!

    ReplyDelete