This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# /etc/udev/rules.d/10-udev-disks.rules | |
# udev custom rule | |
# using # udevadm info -a -p $(udevadm info -q path -n /dev/sda1) | |
# I found the necessary information about my USB device | |
# and take the necessary ones to make it unique (idVendor, idProduct, serial here) | |
# when plugging the disk, nevermind the device name it gets (sda1, sdb1,...) udev creates /dev/mpd-disk and runs the script indicated | |
KERNEL=="sd?1",ATTRS{idVendor}=="xxxx",ATTRS{idProduct}=="yyyy",ATTRS{serial}=="zzzzzzzzzzzz",SYMLINK+="mpd-disk",RUN+="/root/bin/hdparm-mpd-disk.sh" |
NewerOlder