问题:
用户在使用expdp进程导出时,出现队列报错ORA-39077、ORA-06502
ORA-31626: job does not exist
ORA-31638: cannot attach to job SYS_EXPORT_SCHEMA_01 for user SYS
ORA-06512: at "SYS.DBMS_SYS_ERROR", line 95
ORA-06512: at "SYS.KUPV$FT_INT", line 428
ORA-39077: unable to subscribe agent KUPC$A_1_100518811923000 to queue "KUPC$C_1_20230727100518"
ORA-06512: at "SYS.DBMS_SYS_ERROR", line 95
ORA-06512: at "SYS.KUPC$QUE_INT", line 254
ORA-06502: PL/SQL: numeric or value error: character string buffer too small
问题处理:
该问题是Bug 16928674所导致,12.2.0.1以下数据库版本都会受此影响
由于expdp执行次数过多导致作业队列所所调用的序列当前值超过6位,会触发该bug
可以通过查询序列的当前值,确认是否匹配该问题
set linesize 400
set numwidth 40
select sequence_owner,sequence_name,MIN_VALUE,MAX_VALUE,INCREMENT_BY,LAST_NUMBER
from dba_sequences
where sequence_name='AQ$_KUPC$DATAPUMP_QUETAB_N';
修复方法:
1 应用补丁16928674进行修复
or
2 重键datapump组件的数据字典
@$ORACLE_HOME/rdbms/admin/catdph.sql
@$ORACLE_HOME/rdbms/admin/prvtdtde.plb
@$ORACLE_HOME/rdbms/admin/catdpb.sql
@$ORACLE_HOME/rdbms/admin/dbmspump.sql
@$ORACLE_HOME/rdbms/admin/utlrp.sql