I run a script called "delayed_job" for a Ruby on Rails application. One of the options is to run this proc with a separate monitor proc. When the main proc dies, the monitor will spawn a new one. I can also run multiple processes. Each will have its own associated monitor process.
The script gives a way to kill the main processes, but not the monitor processes. I want to kill all of them.
A command of:
ps -ef|grep delayed
yields:
42011 29423 1 0 Sep25 ? 00:00:02 delayed_job.0_monitor
42011 29428 1 0 Sep25 ? 00:00:02 delayed_job.1_monitor
42011 29434 1 0 Sep25 ? 00:00:02 delayed_job.2_monitor
42011 29437 1 0 Sep25 ? 00:00:01 delayed_job.3_monitor
42011 23359 1 10 Oct19 ? 03:12:49 delayed_job.0
42011 8607 1 5 Oct19 ? 00:58:42 delayed_job.3
42011 21442 1 44 12:31 ? 01:02:03 delayed_job.2
42011 23092 1 4 14:18 ? 00:01:22 delayed_job.1
42011 23861 23763 0 14:51 pts/5 00:00:00 grep delayed
I want to kill all of them, or at least the monitors. How can I kill these (with the exception of the grep command itself)?