by Caramon on Mon May 17, 2004 9:46 pm
I used to run a cron task to make sure that the process was still running, then start it if the task wasn't. its been so long since I did any shell programming, I can't remember how i did it. Basically I piped a 'ps -ef | grep 'prog-name' ' into a temp text file, then I did a search of the file. If I found the entire name (I would do a partial search, as the search itself shows up as a process, so the file will always have at least one entry in it). If it didn't find the process running, the shell script would then launch the pol process again. Hope that helps.