Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Oracle XML Database database invalid, how to validate/recompile … can i drop and recreate it.

Ken18Nov 8 2018 — edited Nov 13 2018

Hi All,

The installed components and their status,

Oracle Database Catalog Views                 12.1.0.2.0               Valid

Oracle Database Packages and Types      12.1.0.2.0                Valid

Oracle XML Database                                12.1.0.2.0                Loaded

The XML Database component states as loaded, as there are invalid objects.

--> Tried to recompile invalid objects by running utlrp.sql but no use, still the invalid objects exist.

--> Unable to expdp/impdp due to metadata errors, unable to run scripts like extract tablespace ddl's etc

ORA-04063: package body "SYS.DBMS_METADATA" has errors 04063. 00000 - "%s has errors"

*Cause: Attempt to execute a stored procedure or use a view that has errors.

For stored procedures, the problem could be syntax errors or references to other, non-existent procedures.

For views, the problem could be a reference in the view's defining query to a non-existent table.

Can also be a table which has references to non-existent or inaccessible types.

*Action: Fix the errors and/or create referenced objects as necessary

SQL> select any_path from resource_view;

select any_path from resource_view

                     *

ERROR at line 1:

ORA-01775: looping chain of synonyms

Tried the below solutions as per oracle support doc ID's, but still the issue persists...  did anyone came across this ?

Is there a any workaround or is raising SR is the only way to fix the XDB/SYS invalid objects.

Does upgrading to 12.2 would be successful in this case.

1)

Master Note for Oracle XML Database (XDB) Install / Deinstall (Doc ID 1292089.1)

Oracle 10.1 and above - XDB Reload

spool xdbreload.log
connect / as sysdba
set echo on;
shutdown immediate;
startup upgrade;
@?/rdbms/admin/xdbrelod.sql
shutdown immediate;
startup;
@?/rdbms/admin/utlrp.sql
spool off

2)

XDB is INVALID in DBA_REGISTRY after Fresh Installation (Doc ID 1297620.1)

3) Oracle XML Database (XDB) Installation on 12c - XDB invalid status after fresh installation/upgrade (Doc ID 2222780.1)

Thanks

Kenny

Comments
Post Details
Added on Nov 8 2018
1 comment
6,421 views