Sign up ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Other than Monit, do you know how can auto start the lighttpd?

maybe some built-in function which I dont know...

(I use Lighttpd 1.4.22)

Thanks in advance.

share|improve this question

1 Answer 1

There is a thread on the lighttpd forum that illustrates how this can be done.

Put the following in a file, make it executable and trigger it to run from cron. You will need to tweak it for your environment.

wget --tries=1 --timeout=5 -O /dev/null http://localhost:80/
if [ $? -ne 0 ]; then
  (killall -9 lighttpd; killall -9 gam_server; killall -9 php-cgi; 
/etc/init.d/lighttpd zap; /etc/init.d/lighttpd start)
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.