source: BOOK/boot/common/bootscripts.xml @ 54b143f

clfs-3.0.0-systemdclfs-3.0.0-sysvinitsystemdsysvinit
Last change on this file since 54b143f was 54b143f, checked in by Chris Staub <chris@…>, 10 years ago

Updated bootscripts to be used in /tools

  • Property mode set to 100644
File size: 11.5 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3  "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4  <!ENTITY % general-entities SYSTEM "../../general.ent">
5  %general-entities;
6]>
7
8<sect1 id="ch-scripts-bootscripts" role="wrap">
9  <?dbhtml filename="bootscripts.html"?>
10
11  <title>Bootscripts for CLFS &bootscripts-clfs-version;</title>
12
13  <indexterm zone="ch-scripts-bootscripts">
14    <primary sortas="a-Bootscripts">Bootscripts</primary>
15    <secondary>boot</secondary>
16  </indexterm>
17
18  <sect2 role="package">
19    <title/>
20
21    <para>The Bootscripts package contains a set of scripts to
22    start/stop the CLFS system at bootup/shutdown.</para>
23
24  </sect2>
25
26  <sect2 role="installation">
27    <title>Installation of Bootscripts</title>
28
29    <para os="s1">Update the bootscripts so they can be used in /tools:</para>
30
31<screen os="s2"><userinput>patch -Np1 -i ../bootscripts-cross-lfs-2.1-pre1-updates-1.patch</userinput></screen>
32
33    <para os="a">Install the package:</para>
34
35<screen os="b"><userinput>make DESTDIR=/tools install-minimal</userinput></screen>
36
37  <para os="c">The <command>setclock</command> script reads the time from the
38  hardware clock, also known as the BIOS or the Complementary Metal Oxide
39  Semiconductor (CMOS) clock. If the hardware clock is set to UTC, this
40  script will convert the hardware clock's time to the local time using
41  the <filename>/etc/localtime</filename> file (which tells the
42  <command>hwclock</command> program which timezone the user is in). There
43  is no way to detect whether or not the hardware clock is set to UTC, so
44  this needs to be configured manually.</para>
45
46
47
48  <para os="d">If you do not know whether or not the hardware clock is set to UTC,
49  you can find out after you have booted the new machine by running the
50  <userinput>hwclock --localtime  --show</userinput> command, and if
51  necessary editing the <filename>/etc/sysconfig/clock</filename> script.
52  The worst that will happen if you make a wrong guess here is that the
53  time displayed will be wrong.</para>
54
55  <para os="e">Change the value of the <envar>UTC</envar> variable below
56  to a value of <option>0</option> (zero) if the hardware clock
57  is <emphasis>not</emphasis> set to UTC time.</para>
58
59<screen os="f"><userinput>cat &gt; /tools/etc/sysconfig/clock &lt;&lt; "EOF"
60<literal># Begin /tools/etc/sysconfig/clock
61
62UTC=1
63
64# End /tools/etc/sysconfig/clock</literal>
65EOF</userinput></screen>
66
67  </sect2>
68
69  <sect2 id="contents-bootscripts" role="content">
70    <title>Contents of Bootscripts</title>
71
72    <segmentedlist>
73      <segtitle>Installed scripts</segtitle>
74
75      <seglistitem>
76        <seg>checkfs, cleanfs, console, functions, halt, ifdown,
77        ifup, localnet, mountfs, mountkernfs, network, rc, reboot, sendsignals,
78        setclock, static, swap, sysklogd, template, and udev.</seg>
79      </seglistitem>
80    </segmentedlist>
81
82    <variablelist>
83      <bridgehead renderas="sect3">Short Descriptions</bridgehead>
84      <?dbfo list-presentation="list"?>
85      <?dbhtml list-presentation="table"?>
86
87      <varlistentry id="checkfs-bootscripts">
88        <term><command>checkfs</command></term>
89        <listitem>
90          <para>Checks the integrity of the file systems before they are
91          mounted (with the exception of journal and network based file
92          systems)</para>
93          <indexterm zone="ch-scripts-bootscripts checkfs-bootscripts">
94            <primary sortas="d-checkfs">checkfs</primary>
95          </indexterm>
96        </listitem>
97      </varlistentry>
98
99      <varlistentry id="cleanfs-bootscripts">
100        <term><command>cleanfs</command></term>
101        <listitem>
102          <para>Removes files that should not be preserved between reboots,
103          such as those in <filename class="directory">/var/run/</filename>
104          and <filename class="directory">/var/lock/</filename>; it re-creates
105          <filename>/var/run/utmp</filename> and removes the possibly present
106          <filename>/etc/nologin</filename>, <filename>/fastboot</filename>,
107          and <filename>/forcefsck</filename> files</para>
108          <indexterm zone="ch-scripts-bootscripts cleanfs-bootscripts">
109            <primary sortas="d-cleanfs">cleanfs</primary>
110          </indexterm>
111        </listitem>
112      </varlistentry>
113
114      <varlistentry id="console-bootscripts">
115        <term><command>console</command></term>
116        <listitem>
117          <para>Loads the correct keymap table for the desired keyboard
118          layout; it also sets the screen font</para>
119          <indexterm zone="ch-scripts-bootscripts console-bootscripts">
120            <primary sortas="d-console">console</primary>
121          </indexterm>
122        </listitem>
123      </varlistentry>
124
125      <varlistentry id="functions-bootscripts">
126        <term><command>functions</command></term>
127        <listitem>
128          <para>Contains common functions, such as error and status checking,
129          that are used by several bootscripts</para>
130          <indexterm zone="ch-scripts-bootscripts functions-bootscripts">
131            <primary sortas="d-functions">functions</primary>
132          </indexterm>
133        </listitem>
134      </varlistentry>
135
136      <varlistentry id="halt-bootscripts">
137        <term><command>halt</command></term>
138        <listitem>
139          <para>Halts the system</para>
140          <indexterm zone="ch-scripts-bootscripts halt-bootscripts">
141            <primary sortas="d-halt">halt</primary>
142          </indexterm>
143        </listitem>
144      </varlistentry>
145
146      <varlistentry id="ifdown-bootscripts">
147        <term><command>ifdown</command></term>
148        <listitem>
149          <para>Assists the network script with stopping network devices</para>
150          <indexterm zone="ch-scripts-bootscripts ifdown-bootscripts">
151            <primary sortas="d-ifdown">ifdown</primary>
152          </indexterm>
153        </listitem>
154      </varlistentry>
155
156      <varlistentry id="ifup-bootscripts">
157        <term><command>ifup</command></term>
158        <listitem>
159          <para>Assists the network script with starting network devices</para>
160          <indexterm zone="ch-scripts-bootscripts ifup-bootscripts">
161            <primary sortas="d-ifup">ifup</primary>
162          </indexterm>
163        </listitem>
164      </varlistentry>
165
166      <varlistentry id="localnet-bootscripts">
167        <term><command>localnet</command></term>
168        <listitem>
169          <para>Sets up the system's hostname and local loopback device</para>
170          <indexterm zone="ch-scripts-bootscripts localnet-bootscripts">
171            <primary sortas="d-localnet">localnet</primary>
172          </indexterm>
173        </listitem>
174      </varlistentry>
175
176      <varlistentry id="mountfs-bootscripts">
177        <term><command>mountfs</command></term>
178        <listitem>
179          <para>Mounts all file systems, except ones that are marked
180          <emphasis>noauto</emphasis> or are network based</para>
181          <indexterm zone="ch-scripts-bootscripts mountfs-bootscripts">
182            <primary sortas="d-mountfs">mountfs</primary>
183          </indexterm>
184        </listitem>
185      </varlistentry>
186
187      <varlistentry id="mountkernfs-bootscripts">
188        <term><command>mountkernfs</command></term>
189        <listitem>
190          <para>Mounts virtual kernel file systems, such as
191          <systemitem class="filesystem">proc</systemitem></para>
192          <indexterm zone="ch-scripts-bootscripts mountkernfs-bootscripts">
193            <primary sortas="d-mountkernfs">mountkernfs</primary>
194          </indexterm>
195        </listitem>
196      </varlistentry>
197
198      <varlistentry id="network-bootscripts">
199        <term><command>network</command></term>
200        <listitem>
201          <para>Sets up network interfaces, such as network cards, and sets up
202          the default gateway (where applicable)</para>
203          <indexterm zone="ch-scripts-bootscripts network-bootscripts">
204            <primary sortas="d-network">network</primary>
205          </indexterm>
206        </listitem>
207      </varlistentry>
208
209      <varlistentry id="rc-bootscripts">
210        <term><command>rc</command></term>
211        <listitem>
212          <para>The master run-level control script; it is responsible for
213          running all the other bootscripts one-by-one, in a sequence
214          determined by the name of the symbolic links being processed</para>
215          <indexterm zone="ch-scripts-bootscripts rc-bootscripts">
216            <primary sortas="d-rc">rc</primary>
217          </indexterm>
218        </listitem>
219      </varlistentry>
220
221      <varlistentry id="reboot-bootscripts">
222        <term><command>reboot</command></term>
223        <listitem>
224          <para>Reboots the system</para>
225          <indexterm zone="ch-scripts-bootscripts reboot-bootscripts">
226            <primary sortas="d-reboot">reboot</primary>
227          </indexterm>
228        </listitem>
229      </varlistentry>
230
231      <varlistentry id="sendsignals-bootscripts">
232        <term><command>sendsignals</command></term>
233        <listitem>
234          <para>Makes sure every process is terminated before the system reboots
235          or halts</para>
236          <indexterm zone="ch-scripts-bootscripts sendsignals-bootscripts">
237            <primary sortas="d-sendsignals">sendsignals</primary>
238          </indexterm>
239        </listitem>
240      </varlistentry>
241
242      <varlistentry id="setclock-bootscripts">
243        <term><command>setclock</command></term>
244        <listitem>
245          <para>Resets the kernel clock to local time in case the hardware clock
246          is not set to UTC time</para>
247          <indexterm zone="ch-scripts-bootscripts setclock-bootscripts">
248            <primary sortas="d-setclock">setclock</primary>
249          </indexterm>
250        </listitem>
251      </varlistentry>
252
253      <varlistentry id="static-bootscripts">
254        <term><command>static</command></term>
255        <listitem>
256          <para>Provides the functionality needed to assign a static Internet
257          Protocol (IP) address to a network interface</para>
258          <indexterm zone="ch-scripts-bootscripts static-bootscripts">
259            <primary sortas="d-static">static</primary>
260          </indexterm>
261        </listitem>
262      </varlistentry>
263
264      <varlistentry id="swap-bootscripts">
265        <term><command>swap</command></term>
266        <listitem>
267          <para>Enables and disables swap files and partitions</para>
268          <indexterm zone="ch-scripts-bootscripts swap-bootscripts">
269            <primary sortas="d-swap">swap</primary>
270          </indexterm>
271        </listitem>
272      </varlistentry>
273
274      <varlistentry id="sysklogd-bootscripts">
275        <term><command>sysklogd</command></term>
276        <listitem>
277          <para>Starts and stops the system and kernel log daemons</para>
278          <indexterm zone="ch-scripts-bootscripts sysklogd-bootscripts">
279            <primary sortas="d-sysklogd">sysklogd</primary>
280          </indexterm>
281        </listitem>
282      </varlistentry>
283
284      <varlistentry id="template-bootscripts">
285        <term><command>template</command></term>
286        <listitem>
287          <para>A template to create custom bootscripts for other
288          daemons</para>
289          <indexterm zone="ch-scripts-bootscripts template-bootscripts">
290            <primary sortas="d-template">template</primary>
291          </indexterm>
292        </listitem>
293      </varlistentry>
294
295      <varlistentry id="eudev-bootscripts">
296        <term><command>udev</command></term>
297        <listitem>
298          <para>Starts and stops the Eudev daemon</para>
299          <indexterm zone="ch-scripts-bootscripts eudev-bootscripts">
300            <primary sortas="d-eudev">udev</primary>
301          </indexterm>
302        </listitem>
303      </varlistentry>
304
305    </variablelist>
306
307  </sect2>
308
309</sect1>
Note: See TracBrowser for help on using the repository browser.