Oracle dbms_registry problems

Sometimes, especially after a clone or an upgrade you may find that some packages within Oracle Database do not work as you would expect. For example, creating the repository for enterprise manager may result in the following failure:
BEGIN dbms_registry.valid(‘EM’); END;
PLS-00302 Component ‘VALID’ must be declared

Also if you run utlrp.sql, you may encounter the following error:
ORA-00904: “DBMS_REGISTRY”.”TIME_STAMP”: invalid identifier
SELECT dbms_registry_sys.time_stamp(‘utlrp_end’) as timestamp from dual*ERROR at line 1:ORA-04063: package body “SYS.DBMS_REGISTRY_SYS” has errorsBEGIN dbms_registry_sys.validate_components; END;*ERROR at line 1:ORA-04063: package body “SYS.DBMS_REGISTRY_SYS” has errorsORA-06508: PL/SQL: could not find program unit being called:”SYS.DBMS_REGISTRY_SYS”ORA-06512: at line 1
The solution is simple, recreate using catalog and catproc:

shutdown immediate
startup upgrade
shutdown immediate
check the registry – select comp_name,version,status from dba_registry;
I hope this helps someone out there.

Discover Your Opportunities

Data Solutions | Application Development | Automation