[Ilugc] How to run a script on the event of another process getting killed

  • From: raju.rajsand@xxxxxxxxx (Rajagopal Swaminathan)
  • Date: Sat Jan 30 09:53:45 2010

Greetings,


On Fri, Jan 29, 2010 at 7:52 PM, Saravanan S <dearsaravanan@xxxxxxxxx> wrote:

Hi all,
Like once a GUI app is closed by clicking the x at the top right corner of
the window(usually), i should invoke a script.

How to track the PID of the script we run?

touch a file in say /var/lock/subsys

(This is the way yum prevents another instance)

Also checkout auditd.
Must be there in almost all the distros as it is part of kernel

Other related posts: