source: chapter06/udev.xml@ 7111666

10.0 10.0-rc1 10.1 10.1-rc1 11.0 11.0-rc1 11.0-rc2 11.0-rc3 11.1 11.1-rc1 11.2 11.2-rc1 11.3 11.3-rc1 12.0 12.0-rc1 12.1 12.1-rc1 6.1 6.1.1 6.3 6.4 6.5 6.6 6.7 6.8 7.0 7.1 7.2 7.3 7.4 7.5 7.5-systemd 7.6 7.6-systemd 7.7 7.7-systemd 7.8 7.8-systemd 7.9 7.9-systemd 8.0 8.1 8.2 8.3 8.4 9.0 9.1 arm bdubbs/gcc13 ml-11.0 multilib renodr/libudev-from-systemd s6-init trunk xry111/arm64 xry111/arm64-12.0 xry111/clfs-ng xry111/lfs-next xry111/loongarch xry111/loongarch-12.0 xry111/loongarch-12.1 xry111/mips64el xry111/pip3 xry111/rust-wip-20221008 xry111/update-glibc
Last change on this file since 7111666 was 6135b95, checked in by Jeremy Utley <jeremy@…>, 20 years ago

Experimental - don't build udev in chapter 5, instead create a minimal device enviornment at the beginning of chapter 6, and run udevstart after udev is installed in chapter 6.

git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@4295 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689

  • Property mode set to 100644
File size: 5.1 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN" "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
3 <!ENTITY % general-entities SYSTEM "../general.ent">
4 %general-entities;
5]>
6<sect1 id="ch-system-udev" role="wrap">
7<title>Udev-&udev-version;</title>
8<?dbhtml filename="udev.html"?>
9
10<indexterm zone="ch-system-udev"><primary sortas="a-Udev">Udev</primary></indexterm>
11
12<sect2 role="package"><title/>
13<para>The Udev package contains programs for dynamic creation of device nodes.</para>
14
15<segmentedlist>
16<segtitle>&buildtime;</segtitle>
17<segtitle>&diskspace;</segtitle>
18<seglistitem><seg>0.2 SBU</seg><seg>5.2 MB</seg></seglistitem>
19</segmentedlist>
20
21</sect2>
22
23<sect2 role="installation">
24<title>Installation of Udev</title>
25
26<para>Compile Udev:</para>
27
28<screen><userinput>make udevdir=/dev</userinput></screen>
29
30<variablelist>
31<varlistentry>
32<term><parameter>udevdir=/dev</parameter></term>
33<listitem><para>This tells <command>udev</command> which directory it is to
34create device nodes in.</para></listitem>
35</varlistentry>
36</variablelist>
37
38<para>Install it:</para>
39
40<screen><userinput>make udevdir=/dev install</userinput></screen>
41
42<para>Udev's configuration is far from ideal by default, so we install our own
43configuration files here:</para>
44
45<screen><userinput>cp ../udev-config-2.permissions /etc/udev/permissions.d/25-lfs.permissions
46cp ../udev-config-1.rules /etc/udev/rules.d/25-lfs.rules</userinput></screen>
47
48<para>Finally, we'll allow udev to create the full compliment of device
49nodes, since earlier we only created a minimal set.</para>
50
51<screen><userinput>/sbin/udevstart</userinput></screen>
52
53</sect2>
54
55
56<sect2 id="contents-udev" role="content"><title>Contents of Udev</title>
57
58<segmentedlist>
59<segtitle>Installed programs</segtitle>
60<seglistitem><seg>udev, udevd, udevsend, udevstart, udevinfo, udevtest</seg></seglistitem>
61</segmentedlist>
62
63<variablelist><title>Short descriptions</title>
64
65<varlistentry id="udev">
66<term><command>udev</command></term>
67<listitem><indexterm zone="ch-system-udev udev"><primary
68sortas="b-udev">udev</primary></indexterm>
69<para>is used to create device nodes in <filename
70class="directory">/dev</filename> or to rename network interfaces (not in LFS)
71in response to hotplug events.</para>
72</listitem></varlistentry>
73
74<varlistentry id="udevd">
75<term><command>udevd</command></term>
76<listitem> <indexterm zone="ch-system-udev udevd"><primary
77sortas="b-udevd">udevd</primary></indexterm>
78<para>is a daemon that reorders hotplug events before submitting them to
79<command>udev</command>,
80thus avoiding various race conditions.</para>
81</listitem></varlistentry>
82
83<varlistentry id="udevsend">
84<term><command>udevsend</command></term>
85<listitem> <indexterm zone="ch-system-udev udevsend"><primary
86sortas="b-udevsend">udevsend</primary></indexterm>
87<para>is used to deliver hotplug events to <command>udevd</command>.</para>
88</listitem></varlistentry>
89
90<varlistentry id="udevstart">
91<term><command>udevstart</command></term>
92<listitem> <indexterm zone="ch-system-udev udevstart"><primary
93sortas="b-udevstart">udevstart</primary></indexterm>
94<para>is used to create device nodes in <filename
95class="directory">/dev</filename> that correspond to drivers compiled directly
96into the kernel. It performs that task by simulating hotplug events presumably
97dropped by the kernel before invocation of this program (e.g. because the root
98filesystem has not been mounted) and submitting such synthetic hotplug events
99to <command>udev</command>.</para>
100</listitem>
101</varlistentry>
102
103<varlistentry id="udevinfo">
104<term><command>udevinfo</command></term>
105<listitem> <indexterm zone="ch-system-udev udevinfo"><primary
106sortas="b-udevinfo">udevinfo</primary></indexterm>
107<para>allows users to query the <command>udev</command> database for
108information on any device currently present on the system. It also
109provides a way to query any device in the sysfs tree to help creating udev
110rules.</para>
111</listitem></varlistentry>
112
113<varlistentry id="udevtest">
114<term><command>udevtest</command></term>
115<listitem> <indexterm zone="ch-system-udev udevtest"><primary
116sortas="b-udevtest">udevtest</primary></indexterm>
117<para>simulates a <command>udev</command> run for the given device,
118and prints out the name of the node the real <command>udev</command> would
119have created, or (not in LFS) the name of the renamed network interface.</para>
120</listitem></varlistentry>
121
122<varlistentry id="etc-dev-d">
123<term><filename class="directory">/etc/dev.d</filename></term>
124<listitem> <indexterm zone="ch-system-udev etc-dev-d"><primary
125sortas="e-etc-dev-d">/etc/dev.d</primary></indexterm>
126<para>directory is supposed to contain user-written handlers for device
127creation hotplug events.</para>
128</listitem></varlistentry>
129
130<varlistentry id="etc-udev">
131<term><filename class="directory">/etc/udev</filename></term>
132<listitem> <indexterm zone="ch-system-udev etc-udev"><primary
133sortas="e-etc-udev">/etc/udev</primary></indexterm>
134<para>directory contains <command>udev</command> configuration files,
135device permissions and rules for device naming.</para>
136</listitem></varlistentry>
137</variablelist>
138</sect2>
139
140</sect1>
Note: See TracBrowser for help on using the repository browser.