Differences
This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| udevadm [2018/04/09 08:02] – created beandog | udevadm [2018/04/09 08:07] (current) – beandog | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| ====== udevadm ====== | ====== udevadm ====== | ||
| + | |||
| + | * [[udev]] | ||
| You can use udevadm to see the variables set by udev for a device. This is helpful if you want to get information about the device, based on whether it has a DVD or a CD in there, for example. | You can use udevadm to see the variables set by udev for a device. This is helpful if you want to get information about the device, based on whether it has a DVD or a CD in there, for example. | ||
| Line 5: | Line 7: | ||
| < | < | ||
| udevadm info /dev/sr0 | udevadm info /dev/sr0 | ||
| + | </ | ||
| + | |||
| + | If you want to change any rules, such as in ''/ | ||
| + | |||
| + | < | ||
| + | udevadm trigger | ||
| + | </ | ||
| + | |||
| + | That's what I use when doing my onevent trayclose calls. | ||
| + | |||
| + | In ''/ | ||
| + | |||
| + | < | ||
| + | # Sony Blu-ray | ||
| + | SUBSYSTEM==" | ||
| + | SUBSYSTEM==" | ||
| + | SUBSYSTEM==" | ||
| + | </ | ||
| + | |||
| + | For completion' | ||
| + | |||
| + | < | ||
| + | #!/bin/bash | ||
| + | mount -o ro -t udf $DEVNAME &> /dev/null | ||
| + | if [[ -z " | ||
| + | echo "/ | ||
| </ | </ | ||