ORA-01918: user 'DVSYS' does not exist While Installing the PSU July DataPatch 23054246

Patch 23054246 apply: WITH ERRORS Error at line 33473: Warning: Package altered with compilation err /
ORA-01918: user 'DVSYS' does not exist While Installing the PSU July DataPatch 23054246
/
Patching on upgraded database 

Symptoms


[oracle@hostname OPatch]$./datapatch -verbose
SQL Patching tool version 12.1.0.2.0 on Fri Aug  5 10:40:38 2016
Copyright (c) 2016, Oracle.  All rights reserved.

Log file for this invocation: /u01/app/oracle/cfgtoollogs/sqlpatch/sqlpatch_55992_2016_08_05_10_40_38/sqlpatch_invocation.log

Connecting to database...OK
Bootstrapping registry and package to current versions...done
Determining current state...done
Adding patches to installation queue and performing prereq checks...
Installation queue:
 Nothing to roll back
 The following patches will be applied:
   23054246 (Database Patch Set Update : 12.1.0.2.160719 (23054246))

Installing patches...
Patch installation complete.  Total patches installed: 1

Validating logfiles...
Patch 23054246 apply: WITH ERRORS
 logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/23054246/20464632/23054246_apply_xxxxxxxx_2016Aug05_10_41_25.log (errors)
   Error at line 33473: Warning: Package altered with compilation errors.
Please refer to MOS Note 1609718.1 and/or the invocation log
/u01/app/oracle/cfgtoollogs/sqlpatch/sqlpatch_55992_2016_08_05_10_40_38/sqlpatch_invocation.log
for information on how to resolve the above errors.
SQL Patching tool complete on Fri Aug  5 10:41:29 2016


SYS@hostname> SELECT patch_id, version, status, bundle_id, bundle_series FROM dba_registry_sqlpatch;

 PATCH_ID VERSION              STATUS           BUNDLE_ID BUNDLE_SERIES
---------- -------------------- --------------- ---------- ------------------------------
 23177536 12.1.0.2             SUCCESS
 23054246 12.1.0.2             WITH ERRORS         160719 PSU
 22291127 12.1.0.2             WITH ERRORS         160719 PSU


[oracle@hostname OPatch]$./datapatch -apply 23054246 -force -verbose
SQL Patching tool version 12.1.0.2.0 on Fri Aug  5 11:00:03 2016
Copyright (c) 2016, Oracle.  All rights reserved.

Log file for this invocation: /u01/app/oracle/cfgtoollogs/sqlpatch/sqlpatch_64936_2016_08_05_11_00_03/sqlpatch_invocation.log

Connecting to database...OK
Determining current state...done

Current state of SQL patches:
Patch 23054246 ():
 Not installed in binary or the SQL registry

Adding patches to installation queue and performing prereq checks...
Installation queue:
 Nothing to roll back
 The following patches will be applied:
   23054246 ()

Installing patches...
Patch installation complete.  Total patches installed: 1

Validating logfiles...
Patch 23054246 apply: WITH ERRORS
 logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/23054246/20464632/23054246_apply_xxxxxxxx_2016Aug05_11_00_03.log (errors)
   Error at line 32899: ORA-04042: procedure, function, package, or package body does not exist
   Error at line 33132: ORA-01918: user 'DVSYS' does not exist
   Error at line 33155: ORA-06550: line 5, column 37:
   Error at line 33157: ORA-06550: line 5, column 1:
   Error at line 33177: ORA-01918: user 'DVSYS' does not exist
   Error at line 33200: ORA-06550: line 5, column 37:
   Error at line 33202: ORA-06550: line 5, column 1:
   Error at line 33233: ORA-01918: user 'DVSYS' does not exist
   Error at line 33262: ORA-01918: user 'DVSYS' does not exist
   Error at line 33287: ORA-01918: user 'DVSYS' does not exist
   Error at line 33316: ORA-01918: user 'DVSYS' does not exist
   Error at line 33355: ORA-01918: user 'DVSYS' does not exist
   Error at line 33379: ORA-01918: user 'DVSYS' does not exist
   Error at line 33406: ORA-01918: user 'DVSYS' does not exist
   Error at line 33431: ORA-01918: user 'DVSYS' does not exist
   Error at line 33465: ORA-01918: user 'DVSYS' does not exist
   Error at line 33495: ORA-01918: user 'DVSYS' does not exist
   Error at line 33525: ORA-01918: user 'DVSYS' does not exist
   Error at line 33555: ORA-01918: user 'DVSYS' does not exist
   Error at line 33587: ORA-01918: user 'DVSYS' does not exist
   Error at line 33615: ORA-01918: user 'DVSYS' does not exist
   Error at line 33639: ORA-01918: user 'DVSYS' does not exist
   Error at line 33669: ORA-01918: user 'DVSYS' does not exist
   Error at line 33700: ORA-01918: user 'DVSYS' does not exist
   Error at line 33734: ORA-01918: user 'DVSYS' does not exist
   Error at line 33760: ORA-01918: user 'DVSYS' does not exist
   Error at line 33792: ORA-01918: user 'DVSYS' does not exist
   Error at line 33824: ORA-01918: user 'DVSYS' does not exist
   Error at line 33854: ORA-01918: user 'DVSYS' does not exist
   Error at line 33879: ORA-01918: user 'DVSYS' does not exist
   Error at line 33938: ORA-01918: user 'DVSYS' does not exist
   Error at line 34166: ORA-01918: user 'DVSYS' does not exist
   Error at line 34236: ORA-01918: user 'DVSYS' does not exist
   Error at line 39035: Warning: View created with compilation errors.
   Error at line 39084: Warning: View created with compilation errors.
   Error at line 39140: Warning: View created with compilation errors.
   Error at line 39190: Warning: View created with compilation errors.
   Error at line 39249: Warning: View created with compilation errors.
   Error at line 39302: Warning: View created with compilation errors.
   Error at line 39382: Warning: View created with compilation errors.
   Error at line 39436: Warning: View created with compilation errors.
   Error at line 39484: Warning: View created with compilation errors.
   Error at line 39531: Warning: View created with compilation errors.
   Error at line 39645: Warning: View created with compilation errors.
   Error at line 39692: Warning: View created with compilation errors.
   Error at line 39737: Warning: View created with compilation errors.
   Error at line 39782: Warning: View created with compilation errors.
   Error at line 39846: Warning: View created with compilation errors.
   Error at line 45402: ORA-04042: procedure, function, package, or package body does not exist
   Error at line 45410: ORA-04042: procedure, function, package, or package body does not exist
   Error at line 45418: ORA-04042: procedure, function, package, or package body does not exist
   Error at line 45426: ORA-04042: procedure, function, package, or package body does not exist
   Error at line 45434: ORA-04042: procedure, function, package, or package body does not exist
   Error at line 45442: ORA-04042: procedure, function, package, or package body does not exist
   Error at line 45450: ORA-04042: procedure, function, package, or package body does not exist
   Error at line 45458: ORA-04042: procedure, function, package, or package body does not exist
   Error at line 45467: ORA-04042: procedure, function, package, or package body does not exist
   Error at line 45475: ORA-04042: procedure, function, package, or package body does not exist
   Error at line 45856: ORA-04042: procedure, function, package, or package body does not exist
   Error at line 45865: ORA-04042: procedure, function, package, or package body does not exist
   Error at line 45873: ORA-04042: procedure, function, package, or package body does not exist
   Error at line 46659: ORA-04042: procedure, function, package, or package body does not exist
   Error at line 46666: ORA-04042: procedure, function, package, or package body does not exist
   Error at line 46673: ORA-04042: procedure, function, package, or package body does not exist
   Error at line 46976: ORA-01400: cannot insert NULL into ("SYS"."OBJAUTH$"."OBJ#")
   Error at line 47885: ORA-06550: line 9, column 24:
   Error at line 47887: ORA-06550: line 9, column 6:
   Error at line 47904: ORA-06550: line 2, column 21:
   Error at line 47906: ORA-06550: line 2, column 3:
   Error at line 47923: ORA-06550: line 2, column 21:
   Error at line 47925: ORA-06550: line 2, column 3:
   Error at line 48070: ORA-06550: line 2, column 11:
   Error at line 48071: PLS-00201: identifier 'DVSYS.DV$FACTOR' must be declared
   Error at line 48072: ORA-06550: line 2, column 11:
   Error at line 48074: ORA-06550: line 3, column 12:
   Error at line 48075: PLS-00201: identifier 'DVSYS.DV$FACTOR' must be declared
   Error at line 48076: ORA-06550: line 3, column 12:
   Error at line 48078: ORA-06550: line 4, column 18:
   Error at line 48079: PLS-00201: identifier 'DVSYS.DV$FACTOR' must be declared
   Error at line 48080: ORA-06550: line 4, column 18:
   Error at line 48082: ORA-06550: line 10, column 20:
   Error at line 48084: ORA-06550: line 9, column 9:
   Error at line 48086: ORA-06550: line 14, column 9:
   Error at line 48087: PLS-00320: the declaration of the type of this expression is incomplete or
   Error at line 48089: ORA-06550: line 14, column 9:
   Error at line 48091: ORA-06550: line 15, column 9:
   Error at line 48092: PLS-00320: the declaration of the type of this expression is incomplete or
   Error at line 48094: ORA-06550: line 15, column 9:
   Error at line 48096: ORA-06550: line 20, column 24:
   Error at line 48097: PLS-00320: the declaration of the type of this expression is incomplete or
   Error at line 48099: ORA-06550: line 20, column 13:
   Error at line 48101: ORA-06550: line 24, column 32:
   Error at line 48102: PLS-00201: identifier 'DVSYS.DBMS_MACUTL' must be declared
   Error at line 48103: ORA-06550: line 23, column 13:
   Error at line 48105: ORA-06550: line 26, column 24:
   Error at line 48106: PLS-00320: the declaration of the type of this expression is incomplete or
   Error at line 48108: ORA-06550: line 26, column 13:
   Error at line 48110: ORA-06550: line 30, column 61:
   Error at line 48111: PLS-00320: the declaration of the type of this expression is incomplete or
   Error at line 48113: ORA-06550: line 30, column 13:
   Error at line 49480: Warning: Package altered with compilation errors.

Please refer to MOS Note 1609718.1 and/or the invocation log
/u01/app/oracle/cfgtoollogs/sqlpatch/sqlpatch_64936_2016_08_05_11_00_03/sqlpatch_invocation.log
for information on how to resolve the above errors.

SQL Patching tool complete on Fri Aug  5 11:00:12 2016
[oracle@hostname OPatch]$




2. Cause

The DVSYS schema does not exist in the database that is being patched. There are two common reasons for this:
1) the DV metadata was removed for some reasons
2) the database was upgraded from an 11g database that did not have Database Vault installed


3. Resolution



1) Enable OLS ( this is needed if OLS' metadata is not installed yet) :

sqlplus / as sysdba
@?/rdbms/admin/catols.sql
exec lbacsys.configure_ols
exec lbacsys.ols_enforcement.enable_ols

restart the database

2) Run script catmac.sql :

sqlplus / as sysdba
@?/rdbms/admin/catmac.sql system temp <syspasswd>
3) If there are any invalid objects recompile them :

sqlplus / as sysdba
@?\rdbms\admin\utlrp.sql

4) Run the datapatch script again:
cd $ORACLE_HOME/OPatch

[oracle@hostname OPatch]$./datapatch -verbose
SQL Patching tool version 12.1.0.2.0 on Wed Sep 14 12:11:58 2016
Copyright (c) 2016, Oracle.  All rights reserved.

Log file for this invocation: /u01/app/oracle/cfgtoollogs/sqlpatch/sqlpatch_2760_2016_09_14_12_11_58/sqlpatch_invocation.log

Connecting to database...OK
Bootstrapping registry and package to current versions...done
Determining current state...done

Current state of SQL patches:
Patch 23054246 ():
 Installed in the binary registry only
Patch 23177536 (Database PSU 12.1.0.2.160719, Oracle JavaVM Component (JUL2016)):
 Installed in binary and the SQL registry
Bundle series PSU:
 ID 160719 in the binary registry and not installed in the SQL registry

Adding patches to installation queue and performing prereq checks...
Installation queue:
 Nothing to roll back
 The following patches will be applied:
   22291127 (Database Patch Set Update : 12.1.0.2.160419 (22291127))
   23054246 ()

Installing patches...
Patch installation complete.  Total patches installed: 2

Validating logfiles...
Patch 22291127 apply: SUCCESS
 logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/22291127/19694308/22291127_apply_xxxxxxxx_2016Sep14_12_12_45.log (no errors)
Patch 23054246 apply: SUCCESS
 logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/23054246/20464632/23054246_apply_xxxxxxxx_2016Sep14_12_12_49.log (no errors)
SQL Patching tool complete on Wed Sep 14 12:12:59 2016
[oracle@hostname OPatch]$


SYS@hostname> SELECT patch_id, version, status, bundle_id, bundle_series FROM dba_registry_sqlpatch;

 PATCH_ID VERSION              STATUS           BUNDLE_ID BUNDLE_SERIES
---------- -------------------- --------------- ---------- ------------------------------
 23177536 12.1.0.2             SUCCESS
 22291127 12.1.0.2             SUCCESS             160719 PSU
 23054246 12.1.0.2             SUCCESS




No comments:

Post a Comment