Hi, I would like to receive an event (actually run a script) when I plug/unplugged an usb cable. I tried to use udev with this simple rule: SUBSYSTEM=="usb",RUN+="/var/local/usb-changed.sh"
I do receive the "add" event when I plug the usb cable: just perfect ! But I never receive the "remove" event. Any idea why ? More information: I use linux kernel v3.16. When the cable is plugged, I load the kernel module "g_mass_storage", this work great. My need is to unload the module when the usb cable is unplugged (note it would be even better if I receive an event when the mass-storage is unmounted by the other host, but I do not have any idea where to look for.) Thanks by advance for any hint. Christophe _______________________________________________ systemd-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/systemd-devel
