[Grml] Speeding up udev?

Michael Schierl schierlm at gmx.de
Wed Jul 1 20:03:22 CEST 2009

Hermann schrieb:

> So is there a chance to speed up udev? I didn't find anything in the
> manual that refers to "speeding up the procedure".
> Any hints?

Udev basically works as follows:

When booting, the /etc/init.d/udev script runs

udevadm trigger

which will create a "device added" event for all the hardware that is
currently present (which is usually quite a lot). Those events are
handled by udevd, which will parse the rules in /etc/udev/rules.d and
/lib/udev/rules.d and run the command(s) mentioned there (like create
device nodes, insert modules, etc.).

The udev script will then run

udevadm settle

which will wait until udevd has handled all of those events.

When you add a device later (like plug in an USB device) this will
create a new "device added" event which will be handled the same way
(parsing rules, running command).

The only way of speeding this up is changing (or removing) (some of) the
rules. It will need a bit of trial and error to find the rules that make
your system slow though.

When you delete all rules, udev will be blazingly fast, but it will not
do anything any longer just as if it was disabled.

You can watch udev events by running

udevadm monitor

in another console (and then for example run udevadm trigger to "re-add"
all the hardware agein).

Hope that helps,


More information about the Grml mailing list