HOWTO: Resurrect your xdbconfig file when it gets corrupted

Flavio Casetta, has a great post on his blog “Annals of Oracle’s Improbable Errors” on how to resurrect the xdbconfig.xml when it gets corrupted due, for instance in his case, an unlucky update via WebDAV. This caused the brilliant Oracle error code: ORA-31114: XDB configuration has been deleted or is corrupted . The solution pointed out by Oracle, isn’t very hope giving (“rebuild XDB environment”), but Flavio demonstrates in his blog post a great workaround (and he is a brave man doing it on XE / 10.1).

Probably xdbconfig.xml is somewhere hidden in XDB.XDB$RESOURCE and/or XDB.XDB$SCHEMA and could maybe distilled from this, but I guess this would be a good exercise for the upcoming bank holidays when my general DBA duties allow me a little more sparring time with my Oracle 11g XMLDB VM environment. Trying to perfect such a recovery method could be a good thing, because a lot of functionality is and/or will depend on it like APEX or the NDWS functionality.

Flavio has more good posts on XMLDB. Have a look here: Search XMLDB

Marco Gralike Written by:

One Comment

  1. May 26

    I know now better…

    The xdbconfig.xml file is stored in XDB$CONFIG.

    Addition on 16/07/15 (DBMS_XDB_ADMIN):

     SELECT r.object_value.getclobval(),ri.*
      --INTO ROOTOID
      FROM XDB.XDB$RESOURCE R,
        XDB.XDB$ROOT_INFO RI
      WHERE R.ROWID  = RI.RESOURCE_ROOT;
    

Comments are closed.