[9dfc02f] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
[1770019] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN" "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
|
---|
[9dfc02f] | 3 | <!ENTITY % general-entities SYSTEM "../general.ent">
|
---|
| 4 | %general-entities;
|
---|
| 5 | ]>
|
---|
[a001133] | 6 | <sect1 id="ch-system-udev" role="wrap">
|
---|
[9dfc02f] | 7 | <title>Udev-&udev-version;</title>
|
---|
| 8 | <?dbhtml filename="udev.html"?>
|
---|
| 9 |
|
---|
[a001133] | 10 | <indexterm zone="ch-system-udev"><primary sortas="a-Udev">Udev</primary></indexterm>
|
---|
[9dfc02f] | 11 |
|
---|
[a001133] | 12 | <sect2 role="package"><title/>
|
---|
[81fd230] | 13 | <para>The Udev package contains programs for dynamic creation of device nodes.</para>
|
---|
[9dfc02f] | 14 |
|
---|
[a001133] | 15 | <segmentedlist>
|
---|
| 16 | <segtitle>&buildtime;</segtitle>
|
---|
| 17 | <segtitle>&diskspace;</segtitle>
|
---|
[6c511d85] | 18 | <seglistitem><seg>0.1 SBU</seg><seg>3.8 MB</seg></seglistitem>
|
---|
[a001133] | 19 | </segmentedlist>
|
---|
[9dfc02f] | 20 |
|
---|
[81fd230] | 21 | <segmentedlist>
|
---|
[45992ae] | 22 | <segtitle>&dependencies;</segtitle>
|
---|
[1a89152] | 23 | <seglistitem><seg>Coreutils, GCC, Make, and Perl</seg></seglistitem>
|
---|
[81fd230] | 24 | </segmentedlist>
|
---|
| 25 |
|
---|
[a001133] | 26 | </sect2>
|
---|
| 27 |
|
---|
| 28 | <sect2 role="installation">
|
---|
[9dfc02f] | 29 | <title>Installation of Udev</title>
|
---|
| 30 |
|
---|
[81fd230] | 31 | <para>Compile the package:</para>
|
---|
[9dfc02f] | 32 |
|
---|
[8b51e27] | 33 | <screen><userinput>make EXTRAS=extras/run_directory</userinput></screen>
|
---|
[81fd230] | 34 |
|
---|
[09043c0] | 35 | <para>The meaning of the make option:</para>
|
---|
| 36 |
|
---|
| 37 | <variablelist>
|
---|
| 38 | <varlistentry>
|
---|
| 39 | <term><parameter>EXTRAS=extras/run_directory</parameter>
|
---|
| 40 | </term>
|
---|
| 41 | <listitem>
|
---|
| 42 | <para>This builds the <command>udev_run_devd</command> and
|
---|
| 43 | <command>udev_run_hotplugd</command> binaries, which are required for
|
---|
| 44 | correct handling of hotpluggable devices.
|
---|
| 45 | </para>
|
---|
| 46 | </listitem>
|
---|
| 47 | </varlistentry>
|
---|
| 48 | </variablelist>
|
---|
| 49 |
|
---|
[317b76b] | 50 | <para>To test the results, issue:
|
---|
[5f6ad4e] | 51 | <userinput>make test</userinput>.</para>
|
---|
[81fd230] | 52 |
|
---|
| 53 | <para>Install the package:</para>
|
---|
[9dfc02f] | 54 |
|
---|
[09043c0] | 55 | <screen><userinput>make DESTDIR=/ EXTRAS=extras/run_directory install</userinput></screen>
|
---|
| 56 |
|
---|
| 57 | <para>The meaning of the make option:</para>
|
---|
| 58 |
|
---|
| 59 | <variablelist>
|
---|
| 60 | <varlistentry>
|
---|
| 61 | <term><parameter>DESTDIR=/</parameter>
|
---|
| 62 | </term>
|
---|
| 63 | <listitem>
|
---|
| 64 | <para>This prevents the Udev build process from killing any
|
---|
| 65 | <command>udevd</command> processes that may be running on the host
|
---|
| 66 | system.
|
---|
| 67 | </para>
|
---|
| 68 | </listitem>
|
---|
| 69 | </varlistentry>
|
---|
| 70 | </variablelist>
|
---|
[9dfc02f] | 71 |
|
---|
[81fd230] | 72 | <para>Udev's configuration is far from ideal by default, so install
|
---|
| 73 | the configuration files here:</para>
|
---|
[18da154] | 74 |
|
---|
[c8c8222] | 75 | <screen><userinput>cp -v ../&udev-config-file; /etc/udev/rules.d/25-lfs.rules</userinput></screen>
|
---|
[18da154] | 76 |
|
---|
[7eac3e32] | 77 | <para>Install the documentation that explains how to create Udev rules:</para>
|
---|
| 78 |
|
---|
[5998892] | 79 | <screen><userinput>install -m644 -D -v docs/writing_udev_rules/index.html /usr/share/doc/udev-&udev-version;/index.html</userinput></screen>
|
---|
[7eac3e32] | 80 |
|
---|
[46a2e9c] | 81 | <!-- Not for the LiveCD -->
|
---|
[81fd230] | 82 | <!-- Edit Me -->
|
---|
| 83 | <para>Run the <command>udevstart</command> program to create our full
|
---|
[09bd7b3] | 84 | complement of device nodes.</para>
|
---|
[6135b95] | 85 |
|
---|
| 86 | <screen><userinput>/sbin/udevstart</userinput></screen>
|
---|
| 87 |
|
---|
[9dfc02f] | 88 | </sect2>
|
---|
| 89 |
|
---|
[c6cb3aa] | 90 | <sect2 id="contents-udev" role="content"><title>Contents of Udev</title>
|
---|
[9dfc02f] | 91 |
|
---|
[81fd230] | 92 | <segmentedlist>
|
---|
| 93 | <segtitle>Installed programs</segtitle>
|
---|
| 94 | <segtitle>Installed directory</segtitle>
|
---|
[8b51e27] | 95 | <seglistitem><seg>udev, udev_run_devd, udev_run_hotplugd, udevcontrol, udevd,
|
---|
[67d9211] | 96 | udevinfo, udevmonitor, udevsend, udevstart, and udevtest</seg>
|
---|
[81fd230] | 97 | <seg>/etc/udev</seg></seglistitem>
|
---|
| 98 | </segmentedlist>
|
---|
[32324418] | 99 |
|
---|
[81fd230] | 100 | <variablelist><bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 101 | <?dbfo list-presentation="list"?>
|
---|
[8f97096] | 102 | <?dbhtml list-presentation="table"?>
|
---|
[81fd230] | 103 |
|
---|
| 104 | <varlistentry id="udev">
|
---|
| 105 | <term><command>udev</command></term>
|
---|
| 106 | <listitem>
|
---|
| 107 | <para>Creates device nodes in <filename
|
---|
| 108 | class="directory">/dev</filename> or renames network interfaces (not
|
---|
| 109 | in LFS) in response to hotplug events</para>
|
---|
| 110 | <indexterm zone="ch-system-udev udev"><primary sortas="b-udev">udev</primary></indexterm>
|
---|
| 111 | </listitem></varlistentry>
|
---|
| 112 |
|
---|
[8b51e27] | 113 | <varlistentry id="udev_run_devd">
|
---|
| 114 | <term><command>udev_run_devd</command></term>
|
---|
| 115 | <listitem>
|
---|
[67d9211] | 116 | <para>Executes programs and scripts in the
|
---|
[8b51e27] | 117 | <filename class="directory">/etc/dev.d/</filename> directory in response
|
---|
| 118 | to hotplug events
|
---|
| 119 | </para>
|
---|
| 120 | <indexterm zone="ch-system-udev udev_run_devd">
|
---|
| 121 | <primary sortas="b-udev_run_devd">udev_run_devd</primary>
|
---|
| 122 | </indexterm>
|
---|
| 123 | </listitem>
|
---|
| 124 | </varlistentry>
|
---|
| 125 |
|
---|
| 126 | <varlistentry id="udev_run_hotplugd">
|
---|
| 127 | <term><command>udev_run_hotplugd</command></term>
|
---|
| 128 | <listitem>
|
---|
[67d9211] | 129 | <para>Executes programs and scripts in the
|
---|
[8b51e27] | 130 | <filename class="directory">/etc/hotplug.d/</filename> directory in
|
---|
| 131 | response to hotplug events
|
---|
| 132 | </para>
|
---|
| 133 | <indexterm zone="ch-system-udev udev_run_hotplugd">
|
---|
| 134 | <primary sortas="b-udev_run_hotplugd">udev_run_hotplugd</primary>
|
---|
| 135 | </indexterm>
|
---|
| 136 | </listitem>
|
---|
| 137 | </varlistentry>
|
---|
| 138 |
|
---|
[6c511d85] | 139 | <varlistentry id="udevcontrol">
|
---|
| 140 | <term><command>udevcontrol</command></term>
|
---|
| 141 | <listitem>
|
---|
| 142 | <para>Configures a number of options for the running <command>udevd</command>
|
---|
| 143 | daemon, such as the log level.</para>
|
---|
| 144 | <indexterm zone="ch-system-udev udevcontrol"><primary sortas="b-udevcontrol">udevcontrol</primary>
|
---|
| 145 | </indexterm>
|
---|
| 146 | </listitem></varlistentry>
|
---|
| 147 |
|
---|
[81fd230] | 148 | <varlistentry id="udevd">
|
---|
| 149 | <term><command>udevd</command></term>
|
---|
| 150 | <listitem>
|
---|
| 151 | <para>A daemon that reorders hotplug events before submitting them to
|
---|
| 152 | <command>udev</command>,
|
---|
| 153 | thus avoiding various race conditions</para>
|
---|
| 154 | <indexterm zone="ch-system-udev udevd"><primary sortas="b-udevd">udevd</primary></indexterm>
|
---|
| 155 | </listitem></varlistentry>
|
---|
| 156 |
|
---|
[6c511d85] | 157 | <varlistentry id="udevinfo">
|
---|
| 158 | <term><command>udevinfo</command></term>
|
---|
| 159 | <listitem>
|
---|
| 160 | <para>Allows users to query the <command>udev</command> database for
|
---|
| 161 | information on any device currently present on the system; it also
|
---|
| 162 | provides a way to query any device in the <systemitem
|
---|
| 163 | class="filesystem">sysfs</systemitem> tree to help create udev
|
---|
| 164 | rules</para>
|
---|
| 165 | <indexterm zone="ch-system-udev udevinfo"><primary sortas="b-udevinfo">udevinfo</primary></indexterm>
|
---|
| 166 | </listitem></varlistentry>
|
---|
| 167 |
|
---|
| 168 | <varlistentry id="udevmonitor">
|
---|
| 169 | <term><command>udevmonitor</command></term>
|
---|
| 170 | <listitem>
|
---|
| 171 | <para>Prints the event received from the kernel and the event which
|
---|
| 172 | <command>udev</command> sends out after rule processing</para>
|
---|
| 173 | <indexterm zone="ch-system-udev udevmonitor"><primary sortas="b-udevmonitor">udevmonitor</primary>
|
---|
| 174 | </indexterm>
|
---|
| 175 | </listitem></varlistentry>
|
---|
| 176 |
|
---|
[81fd230] | 177 | <varlistentry id="udevsend">
|
---|
| 178 | <term><command>udevsend</command></term>
|
---|
| 179 | <listitem>
|
---|
| 180 | <para>Delivers hotplug events to <command>udevd</command></para>
|
---|
| 181 | <indexterm zone="ch-system-udev udevsend"><primary sortas="b-udevsend">udevsend</primary></indexterm>
|
---|
| 182 | </listitem></varlistentry>
|
---|
| 183 |
|
---|
| 184 | <varlistentry id="udevstart">
|
---|
| 185 | <term><command>udevstart</command></term>
|
---|
| 186 | <listitem>
|
---|
| 187 | <para>Creates device nodes in <filename
|
---|
| 188 | class="directory">/dev</filename> that correspond to drivers compiled directly
|
---|
| 189 | into the kernel; it performs that task by simulating hotplug events presumably
|
---|
| 190 | dropped by the kernel before invocation of this program (e.g., because the root
|
---|
| 191 | filesystem has not been mounted) and submitting such synthetic hotplug events
|
---|
| 192 | to <command>udev</command></para>
|
---|
| 193 | <indexterm zone="ch-system-udev udevstart"><primary sortas="b-udevstart">udevstart</primary></indexterm>
|
---|
| 194 | </listitem>
|
---|
| 195 | </varlistentry>
|
---|
| 196 |
|
---|
| 197 | <varlistentry id="udevtest">
|
---|
| 198 | <term><command>udevtest</command></term>
|
---|
| 199 | <listitem>
|
---|
| 200 | <para>Simulates a <command>udev</command> run for the given device,
|
---|
| 201 | and prints out the name of the node the real <command>udev</command> would
|
---|
| 202 | have created or (not in LFS) the name of the renamed network interface</para>
|
---|
| 203 | <indexterm zone="ch-system-udev udevtest"><primary sortas="b-udevtest">udevtest</primary></indexterm>
|
---|
| 204 | </listitem></varlistentry>
|
---|
| 205 |
|
---|
| 206 | <varlistentry id="etc-udev">
|
---|
| 207 | <term><filename class="directory">/etc/udev</filename></term>
|
---|
| 208 | <listitem>
|
---|
| 209 | <para>Contains <command>udev</command> configuation files,
|
---|
| 210 | device permissions, and rules for device naming</para>
|
---|
[32b21a1] | 211 | <indexterm zone="ch-system-udev etc-udev"><primary sortas="e-/etc/udev">/etc/udev</primary></indexterm>
|
---|
[81fd230] | 212 | </listitem></varlistentry>
|
---|
| 213 | </variablelist>
|
---|
[32324418] | 214 | </sect2>
|
---|
[9dfc02f] | 215 |
|
---|
| 216 | </sect1>
|
---|
[81fd230] | 217 |
|
---|