I faced with that error during export process on Oracle 12c RAC database

Complete error message is:

ORA-39127: unexpected error from call to local_str := SYS.DBMS_EXPORT_EXTENSION.GET_DOMAIN_INDEX_METADATA(‘INDEX_NAME_HERE’,’SCHEMA_NAME_HERE’,’TEXTINDEXMETHODS’,’CTXSYS’,,newblock,0) ORA-20000: Oracle Text error: DRG-10502: index SCHEMA_NAME_HERE”.”INDEX_NAME_HERE does not exist ORA-06512: at “SYS.DBMS_EXPORT_EXTENSION”, line 274 ORA-06512: at line 1 ORA-06512: at “SYS.DBMS_METADATA”, line 9524

After investigate issue I found ORA-39127 ORA-20000 DRG-10502 Errors when Doing EXPDP (Doc ID 979047.1)

So here is the steps:

1.What is cause for that error? Here is the answer:

The errors are thrown because the domain index has status FAILED, visible in USER_/DBA_INDEXES view, and no entry exists in Text data dictionary, ctxsys schema.
ONLY metadata of VALID domain indexes are exported.

  1. Use below query to see exact status of index

select index_name, status, domidx_status, domidx_opstatus from dba_indexes where index_type = ‘DOMAIN’ and domidx_opstatus = ‘FAILED’;

Export is fail because domidx_opstatus in failed status.

  1. You mat try to drop and re-create index or if the indexes are not used then drop them.

In my case even i re-create index domidx_opstatus still in failed status. So I checked latest usage of index. It seems it doesnt access than i decided to drop index.