Wednesday, December 21, 2011

STOP Rman backup job


If the Rman job process is running in the foreground on your screen then type ‘ctl+C’, but if its running in the background then you can kill either manually by finding sid/spid or using OEM

To know the rman sid and spid of your running job use the below script

SQL >   SELECT p.SPID, s.sid, s.serial#, sw.EVENT, sw.SECONDS_IN_WAIT AS  SEC_WAIT, sw.STATE, CLIENT_INFO 
FROM V$SESSION_WAIT sw, V$SESSION s, V$PROCESS p
WHERE s.client_info LIKE 'rman%'
AND s.SID=sw.SID
AND s.PADDR=p.ADDR;

SPID      SID      SERIAL#    EVENT                                     SEC_WAIT     STATE        CLIENT_INFO
-------   -------    ----------    ------------------                              --------------    --------        ------------------
1234   5678     98765      control file sequential read                         0     WAITING     rman channel=ORA_DISK_1

SQL >   alter system kill session ’SID, SERIAL#′;

To know more about killing a session :   find and kill oracle session

0 comments:

Post a Comment

Auto Scroll Stop Scroll