Gentoo Archives: gentoo-user

From: Joost Roeleveld <joost@××××××××××××.uk>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] displaying the actual order init scripts will run
Date: Wed, 19 Dec 2007 18:16:21
Message-Id: 200712191909.06887.joost@roeleveld.co.uk
In Reply to: [gentoo-user] displaying the actual order init scripts will run by Mike Williams
1 On Wednesday 19 December 2007 15:36:01 Mike Williams wrote:
2 > Hey all,
3 >
4 > I'm knocking together an init script that needs to run at a very specific
5 > point during startup.
6 > Is there a simple way I can see in exactly what order the init scripts
7 > would be run?
8 > Don't much fancy constant rebooting just to make sure it runs at the
9 > correct time! Especially seeing as it's a machine about 110 miles away from
10 > me!
11
12 If the init-script needs to run after a specific (set of) other init-script(s)
13 and/or before a specific (set of) other init-script(s), you can add these to
14 to the "before" and "after" lists respectively.
15
16 As example, the following is copied from the /etc/init.d/xdm file:
17
18 ---
19 depend() {
20 need localmount
21
22 # this should start as early as possible
23 # we can't do 'before *' as that breaks it
24 # (#139824) Start after ypbind and autofs for network authentication
25 # (#145219) Could use lirc mouse as input device
26 # (#70689 comment #92) Start after consolefont to avoid display
27 corruption
28 after bootmisc readahead-list ypbind autofs openvpn gpm netmount lircd
29 consolefont
30 before alsasound
31
32 # Start before X
33 use acpid consolekit hald xfs
34 }
35 ---
36
37 This will allow you to disable init-scripts that you no longer need, without
38 having your init-script becoming disabled.
39
40 HTH.
41
42 --
43 Joost Roeleveld
44 --
45 gentoo-user@g.o mailing list