The best way of doing this is by writing a C/C++ daemon, I remember I did this a long time ago for a buggy apache server. In the end I managed to fix the actual problem that was crashing apache.
You should do the same, just fix the actual problem, don't just restart a crashed http server.
PidginHost.com - Managed dedicated servers, cloud servers and software development.
I think the crash is caused by too many busy server.
this is the "top" at this time (i don't have much visitator now, on the 8-12PM GMT +1 i have much visitatos.. andi crash php)
i have 40.000 visitator by month, the server are Intel Xeon Quad Core 2.83Ghz, 8GB DDR2, 2x 750GB RAID1, 200MbpsTX/1GbpsRX
Yersturday i have delete and disable the log file becouse the log access are 40GB in one month..
I have FreeBSD and Nginx.
here /var/log/php-fpm.log i have this log:
Jun 12 21:04:36.779515 [NOTICE] fpm_children_make(), line 352: child 11488 (pool default) started
Jun 12 21:04:36.779564 [NOTICE] fpm_event_loop(), line 107: libevent: entering main loop
Jun 13 12:20:54.917150 [WARNING] fpm_stdio_child_said(), line 167: child 11454 (pool default) said into stderr: "cut: /proc/uptime: $