← All tools

udev Rule Builder

Match a device by subsystem, kernel name and parent attributes, and give it a stable name and permissions.

Match
as udev reports it: tty, usb, block, net, input
glob allowed: ttyUSB*, ttyACM[0-9], leave blank for any
ATTRS searches up the parent chain, where a USB adapter's idVendor lives
sysfs name, or blank to skip
exact or glob, quoted in the rule
a second match, or blank
leave both fields blank to skip
Assign
octal, 0000 to 0777
user name or numeric id, blank to leave it
group name or numeric id
Press Compose rule to build the sample rule.

udev composes nothing for you: it reads every .rules file in /etc/udev/rules.d in lexical order and applies the last matching assignment, so a 99- prefix runs after the distribution's own rules. ATTR{name} reads an attribute of the device the event is for, while ATTRS{name} searches the device and its parents; a USB serial adapter's idVendor and idProduct live on the USB device, not on the tty, which is why the default here uses ATTRS. A SYMLINK+ adds a name beside the kernel-assigned one and never replaces it. This page only composes text: it reads nothing from your machine, cannot install the rule, and needs no network access. Save the file as root, then reload the rules and trigger the subsystem for existing devices.