博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
ORA-06575: 程序包或函数 NO_VM_DROP_PROC 处于无效状态
阅读量:5788 次
发布时间:2019-06-18

本文共 2815 字,大约阅读时间需要 9 分钟。

SQL> drop user aaa ;
 
drop user aaa
 
ORA-00604: 递归 SQL 级别 1 出现错误
ORA-06575: 程序包或函数 NO_VM_DROP_PROC 处于无效状态
ORA-06512: 在 line 21
 
SQL> alter procedure WMSYS.NO_VM_DROP_PROC disable;
 
alter procedure WMSYS.NO_VM_DROP_PROC disable
 
ORA-00922: 选项缺失或无效
 
SQL> alter procedure WMSYS.NO_VM_DROP_PROC DISABLE;
 
alter procedure WMSYS.NO_VM_DROP_PROC DISABLE
 
ORA-00922: 选项缺失或无效
 
SQL> ALTER TRIGGER wmsys.NO_VM_DDL DISABLE;
 
Trigger altered
 
SQL> ALTER TRIGGER wmsys.NO_VM_DROP_A DISABLE;
 
ALTER TRIGGER wmsys.NO_VM_DROP_A DISABLE
 
ORA-04080: 触发器 'NO_VM_DROP_A' 不存在
 
SQL> drop user aaa ;
 
User dropped
 
SQL> purge recyclebin;
 
Done
 

SQL> 

metlink引用文档

ORA-06576 error during Drop User (文档 ID 1498610.1)

In this Document

 
 
 
 

APPLIES TO:

Oracle Server - Enterprise Edition - Version 10.2.0.1 and later

Information in this document applies to any platform.

SYMPTOMS

Dropping a user schema results in below errors:

SQL> drop user GG_ADMIN;DROP USER "GG_ADMIN"Error at line 2ORA-00604: error occurred at recursive SQL level 1ORA-06576: not a valid function or procedure nameORA-06512: at line 21 gg_admin cascade;

CAUSE

A DDL trigger is defined on the drop statement.

Next query will get you the definition of the DDL Triggers in the system.

SQL> connect / as sysdbaSQL> SELECT a.obj#, a.sys_evts, b.name FROM trigger$ a,obj$ b WHERE a.sys_evts > 0 AND a.obj#=b.obj# AND baseobject = 0;  OBJ#       SYS_EVTS NAME---------- ---------- ------------------------------  81794             8 LOGON_DATE  81795          8416 NO_VM_DDL  81796           128 NO_VM_DROP_A  13177          8192 AW_REN_TRG  13179           128 AW_DROP_TRG  11990        524256 LOGMNRGGC_TRIGGER  13175          4096 AW_TRUNC_TRG  71787             1 MGMT_STARTUP

Get an errorstack for ORA-06576 error:

SQL> alter system set events='6576 trace name errorstack level 3';
SQL> drop user 

When executing 'drop user gg_admin', the resultant trace file shows the failing statement is a call to wmsys.no_vm_drop_proc('USER', 'GG_ADMIN', '').

From errorstack trace file we could observe the following:

 if (s_event='CREATE') then   execute immediate 'call wmsys.no_vm_create_proc(''' || sys.dictionary_obj_type || ''', ''' ||       sys.dictionary_obj_name || ''', ''' || sys.dictionary_obj_owner || ''')' ; elsif (s_event='DROP') then   execute immediate 'call wmsys.no_vm_drop_proc(''' || sys.dictionary_obj_type || ''', ''' ||       sys.dictionary_obj_name || ''', ''' || sys.dictionary_obj_owner || ''')' ;

The triggers enabled for this were in this case NO_VM_DDL and NO_VM_DROP_A

SOLUTION

Check if there are any DROP BEFORE triggers enabled. Once you drop the trigger, it will allow you to drop the user.

Workaround would be:

SQL> ALTER TRIGGER NO_VM_DDL DISABLE;SQL> ALTER TRIGGER NO_VM_DROP_A DISABLE;SQL> drop user gg_admin;

REFERENCES

 - OERR: ORA-6576 not a function or procedure

转载地址:http://ptmyx.baihongyu.com/

你可能感兴趣的文章
html代码究竟什么用途
查看>>
Hadoop HDFS编程 API入门系列之路径过滤上传多个文件到HDFS(二)
查看>>
Python version 2.7 required, which was not foun...
查看>>
context:annotation-config vs component-scan
查看>>
exgcd、二元一次不定方程学习笔记
查看>>
经典sql
查看>>
CSS3边框会动的信封
查看>>
JavaWeb实例设计思路(订单管理系统)
查看>>
source insight中的快捷键总结
查看>>
PC-IIS因为端口问题报错的解决方法
查看>>
java四种线程池简介,使用
查看>>
ios View之间的切换 屏幕旋转
查看>>
typedef BOOL(WINAPI *MYFUNC) (HWND,COLORREF,BYTE,DWORD);语句的理解
查看>>
jsp 特殊标签
查看>>
[BZOJ] 1012 [JSOI2008]最大数maxnumber
查看>>
gauss消元
查看>>
多线程-ReentrantLock
查看>>
数据结构之链表与哈希表
查看>>
IIS7/8下提示 HTTP 错误 404.13 - Not Found 请求筛选模块被配置为拒绝超过请求内容长度的请求...
查看>>
http返回状态码含义
查看>>