chiark / gitweb /
[PATCH] don't sleep if 'dev' file is already present on device add.
[elogind.git] / udev.8
1 .TH UDEV 8 "October 2003" "" "Linux Administrator's Manual"
2 .SH NAME
3 udev \- Linux configurable dynamic device naming support
4 .SH SYNOPSIS
5 .B udev
6 .SH "DESCRIPTION"
7 .B udev
8 creates or removes device node files usually located in the /dev directory.
9 As part of the
10 .B hotplug
11 subsystem,
12 .B udev
13 is exectuted if a kernel device is added or removed from the system.
14 .P
15 On device creation,
16 .B udev
17 reads the sysfs directory of the given device, to collect device attributes
18 like label, serial number or bus device number.
19 These attributes are passed as a key to the namedev subsystem
20 to receive a unique name for device file creation.
21 namedev maintains a database for devices present on the system.
22 .P
23 On device removal,
24 .B udev
25 queries the namedev database for the name of the device file to delete.
26 .P
27 namedev expects its configuration at
28 .I /etc/udev/namedev.config.
29 The file consists of a set of lines. All empty lines and
30 lines beginning with a '#' will be ignored.
31 .br
32 Every line defines the mapping between device attributes and the name of
33 the device file. It starts with a keyword defining the method for
34 overriding the default kernel naming scheme, followed by a list
35 of keys and ends with the definition of the filename for the device.
36 .TP
37 .B LABEL
38 device label or serial number, like USB serial number, SCSI UUID or
39 file system label
40 .TP
41 .B NUMBER
42 device number on the bus, like PCI bus id
43 .TP
44 .B TOPOLOGY
45 device position on bus, like physical port of USB device
46 .TP
47 .B REPLACE
48 string replacement of the kernel device name
49 .P
50 If no matching configuration is found, the default kernel device name is used.
51 .SH "EXAMPLE"
52 .nf
53 # USB printer to be called lp_color
54 LABEL, BUS="usb", serial="W09090207101241330", NAME="lp_color"
55
56 # sound card with PCI bus id 00:0b.0 to be called dsp
57 NUMBER, BUS="pci", id="00:0b.0", NAME="dsp"
58
59 # USB mouse at third port of the second hub to be called mouse1
60 TOPOLOGY, BUS="usb", place="2.3", NAME="mouse1"
61
62 # ttyUSB1 should always be called pda
63 REPLACE, KERNEL="ttyUSB1", NAME="pda"
64 .fi
65 .SH "FILES"
66 .nf
67 .ft B
68 .ft
69 /sbin/udev                           udev program
70 /etc/udev/*                          udev config and database files
71 /etc/hotplug.d/default/udev.hotplug  hotplug symlink to udev program
72 .fi
73 .LP
74 .SH "SEE ALSO"
75 .B hotplug (8)
76 .PP
77 The
78 .I http://linux-hotplug.sourceforge.net/
79 web site.
80 .SH AUTHORS
81 udev was developed by Greg Kroah-Hartman <greg@kroah.com> with much help from
82 Dan Stekloff <dsteklof@us.ibm.com> and many others.