17 Nov
2005
17 Nov
'05
14:40
* Albert
I want to write a bash script which can be executed by cron every minute to check if an application is running. If it is not running the script should start it again.
make a script as: #!/bin/bash if ! (pidof -x <app-name>); then /<path>/<to>/<app-name>& fi call the script from cron */5 * * * * /<path>/<to>/<script-name> > /dev/null -- Patrick Shanahan Registered Linux User #207535 http://wahoo.no-ip.org @ http://counter.li.org HOG # US1244711 Photo Album: http://wahoo.no-ip.org/gallery2