*BSD News Article 73785


Return to BSD News archive

Path: euryale.cc.adfa.oz.au!newshost.anu.edu.au!harbinger.cc.monash.edu.au!munnari.OZ.AU!news.ecn.uoknor.edu!solace!eru.mt.luth.se!bloom-beacon.mit.edu!news.mathworks.com!uunet!inXS.uu.net!news.artisoft.com!usenet
From: Terry Lambert <terry@lambert.org>
Newsgroups: comp.unix.bsd.freebsd.misc
Subject: Re: httpd through cron
Date: Mon, 15 Jul 1996 17:39:08 -0700
Organization: Me
Lines: 40
Message-ID: <31EAE4AC.23B618E2@lambert.org>
References: <4s88g3$krt@usenet.srv.cis.pitt.edu> <4sdo3p$461@usenet.srv.cis.pitt.edu>
NNTP-Posting-Host: hecate.artisoft.com
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
X-Mailer: Mozilla 2.01 (X11; I; Linux 1.1.76 i486)

James L Fox wrote:
] ---------
] Note:
] I know this group is FreeBSD and not SunOs or CERN but I also
] know that many posters/readers here are running web servers,
] understand cron, and might want to try to do what I'm doing
] with Apache on FreeBSD.
] ---------
] 
] Here I am again, the only responder to my own post!
] I included all the dirty details of my problem after reading the
] criticisms here of people who ask questions without sufficient
] background information.  Apparently I overdid it!  Here's a
] stripped down version of my question...  If you need more details,
] please refer back to the article referenced by this one.

It needs a /dev/tty, which it can't get if it is run by cron.

Instead, you should start it from /etc/rc.local, if you are
worried about it following a reboot.

If you are worried about it crashing and restarting, you can do
that using a "restart" script to watchdog it; something like:


#!/bin/sh
#
while true
do
	echo "starting httpd" > /dev/console
	httpd&	# or whatever...
done
# not reached


                                        Terry Lambert
                                        terry@lambert.org
---
Any opinions in this posting are my own and not those of my present
or previous employers.