playing around with udev / hal / dbus

20 Jan

well, with a recent linux distribution, hotplug is no longer the way to go (on ubuntu 8.10 there are almost no traces of hotplug left over…)

first attempt: udev

the most obvious way seems to be udev which supersedes hotplug

first, raise udev-verbosity by adjusting its logging level:

sudo udevadm control log_priority=info

find out the vendor- and product-id of your usb-device:

# lsusb

create a rule file for that device, e.g. /etc/udev/rules.d/99-local.rules

# 05e3:0714 -- A-DATA 2GB SD Duo Card
ACTION=="add", SYSFS{idVendor}=="05e3", SYSFS{idProduct}=="0714", RUN+="/script/to/call.sh"

now script specified under “RUN” is called when this very device is connected to the usb…

Leave a Reply

Your email address will not be published. Required fields are marked *