From mboxrd@z Thu Jan 1 00:00:00 1970 From: Greg KH Date: Fri, 26 Mar 2004 19:51:08 +0000 Subject: Re: add/remove actions for usb devices Message-Id: <20040326195108.GA25791@kroah.com> List-Id: References: <40648838.2040703@labri.fr> In-Reply-To: <40648838.2040703@labri.fr> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: linux-hotplug@vger.kernel.org On Fri, Mar 26, 2004 at 08:44:56PM +0100, Florian Iragne wrote: > Hello everybody, > > i've just a simple question and i didn't find any clues about the answer > on the internet, so i ask you : why is there no "remove" action for usb > devices with hotplug? The remove event happens just fine. It's just that the current scripts don't do anything with it :) > my current problem is that i looking for a solution to mount/umount > usb-storage devices automagically when they are plugged/unplugged, but > since there is no remove event, i must write a complex script to do it > (currently working on 2.6.4-ck1 and udev). But there is an event. You can catch it on your own if you want. Just put your script in /etc/hotplug.d/usb/ Or if you want to catch the fact when udev removes a /dev node (which odds are is what you really want to catch), put your script, or a link to it in /etc/dev.d/block/ with the extension .dev and you will get both add and remove events that corrisponded to a udev create or remove device node. Hope this helps, greg k-h ------------------------------------------------------- This SF.Net email is sponsored by: IBM Linux Tutorials Free Linux tutorial presented by Daniel Robbins, President and CEO of GenToo technologies. Learn everything from fundamentals to system administration.http://ads.osdn.com/?ad_id70&alloc_id638&op=click _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel