"watchdog" for a process?

Nicolai Spohrer nicolai at xeve.de
Wed Sep 19 19:15:45 UTC 2007


Bart Silverstrim schrieb:
> Is there a quick and short script, maybe something that can be run in 
> Cron, that will look at the process list and if a process has been 
> killed or had died will restart the process?

What about

<script>
#!/bin/bash
ps -A | grep "filezilla" || echo "Filezilla not running anymore..
starting it again." >> ~/.fz_checker; filezilla&
exit 0
</script>
as cronjob?

greetings

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: OpenPGP digital signature
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20070919/1e4bf8e4/attachment.sig>


More information about the ubuntu-users mailing list