Advertisement
Guest User

Untitled

a guest
Sep 24th, 2017
45
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.26 KB | None | 0 0
  1. #!/bin/sh
  2. tmpfile=/tmp/tmp.$$
  3. sqlplus system/manager <
  4. spool $tmpfile
  5. select p.spid from v\$process p,v\$session s
  6. where s.paddr=p.addr
  7. and s.status='SNIPED';
  8. spool off
  9. EOF
  10. for x in `cat $tmpfile | grep "^[0123456789]"`
  11. do
  12. kill -9 $x
  13. done
  14. rm $tmpfile
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement