1、停服务:
- stop *
- stop mgr
- rm -rf ggate
- SQL> drop user gate01 cascade;
- drop user gate01 cascade
- *
- ERROR at line 1:
- ORA-00604: error occurred at recursive SQL level 2
- ORA-20782: GoldenGate DDL Replication Error: Code :ORA-20782: Cannot DROP
- object used in GoldenGate replication while trigger is enabled. Consult
- GoldenGate documentation and/or call GoldenGate Technical Support if you wish
- to do so., error stack: ORA-06512: at line 226
- ORA-06512: at line 951
- SQL> drop trigger ggs_ddl_trigger_before;
- Trigger dropped.
- SQL> drop user gate01 cascade;
- drop user gate01 cascade
- *
- ERROR at line 1:
- ORA-00604: error occurred at recursive SQL level 1
- ORA-14452: attempt to create, alter or drop an index on temporary table already
- in use
解决办法:
- 1、查出gate01用户的表:
- conn gate01/gate01
- select table_name from tabs;
- TABLE_NAME
- ------------------------------
- GGS_DDL_PRIMARY_KEYS
- GGS_STICK
- 2、查询对应sid,serial#:
- select sid, serial# from v$session where sid =
- (select sid from v$lock where id1 =
- (select object_id from user_objects where object_name = upper('GGS_STICK')));
- 3、结束session:
- alter system kill session 'sid,serial#';
- drop user gate01 cascade;