From owner-freebsd-current Fri Aug 16 14:40:50 1996 Return-Path: owner-current Received: (from root@localhost) by freefall.freebsd.org (8.7.5/8.7.3) id OAA20352 for current-outgoing; Fri, 16 Aug 1996 14:40:50 -0700 (PDT) Received: from rocky.mt.sri.com (rocky.mt.sri.com [206.127.76.100]) by freefall.freebsd.org (8.7.5/8.7.3) with ESMTP id OAA20339 for ; Fri, 16 Aug 1996 14:40:46 -0700 (PDT) Received: (from nate@localhost) by rocky.mt.sri.com (8.7.5/8.7.3) id PAA08388; Fri, 16 Aug 1996 15:36:42 -0600 (MDT) Date: Fri, 16 Aug 1996 15:36:42 -0600 (MDT) Message-Id: <199608162136.PAA08388@rocky.mt.sri.com> From: Nate Williams To: Terry Lambert Cc: freebsd-current@freebsd.org Subject: Re: Opinions? NT VS UNIX, NT SUCKS SOMETIMES In-Reply-To: <199608162004.NAA03242@phaeton.artisoft.com> References: <199608162004.NAA03242@phaeton.artisoft.com> Sender: owner-current@freebsd.org X-Loop: FreeBSD.org Precedence: bulk > > In BSD, I can add service A by appending to /etc/rc.local during > install. That's one way of doing it, but not the only way. > I can then add service B by doing the same thing. > Now I want to deinstall service A... I am screwed because: > > 1) I can't stop the service by name unless it's exactly one > process, or I do a whole lot of work that has to be > duplicated over and over for each package because the > support infrastructure is non-existent. The current setup doesn't allow for 'stopping' of services. > 2) I can't automatically hack the file, because I may not > have tagged the file in such a way that it's editable, and > since we allow users to hack the file as well as allowing > install scripts to hack the file, we can never be sure that > we would be removing the right thing anyway. The 'other' solution works in this case. > 3) I can't automatically start the service in the same way that > I would start the service on system initialization without > a reboot, because the start "script" is now homogenized into > the rc.local and forever unuasable on a per item basis. The 'other' solution works in this case. >From -current's /etc/sysconfig: # Location of local startup directories. local_startup="/usr/local/etc/rc.d /usr/X11R6/etc/rc.d" >From -current's /etc/rc: # for each valid dir in $local_startup, search for init scripts matching *.sh if [ "X${local_startup}" != X"NO" ]; then for dir in ${local_startup}; do [ -d ${dir} ] && for script in ${dir}/*.sh; do [ -x ${script} ] && ${script} start done done fi This is *very* much like SysV's init, except that it leaves the system (ie; standard/normal configuration) localized, and non-standard (custom) stuff off somewhere else. This si a 'Good Thing' IMHO. init(8) still needs to be modified to have it run a signle 'shutdown' script which would do the same thing as above, but it wouldn't be that hard to do. The SysV of 'multiple run-levels' is something I've yet to see used. Even the most hard-core SysV gurus use the two available in BSD, single-user and multi-user. Nate