10.75. Udev-093

The Udev package contains programs for dynamic creation of device nodes.

10.75.1. Installation of Udev

Compile the package:

make CC="gcc ${BUILD64}" LD="gcc ${BUILD64}" \
 EXTRAS="extras/cdrom_id extras/floppy extras/firmware extras/scsi_id extras/volume_id \
            extras/ata_id extras/usb_id extras/edd_id extras/dasd_id extras/path_id" udevdir=/dev

The meaning of the make parameter:

EXTRAS="extras/floppy extras/cdrom_id extras/firmware extras/scsi_id extras/volume_id extras/ata_id extras/usb_id extras/edd_id extras/dasd_id extras/path_id"

This builds the helper applications that are used with udev. The helper programs assist in correct handling of devices.

If you want to run the testsuite, you need to change a hardcoded reference to the test program:

sed -i 's@/usr/bin/test@/bin/test@' test/udev-test.pl

To test the results, issue: make test.

Install the package:

make DESTDIR=/ \
    EXTRAS="extras/floppy extras/cdrom_id extras/firmware \
    extras/scsi_id extras/volume_id extras/ata_id extras/usb_id \
    extras/edd_id extras/dasd_id extras/path_id" udevdir=/dev install

The meaning of the make parameter:

DESTDIR=/

This prevents the Udev build process from killing any udevd processes that may be running on the system.

Install necessary helpers.

install -v extras/eventrecorder.sh /lib/udev

Install the documentation that explains how to create Udev rules:

install -v -m644 -D docs/writing_udev_rules/index.html \
    /usr/share/doc/udev-093/index.html

Create a directory for storing firmware that can be loaded by udev:

install -dv /lib/firmware

10.75.2. Contents of Udev

Installed programs: udevcontrol, udevd, udevinfo, udevmonitor, udevsend, udevtest, and udevtrigger
Installed directory: /etc/udev

Short Descriptions

udevcontrol

Configures a number of options for the running udevd daemon, such as the log level.

udevd

A daemon that reorders hotplug events before submitting them to udev, thus avoiding various race conditions

udevinfo

Allows users to query the udev database for information on any device currently present on the system; it also provides a way to query any device in the sysfs tree to help create udev rules

udevmonitor

Prints the event received from the kernel and the event which udev sends out after rule processing

udevsettle

Watches the Udev event queue and exits if all current uevents have been handled

udevtest

Simulates a udev run for the given device, and prints out the name of the node the real udev would have created or (not in CLFS) the name of the renamed network interface

udevtrigger

Walks the sysfs tree for devices that need to be added to the system.

ata_id

Provides Udev with a unique string and additional information (uuid, label) for an ATA drive

cdrom_id

To be written

create_floppy_devices

Creates all possible floppy devices based on the CMOS type

firmware.sh

To be written

path_id

Provide the shortest possible unique hardware path to a device

scsi_id

To be written

vol_id

To be written

usb_id

To be written

edd_id

To be written

dasd_id

To be written

/etc/udev

Contains udev configuation files, device permissions, and rules for device naming

/lib/udev

Contains udev helper programs and static devices which get copied to /dev when booted.