From owner-freebsd-hackers Sun Jan 31 00:35:57 1999 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id AAA00211 for freebsd-hackers-outgoing; Sun, 31 Jan 1999 00:35:57 -0800 (PST) (envelope-from owner-freebsd-hackers@FreeBSD.ORG) Received: from peach.ocn.ne.jp (peach.ocn.ne.jp [210.145.254.87]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id AAA00205 for ; Sun, 31 Jan 1999 00:35:55 -0800 (PST) (envelope-from dcs@newsguy.com) Received: from newsguy.com by peach.ocn.ne.jp (8.9.1a/OCN) id RAA19263; Sun, 31 Jan 1999 17:33:19 +0900 (JST) Message-ID: <36B407A3.FE86093D@newsguy.com> Date: Sun, 31 Jan 1999 16:34:59 +0900 From: "Daniel C. Sobral" X-Mailer: Mozilla 4.5 [en] (Win98; I) X-Accept-Language: pt-BR,ja MIME-Version: 1.0 To: Wes Peters CC: Brandon Gillespie , Robert Withrow , freebsd-hackers@FreeBSD.ORG Subject: Re: more modular rc/init/uninit system... References: <36B1739E.1A22A983@urc.ac.ru> <199901291406.JAA27108@spooky.rwwa.com> <19990129115122.A25989@cold.org> <36B2CD01.69CFEFA8@newsguy.com> <36B33C2B.CDB07CCB@softweyr.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Wes Peters wrote: > > > The problem with dependencies is that you need to build a graph, so > > you know how to shutdown a service, while correctly shuting down > > everything that depended on it (which the service is most likely to > > *not* know -- take, for instance, the networking stack). > > And wouldn't you know it, we already have a tool for managing > dependency graphs. ;^) > > How about a Makefile, with "startup" and "shutdown" targets, and > individual "start" and "stop" targets for each subsystem? The While the Makefile idea is interesting, let me just make clear that the problem lies in the fact that the startup dependency is in the opposite direction of the shutdown dependency. For instance, if resource B depends on A, resource D on B and C, and resource E on B, these are the dependencies: A.startup: A.shutdown: B.startup: A.startup B.shutdown: D.shutdown E.shutdown C.startup: C.shutdown: D.shutdown D.startup: B.startup C.startup D.shutdown: E.startup: B.startup E.shutdown: Now, you show me that being created out of environment variables, given that B does not have the slightest idea of what is depending on it (which may vary, given different levels (or states, which is, imho, the correct way)). > configuration settings would remain in rc.conf and rc.conf.local, > where they belong, and each "subsystem" startup moved to an > individual script. /etc/rc would bring the system up just far > enough for make to function, and then cd /etc; make startup. You > could start a particular subsystem, or shut it down, with i.e. > "make start.nfsserver" or "make stop.nfsserver". > > Good? Bad? Indifferent? Intriguing, to say the least... :-) -- Daniel C. Sobral (8-DCS) dcs@newsguy.com Would you mind not shooting at the thermonuclear weapons? To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message