30036ORA-30036: unable to extend segment by 8 in undo tablespace 'UNDOTBS1'解决办法
解决该问题分三步走
(一)
--查看undo表空间使用情况
--插入 和 删除操作才产生对undo空间使用
select s.username, s.sid, rn.name, rs.extents
,rs.status, t.used_ublk, t.used_urec, round(t.used_ublk*8/1024,1) as "SIZE(MB)"
,do.object_name
from v$transaction t
,v$session s
,v$rollname rn
,v$rollstat rs
,v$locked_object lo
,dba_objects do
where t.addr = s.taddr
and t.xidusn = rn.usn
and rn.usn = rs.usn
and t.xidusn = lo.xidusn(+)
and do.object_id = lo.object_id
(二)
--锁解决方法
select b.owner,b.object_name,l.session_id,l.locked_mode
from v$locked_object l, dba_objects b
where b.object_id=l.object_id
select t2.username,t2.sid,t2.serial#,t2.logon_time
from v$locked_object t1,v$session t2
where t1.session_id=t2.sid order by t2.logon_time
--查看对应执行的SQL
select sql_text from v$sqltext where address in(select sql_address from v$session where sid=&sid)order by piece
(三)
--kill session
alter system kill session 'sid,serial#'
--如果上面KILL不行则需要在os级进行进程切断
select spid from v$session s ,v$process p where p.addr=s.paddr and s.sid=&sid
--oracle用户下执行如下命令
kill -9 &spid