[Spread-users] Spread startup

Ian Eiloart iane at sussex.ac.uk
Wed Sep 27 06:18:44 EDT 2006



--On 26 September 2006 12:07:39 -0400 Theo Schlossnagle <jesus at omniti.com> 
wrote:

>

>>
>> Well, hostname is always set correctly by the time I can get to log
>> in, it's set in /etc/hostconfig. The IP address is set by DHCP, so
>> it's not in /etc/hosts.
>>
>> Perhaps that's an alternative solution, but I think Spread would
>> ideally check that it has local access to one of the IP addresses
>> in the spread_segment definition before starting. Does it not do that?
>
> Most server software is pretty particular about startup order /
> dependencies.  It sounds like you are trying to compensate for a lack  of
> this on the Mac.  I was unaware that Mac launchd suffered form  this (I
> thought it was a rather thorough startup system).  Spread and  wackamole
> require certain things in the system to be functioning  correctly before
> they start -- otherwise, the outcome will likely not  be the desired
> outcome.

Well, launchd is a thorough startup system. However, the launchd philosophy 
is to design "daemons to not depend on the order in which they are started. 
Programs should be robust in the case where a service is unavailable, and 
in some cases, programs should be automatically spawned when needed instead 
of requiring programs to wait for them." 
<http://developer.apple.com/macosx/launchd.html>

Legacy startup mechanisms are available (rc scripts, cron, "StartupItems", 
inetd, etc), but I don't think launchd will ever include a mechanism for 
ordering startup. launchd replaces *all* those mechanisms, btw, where 
daemons are suitably coded.

Having said all that, a script can use launchd to start and stop services, 
so ordering is possible.

launchd does have a number of great advantages over traditional startup 
mechanisms. In particular, it has a watchdog role which will restart 
crashing daemons. That feature alone makes it highly desirable to use 
launchd.

> I would not be using DHCP to run these things.  The IP addresses are
> hardcoded into the spread.conf, but not into your hosts'  configurations.
> This is an inconsistency.

Well, the IP addresses aren't dynamic - in the sense that the DHCP server 
is configured to give each host the same primary IP address each time.




-- 
Ian Eiloart
IT Services, University of Sussex




More information about the Spread-users mailing list