12.2 DataPump Export (EXPDP) Fails Exporting Full PDB Due To ORA-39126 On KUPW$WORKER.FETCH_XML_OBJECTS

(Doc ID 2361799.1)

Last updated on APRIL 11, 2018

Applies to:

Oracle Database - Enterprise Edition - Version 12.2.0.1 and later
Information in this document applies to any platform.
Database does not have Data Vault Installed.
Database upgraded from 11.2.X to 12.2

Symptoms

Starting a DataPump Export job to run a full PDB export in 12.2.0.1, fails with the following errors:

ORA-39126: Worker unexpected fatal error in KUPW$WORKER.FETCH_XML_OBJECTS [ORA-00942: table or view does not exist]

ORA-06512: at "SYS.DBMS_SYS_ERROR", line 105
ORA-06512: at "SYS.KUPW$WORKER", line 12098
ORA-06512: at "SYS.DBMS_SYS_ERROR", line 105
ORA-06512: at "SYS.DBMS_METADATA", line 9039
ORA-06512: at "SYS.DBMS_METADATA", line 2792
ORA-06512: at "SYS.DBMS_METADATA", line 3423
ORA-06512: at "SYS.DBMS_METADATA", line 4760
ORA-06512: at "SYS.DBMS_METADATA", line 5079
ORA-06512: at "SYS.DBMS_METADATA", line 9020
ORA-06512: at "SYS.KUPW$WORKER", line 14367

----- PL/SQL Call Stack -----
object line object
handle number name
0x1201393a0 32239 package body SYS.KUPW$WORKER.WRITE_ERROR_INFORMATION
0x1201393a0 12119 package body SYS.KUPW$WORKER.DETERMINE_FATAL_ERROR
0x1201393a0 14693 package body SYS.KUPW$WORKER.FETCH_XML_OBJECTS
0x1201393a0 3689 package body SYS.KUPW$WORKER.UNLOAD_METADATA
0x1201393a0 13063 package body SYS.KUPW$WORKER.DISPATCH_WORK_ITEMS
0x1201393a0 2311 package body SYS.KUPW$WORKER.MAIN
0x76dc0a40 2 anonymous block

DBMS_METADATA.SET_FILTER
DBMS_METADATA.SET_FILTER
DBMS_METADATA.SET_FILTER
In FETCH_XML_OBJECTS
End seqno is: 24
KUPF$FILE.OPEN_CONTEXT
KUPF$FILE.OPEN_CONTEXT
DBMS_METADATA.FETCH_XML_CLOB
DBMS_METADATA.FETCH_XML_CLOB
In procedure DETERMINE_FATAL_ERROR with ORA-00942: table or view does not exist


After enabling tracing for ORA-00942 error with "alter system set events '942 trace name ERRORSTACK level 3' ", revealed that the missing tables are all Database Vault related.
The generated trace file shows that DVSYS.KU$_DV_ISR_VIEW KU$ does not exist in PDB, hence causing PDB expdp job to fail:

----- Current SQL Statement for this session (sql_id=64jrvm6j446x3) -----
SELECT /*+all_rows*/ SYS_XMLGEN(VALUE(KU$), XMLFORMAT.createFormat2('DVPS_IMPORT_STAGING_REALM_T', '7')), 0 , 'DVPS_IMPORT_STAGING_REALM' FROM DVSYS.KU$_DV_ISR_VIEW KU$;


Running same query on CDB and PDB showing that DVSYS.KU$_DV_ISR_VIEW KU$ table exist in CDB$ROOT but it does not exist in PDB:


From CDB$ROOT
SQL> SELECT
2 /*+all_rows*/ SYS_XMLGEN(VALUE(KU$), XMLFORMAT.createFormat2('DVPS_IMPORT_STAGING_REALM_T', '7')), 0 ,'DVPS_IMPORT_STAGING_REALM'
3 FROM
4 DVSYS.KU$_DV_ISR_VIEW KU$
5 /

From PDB

SQL> alter session set container=test_pdb;
Session altered.

SQL> SELECT
2 /*+all_rows*/ SYS_XMLGEN(VALUE(KU$), XMLFORMAT.createFormat2('DVPS_IMPORT_STAGING_REALM_T', '7')), 0 ,'DVPS_IMPORT_STAGING_REALM'
3 FROM
4 DVSYS.KU$_DV_ISR_VIEW KU$
5 /
DVSYS.KU$_DV_ISR_VIEW KU$
*
ERROR at line 4:
ORA-00942: table or view does not exist


DVSYS schema and DV objects exist in metaview$ at CDB$ROOT level, even if Database Vault is not enabled:

SQL> select viewname from metaview$ where schema ='DVSYS';

VIEWNAME
-------------------------------------------------------------
KU$_DV_REALM_VIEW
KU$_DV_REALM_MEMBER_VIEW
KU$_DV_REALM_AUTH_VIEW
KU$_DV_ISR_VIEW
KU$_DV_ISRM_VIEW
KU$_DV_ISR_VIEW
KU$_DV_RULE_VIEW
KU$_DV_RULE_SET_VIEW
KU$_DV_RULE_SET_MEMBER_VIEW
KU$_DV_COMMAND_RULE_VIEW
KU$_DV_COMM_RULE_ALTS_V
KU$_DV_AUTH_DP_V
KU$_DV_AUTH_TTS_V
KU$_DV_AUTH_JOB_V
KU$_DV_AUTH_PROXY_V
KU$_DV_AUTH_DDL_V
KU$_DV_AUTH_PREP_V
KU$_DV_AUTH_MAINT_V
KU$_DV_AUTH_DIAG_V
KU$_DV_INDEX_FUNC_V
KU$_DV_ORADEBUG_V
KU$_DV_ACCTS_V


 

Changes

Database was upgraded from 11.2.X to 12.2.
The error is seen in an Multitenant environment where Database Vault is not enabled.
One has to execute the following command to see whether the Oracle software was compiled with the dv_on option:

$ ar -t libknlopt.a | grep -c kzvidv.o

For IBM AIX:
$ ar -X64 -t libknlopt.a | grep -c kzvidv.o

- If the output is 0, the option is disabled.
- If the output is 1, the option is enabled.

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms