I host my sites at tektonic.net, which provides cheep usable virtual private servers (VPS) running linux.
For the most part, they have been very good; however they occasionally need to restart my virtuozzo
VPS, and for some reason (unbeknownst to syslog-ng), some services will not start (like atd, wtf?). So I gave up on the sysvinit, and
moved to daemontools.
I rationalized some of the daemontools startup scripts that I found online and archived them. So now daemontools
supervises most of my processes, making sure that they run, even if they fall over, which matters a lot (to me) for things like SSH....
PID TTY STAT TIME COMMAND
1 ? Ss 0:01 init [2]
24177 ? S 0:06 /usr/lib/postgresql/8.1/bin/postmaster -D /var/lib/postgresql/8.1/main -c config_file=/etc/postgresql/8.1/main/postgresql.conf
11894 ? S 0:02 \_ postgres: writer process
11898 ? S 0:01 \_ postgres: stats buffer process
11901 ? S 0:02 \_ postgres: stats collector process
29836 ? Ss 0:00 /usr/sbin/apache2 -k start
29837 ? S 0:00 \_ /usr/bin/logger -p local0.info
29838 ? S 0:00 \_ /usr/bin/logger -p local0.notice
29839 ? S 0:00 \_ /usr/sbin/fcgi-pm -k start
27869 ? Sl 0:01 | \_ python /var/www/domify.com/website.py
29847 ? S 0:00 \_ /usr/sbin/apache2 -k start
29849 ? S 0:02 \_ /usr/sbin/apache2 -k start
29850 ? S 0:02 \_ /usr/sbin/apache2 -k start
29852 ? S 0:00 \_ /usr/sbin/apache2 -k start
29870 ? S 0:02 \_ /usr/sbin/apache2 -k start
30381 ? S 0:02 \_ /usr/sbin/apache2 -k start
22106 ? S 0:00 \_ /usr/sbin/apache2 -k start
22110 ? S 0:00 \_ /usr/sbin/apache2 -k start
22111 ? S 0:00 \_ /usr/sbin/apache2 -k start
30510 ? S 0:00 \_ /usr/sbin/apache2 -k start
23946 ? Ss 0:00 /bin/sh /usr/bin/svscanboot
23948 ? S 0:00 \_ svscan /var/lib/svscan
23950 ? S 0:00 | \_ supervise tinydns
23960 ? S 0:00 | | \_ /usr/bin/tinydns
23951 ? S 0:00 | \_ supervise log
23962 ? S 0:00 | | \_ /bin/sh ./run
23956 ? S 0:00 | \_ supervise atd
23958 ? Ss 0:00 | | \_ /usr/sbin/atd -d
23957 ? S 0:00 | \_ supervise postfix
23959 ? Ss 0:00 | | \_ /usr/lib/postfix/master
24028 ? S 0:00 | | \_ qmgr -l -t fifo -u
5799 ? S 0:00 | | \_ pickup -l -t fifo -u
12242 ? S 0:00 | | \_ anvil -l -t unix -u
15531 ? S 0:00 | | \_ trivial-rewrite -n rewrite -t unix -u
16119 ? S 0:00 | | \_ cleanup -z -t unix -u
16137 ? S 0:00 | | \_ local -t unix
18384 ? S 0:00 | | \_ cleanup -z -t unix -u
18394 ? S 0:00 | | \_ local -t unix
19669 ? S 0:00 | | \_ smtpd -n smtp -t inet -u
19674 ? S 0:00 | | \_ smtpd -n smtp -t inet -u
24036 ? S 0:00 | \_ supervise ssh
24038 ? S 0:00 | | \_ /usr/sbin/sshd -D
22292 ? Ss 0:00 | | \_ sshd: dorkbot [priv]
22295 ? S 0:00 | | \_ sshd: dorkbot@notty
22296 ? Rs 0:00 | | \_ ps faxwww
24037 ? S 0:00 | \_ supervise syslog-ng
29898 ? S 0:00 | | \_ /sbin/syslog-ng -F -p /dev/null
24040 ? S 0:00 | \_ supervise dnscache
24041 ? S 0:00 | | \_ /usr/bin/dnscache
24042 ? S 0:00 | \_ supervise log
24043 ? S 0:00 | | \_ multilog t ./main
28356 ? S 0:00 | \_ supervise cron
28357 ? S 0:00 | | \_ /usr/sbin/cron -f
19878 ? S 0:00 | \_ supervise proctitle
23949 ? S 0:00 \_ readproctitle service errors:....................
................................................................................
................................................................................
................................................................................
................................................................................
............................................................
This looks good, however, daemontools doesn't supervise postgres (not sure I want to automatically restart it upon crash), and apache, which
as far as I know doesn't have a remain-in-foreground option. Which means I may move to lighttpd, as I don't really need all of the apache craziness.