what is it?
user space system that enables the operating system administrator to register user space handlers for events. The events received by udev’s daemon are mainly generated by the Linux kernel in response to physical events relating to peripheral devices.
udev rules
- file name has to end with .rules
- udev rules written by the administrator go in
/etc/udev/rules.d/ - udev rules shipped with various packages are found in
/usr/lib/udev/rules.d/
USB port permissions for QEMU VM pass-through
get the device vendor and product id
❯ lsusb
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 010: ID <vendor>:<product> Line6, Inc. HELIXadd a udev rule, adds group write/read and uaccess tag
sudoedit /etc/udev/rules.d/71-device-name.rules
ACTION!="remove", SUBSYSTEMS=="usb", ATTRS{idVendor}=="<vendor>", ATTRS{idProduct}=="<product>", MODE="0660", TAG+="uaccess"