From: Jonathan de Boyne Pollard on
>
>>>
>>> People moan how UNIX is so much better than Windows, but Windows has
>>> had services for a very long time - there is no such messing about ;-)
>>>
>> This state of affairs probably has something to do w/ Windows' poor
>> process control. Horses for courses....
>>
> Microsoft recognised the need for proper control of daemons. This has
> nothing to do with process control itself. It doesn't matter how well
> you can signal, fork daemons etc - you still need a clean way of
> launching just one daemon.
>
It hasn't to do with Unix being inferior either, strictly speaking.
This is the common canard of conflating Linux and Unix. Linux may be
deficient in this area, with many distributions not using daemontools,
runit, or some other such package but instead having a house of straw
built upon the sand that is PID files, doing things in the way that they
used to be done back in the 1980s. But Unices and others are not
deficient like this. Solaris has the Service Access Controller in
version 9 and the Service Management Facility in version 10. AIX has
the System Resource Controller. Other Unices have similar things.
MacOS version 10.4 and later similarly have launchd. Linux is the
exception here, not actually the norm. The norm is that Unices in fact
do have services, and service control mechanisms that will do all of the
nitty-gritty of service management, including running only the one
service process at a time with the service manager using wait() to
reliably determine when the process dies and fork() to reliably know
what its process ID is in the first place, much the same as Windows NT.
This has been the norm since the 1990s, when people (from IBM through
Microsoft to Dan Bernstein) realized that a reliable, structured,
service management mechanism was a good idea and started providing it.
Apple has reached this point, now. Heck, one can even do this with OS/2
nowadays. (I first publicly released service management tools for OS/2
in 2002, if memory serves correctly.) The simple truth is that the
world of Linux hasn't universally caught up with this thinking yet. But
don't think that that is in any way the norm nowadays for the world of
operating systems in general, or even for the world of Unix in particular.