From owner-freebsd-arch Fri Apr 6 0:13:37 2001 Delivered-To: freebsd-arch@freebsd.org Received: from homer.softweyr.com (bsdconspiracy.net [208.187.122.220]) by hub.freebsd.org (Postfix) with ESMTP id C12A737B506 for ; Fri, 6 Apr 2001 00:13:28 -0700 (PDT) (envelope-from wes@softweyr.com) Received: from [127.0.0.1] (helo=softweyr.com ident=f427b9f9567ff881379d9198d53a4e97) by homer.softweyr.com with esmtp (Exim 3.16 #1) id 14lQQb-0000JF-00; Fri, 06 Apr 2001 01:13:05 -0600 Message-ID: <3AC9E86B.A8D976D4@softweyr.com> Date: Tue, 03 Apr 2001 09:12:43 -0600 From: Wes Peters Organization: Softweyr LLC X-Mailer: Mozilla 4.75 [en] (X11; U; Linux 2.2.12 i386) X-Accept-Language: en MIME-Version: 1.0 To: David Xu Cc: Doug White , David O'Brien , Cy Schubert - ITSD Open Systems Group , Jack Rusher , Neil Blakey-Milner , Michael Lucas , "litos2001@libero.it" Subject: Re: Startup scripts a la NetBSD References: <39898261.20010403084256@21cn.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG David Xu wrote: > > Hello Doug, > > Tuesday, April 03, 2001, 6:26:10 AM, you wrote: > > DW> On Mon, 2 Apr 2001, David Xu wrote: > > >> In the past, I saw lots of people refused to see rc.d style in > >> FreeBSD, include some guys in core team, at that time, I'm very > >> disappointed, why is it back again? is this just because of NetBSD? > > DW> Because sysv-style init scripts actually make sense for both admins and > DW> installed packages? It's not traditionally BSD, but unfortunately programs > DW> are much more complex today, generally with multiple daemons and > DW> interdependencies for starting up properly. A vendor-supplied script > DW> makes sure everything is set up to start the daemons/packages correctly, > DW> and gives a nice start/stop knob for the admin to control it with. > > DW> For the record, I hacked up this pile of scripts to emulate one runlevel, > DW> along with a linux-style chkconfig(8) script. You just have to call the > DW> start-rc3.sh script at some point in the boot, and stop-rc3.sh when > DW> shutting down. Since we have rc.shutdown.d you don't have to edit > DW> rc.shutdown anymore. If you really want Linnex-style /etc/rc.d/init.d/ > DW> and friends, this will give it to you. > > DW> It should be in > DW> ftp://ftp.freebsd.org/pub/FreeBSD/ports/local-distfiles/dwhite/sysvrc-1.1.tar.gz, > DW> or any other MASTER_SITE_LOCAL mirror. > > DW> Doug White | FreeBSD: The Power to Serve > DW> dwhite@resnet.uoregon.edu | www.FreeBSD.org > > I like the idea, it has unique start/stop interface, I needn't > remember obscure parameters for every daemon, it really got me. > but am I dreaming? I suspect it will never be native supported > in FreeBSD. That depends on what you mean by "sysv-like". If you want runlevels 0-6 supported by init, probably not. If you want individual packages started by their own scripts, FreeBSD already has this to some extent, and even allows you to add directories. See /etc/defaults/rc.conf, which contains: local_startup="/usr/local/etc/rc.d /usr/X11R6/etc/rc.d" This allows everything you want above, for packages that are added to FreeBSD. It does not handle dependencies between packages, or state a startup order between directories in $local_startup or between the scripts in each directory. If you'd like to improve any of the above, or to move parts of the standard system startup scripts to, for instance, /etc/rc.d, with some explicit ordering, we'd like to hear it. This is FreeBSD, patches talk. -- "Where am I, and what am I doing in this handbasket?" Wes Peters Softweyr LLC wes@softweyr.com http://softweyr.com/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message