LDP/LDP/retired/PLD-Guide/admin-manual/sysconfig.xml

246 lines
7.1 KiB
XML

<chapter>
<title>System configuration</title>
<section id="modules">
<title>Device support (kernel modules config)</title>
<para>
PLD contains highly modularized kernel.
All kernel-supported device drivers that can be compiled as a module
are compiled in this way.
</para>
<para>
To support devices available in the system, proper modules must be
loaded into the kernel. That can be done primarily in four ways:
<orderedlist>
<listitem>
<para>
They can be loaded by hand with <command>modprobe</command> or
<command>insmod</command> command (the least convenient method)
</para>
</listitem>
<listitem>
<para>
They can be loaded at boot-up by some extra script
(e.g. /etc/rc.d/init/rc.local).
</para>
</listitem>
<listitem>
<para>
Some devices (mainly disk interfaces)
need support at a very, very early stage of system boot-up.
Modules for these devices must be loaded from
so-called <emphasis>initrd</emphasis>
(see more in <xref linkend="bootloaders"/>)
</para>
</listitem>
<listitem>
<para>
Finally, they can be loaded automatically, when they are
needed, by <command>kmod</command> daemon.
</para>
</listitem>
</orderedlist>
The latter method is most convenient, although not every device can be
supported like that.
</para>
<para>
Kmod needs information what module should be associated to particular
devices.
</para>
<note>
<para>
During installation process the installer takes care about
setting proper <emphasis>initrd</emphasis>, and may also
put some entries into <filename>/etc/modules.conf</filename>.
(e.g. aliases for network devices), but in general this
file should be filled in by the administrator.
</para>
</note>
<para>
Some typical settings in <filename>/etc/modules.conf</filename>:
</para>
<programlisting>
# Use kernel module 3c509 (3Com 509/509b adapter) as a driver for
# first ethernet device (eth0):
alias eth0 3c509
# Use kernel module aic7xxx to handle SCSI hostadapter:
scsi_hostadapter aic7xxx
</programlisting>
<para>
See
<citerefentry>
<refentrytitle>modules.conf</refentrytitle>
<manvolnum>5</manvolnum>
</citerefentry>
for details.
</para>
</section>
<section id="disks">
<title>Disks</title>
<para>
</para>
<literallayout>
fstab:
disks
removable media: CD, diskettes etc
user access
automounter
LVM?
journaling?
raid?
</literallayout>
</section>
<section id="inittab">
<title>Init control: /etc/inittab</title>
<para>
The file <filename>/etc/inittab</filename> is read by
<command>init</command> process to control
system behavior in particular runlevel. Full description
of this file can be found in
<citerefentry>
<refentrytitle>inittab</refentrytitle>
<manvolnum>5</manvolnum>
</citerefentry>
</para>
<para>
What this file usually contains:
<itemizedlist>
<listitem>
<para>
<emphasis>Default runlevel</emphasis> - the runlevel used
when init is invoked without parameters (e.g. during system startup).
Runlevels are described in <xref linkend="runlevels"/>.
Default runlevel is given in the form:
<programlisting>id:3:initdefault:</programlisting>
Here the digit 3 indicates use of runlevel 3. This can be changed
to any other valid runlevel.
</para>
</listitem>
<listitem>
<para>
Instructions to run getty on consoles. They look like that:
<programlisting>1:12345:respawn:/sbin/mingetty --noclear tty1</programlisting>
One of possible situations when this needs to be changed is
when we want console on serial port (see e.g. <xref linkend="installer-serial"/>).
</para>
</listitem>
<listitem>
<para>
Invocation of proper init scripts. These are lines like this:
<programlisting>
si::sysinit:/etc/rc.d/rc.sysinit
l0:0:wait:/etc/rc.d/rc 0
</programlisting>
This rarely needs to be changed.
</para>
</listitem>
<listitem>
<para>
Handling special events like Ctrl-Alt-Del keystroke.
The line looks like this:
<programlisting>
ca::ctrlaltdel:/sbin/shutdown -t3 -r now
</programlisting>
The command run at Ctrl-Alt-Del event can be replaced here,
e.g. one can change <command>shutdown -r</command>
to <command>shutdown -h</command> to get the halt instead reboot.
</para>
</listitem>
</itemizedlist>
</para>
</section>
<section id="etc-sysconfig">
<title>Basic system configuration: <filename>/etc/sysconfig</filename></title>
<section>
<title>Intro</title>
<para>
Directory <filename>/etc/sysconfig</filename> contains several files
that are used by rc-scripts (system startup scripts located in
/etc/rc.d). Those files defines basic properties of the system.
</para>
</section>
<section>
<title>console</title>
<para>
File <filename>/etc/sysconfig/console</filename>
contains basic console settings.
</para>
<para>
After modifying config file, issue
<programlisting>/etc/rc.d/init.d/console restart</programlisting>
if you want the changes to take effect.
</para>
</section>
<section>
<title>mouse</title>
<para>
File <filename>/etc/sysconfig/mouse</filename> contains
mouse settings for service <command>gpm</command> (General Purpose Mouse).
This service provides mouse support for console based
applications and may be also used by X Window System.
<!-- (see <xref linkend="x-repeater"/>) -->
</para>
<para>
After modifying config file, issue
<programlisting>/etc/rc.d/init.d/gpm restart</programlisting>
if you want the changes to take effect.
</para>
</section>
<section>
<title>clock</title>
<para>
File <filename>/etc/sysconfig/clock</filename> contains
clock settings.
Its content is used by /etc/rc.d/rc.sysinit script
at very early stage of system bootup.
This file contains very general clock properties.
Setting clock can be done with <command>date</command>
and <command>hwclock</command> commands.
</para>
</section>
<section>
<title>system</title>
<para>
Its content is used by rc-scripts at very early stage of system bootup.
It contains some basic settings, e.g. system behavior in case of kernel
panic, etc.
</para>
</section>
</section>
<section id="printing">
<title>Printing</title>
<para>
</para>
</section>
<section id="x-window">
<title>X Window</title>
<para>
</para>
</section>
</chapter>
<!-- Keep this comment at the end of the file
Local variables:
mode: xml
sgml-omittag:nil
sgml-shorttag:nil
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:2
sgml-indent-data:t
sgml-default-dtd-file:"../dbxbook4.1.2.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
sgml-declaration:nil
sgml-validate-command:"rxp -sxV %s %s"
sgml-parent-document:("PLD-Guide.xml" "book" "section")
End:
-->