nice work, here my script from bsd box
Code:
#!/bin/sh
isAlive=`ps ax | grep -v grep | grep -c httpd`
if [ $isAlive -le 0 ]
then
/usr/local/etc/rc.d/apache restart
fi
__________________
Rocky Jr.
You may have my body & soul, but you will never touch my pride!
If you have knowledge, let others light their candles at it.
Certified to work on
HP-UX /
Sun Solaris /
RedHat