Udev

Udev

Infobox_Software
name = udev



caption =
developer = Greg Kroah-Hartman and Kay Sievers
latest_release_version = 128
latest_release_date = September 11, 2008
operating_system = Linux kernel
genre = device node
license =
website = [http://www.kernel.org/pub/linux/utils/kernel/hotplug/ kernel.org/pub/linux/utils/kernel/hotplug/]

udev is the device manager for the Linux 2.6 kernel series. Primarily, it manages device nodes in /dev. It is the successor of devfs and hotplug, which means that it handles the /dev directory and all user space actions when adding/removing devices, including firmware load.

The latest versions of udev depend on the latest version of the uevent interface of the Linux kernel which has been updated or introduced with Linux kernel 2.6.13. A system using a new version of udev will not boot with kernels older than 2.6.13 unless udev is disabled with bootparam noudev and a traditional /dev directory is used for device access.

Overview

Unlike traditional Unix systems, where the device nodes in the /dev directory have been a static set of files, the Linux udev device manager dynamically provides only the nodes for the devices actually present on a system. Although devfs used to provide similar functionality, advocates of udev cited a number of reasons [cite web |url=http://kernel.org/pub/linux/utils/kernel/hotplug/udev_vs_devfs |title=udev and devfs - The final word |accessdate=2008-01-24 |format=Plain text |author=Greg Kroah-Hartman] for preferring its implementation over devfs:

*udev supports persistent device naming, which does not depend on, for example, the order in which the devices are plugged into the system. The default udev setup provides persistent names for storage devices. Any hard disk is recognized by its unique filesystem id, the name of the disk and the physical location on the hardware it is connected to.
*udev executes entirely in user space, as opposed to devfs' kernel space. One consequence is that udev moved the naming policy out of the kernel and can run arbitrary programs to compose a name for the device from the device's properties, before the node is created.

Operation

udev is a generic kernel device manager. It runs as a daemon on a Linux system and listens to uevents the kernel sends out (via netlink socket) if a new device is initialized or a device is removed from the system.The system provides a set of rules that match against exported values of the event and properties of the discovered device.A matching rule will possibly name and create a device node and run configured programs to set-up and configure the device.

udev rules can match on properties like the kernel subsystem, the kernel device name, the physical location of the device, or properties like the device's serial number. Rules can also request information from external programs to name a device or specify a custom name that will always be the same, regardless of the order devices are discovered by the system.

A common way to use udev on Linux systems is to let it send events through a socket to HAL, which will perform further device-specific actions. For example HAL will notify other software running on the system that the new hardware has arrived by issuing a broadcast message on the D-Bus system IPC bus to all interested processes. In this way, desktops such as GNOME or KDE will be able to pop up a file browser on attached USB flash drives and SD cards, for example. [cite web|url=http://w3.linux-magazine.com/issue/71/Dynamic_Device_Management_in%20Udev.pdf|title=Dynamic Device Management in Udev|publisher=Linux Magazine|date=2006-10-01|accessdate=2008-07-14]

Architecture

The system is divided in three parts:

* The library namedev, that handles the names to be assigned to the devices
* The library libsysfs, that allows access to device information (dropped since version 080)
* The daemon udevd, in user space, that creates the virtual /dev

The system gets calls from the kernel via netlink socket. Earlier versions used hotplug, adding a link to themselves in /etc/hotplug.d/default with this purpose.

Authors

udev was developed by Greg Kroah-Hartman and Kay Sievers, with much help from Dan Stekloff among others.

References

External links

* [http://www.kernel.org/pub/linux/utils/kernel/hotplug/udev.html udev home at kernel.org]
* [http://vrfy.org/log/recent-state-of-udev.html Kay Sievers on the recent state of udev]
* [http://www.reactivated.net/writing_udev_rules.html Discussion of udev rules]
* [http://www.kernel.org/pub/linux/utils/kernel/hotplug/udev-FAQ udev FAQ]
* [http://www.linuxformat.co.uk/pdfs/LXF66.tut_udev.pdf A simple introduction to writing rules for udev]
* [http://www.kroah.com/linux/talks/ols_2003_udev_paper/Reprint-Kroah-Hartman-OLS2003.pdf udev – A Userspace Implementation of devfs by Greg Kroah-Hartman]
* [http://pysdm.sourceforge.net/ PySDM (Storage Device Manager and udev rule writer)]


Wikimedia Foundation. 2010.

Игры ⚽ Поможем написать курсовую

Look at other dictionaries:

  • Udev — Entwickler: Greg Kroah Hartman, Kay Sievers, Dan Stekloff u. v. a Aktuelle Version: 141 (8. April 2009) …   Deutsch Wikipedia

  • Udev — Saltar a navegación, búsqueda udev es el gestor de dispositivos que usa el kernel Linux en su versión 2.6. Su función es controlar los ficheros de dispositivo en /dev. Es el sucesor de devfs. Contenido 1 Motivación 2 Características …   Wikipedia Español

  • udev — Entwickler Greg Kroah Hartman, Kay Sievers, Dan Stekloff u. v. a Aktuelle Version 175 (07. November 2011) …   Deutsch Wikipedia

  • udev — es el gestor de dispositivos que usa el kernel Linux en su versión 2.6. Su función es controlar los ficheros de dispositivo en /dev. Es el sucesor de devfs y de hotplug, lo que significa que maneja el directorio /dev y todas las acciones del… …   Wikipedia Español

  • udev — Тип Device node Разработчик Greg Kroah Hartman и Kay Sievers Написана на С Операционная система Linux (ядро) Первый выпуск ноябрь 2003 года Последняя версия 184 (30 мая …   Википедия

  • Udev — est un gestionnaire de périphériques remplaçant Devfs sur les noyaux Linux de la série 2.6. Sa fonction principale est de gérer les périphériques dans le répertoire /dev. udev s exécute en mode utilisateur et dialogue avec hotplug qui lui s… …   Wikipédia en Français

  • udev — Développeur Greg Kroah Hartman et Kay Sievers Première version …   Wikipédia en Français

  • HAL (software) — HAL Stable release 0.5.14 / November 30, 2009; 23 months ago (2009 11 30) Development status Deprecated; functionality merged with udev Operating system …   Wikipedia

  • HAL (freedesktop.org) — У этого термина существуют и другие значения, см. HAL. HAL Тип Системное ПО Операционная система Linux, FreeBSD, NetBSD, OpenSolaris, Solaris Аппаратная платформа UNIX Последняя версия …   Википедия

  • /dev — Gerätedatei (von engl. device file) sind spezielle Dateien, die unter fast allen Unix Derivaten und vielen anderen Betriebssystemen genutzt werden. Sie ermöglichen eine einfache Kommunikation zwischen Userspace, zum Beispiel gewöhnlichen… …   Deutsch Wikipedia

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”