linux-hotplug.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* udev PROGRAM  action
@ 2005-08-24  7:47 Miles Roper
  2005-08-24  9:05 ` Kay Sievers
  2005-08-24  9:27 ` Thierry Vignaud
  0 siblings, 2 replies; 3+ messages in thread
From: Miles Roper @ 2005-08-24  7:47 UTC (permalink / raw)
  To: linux-hotplug

Hi,

I've been trolling around the net trying to find an answer to why I can't get udev to correctly run 
a remove event in a script.

here is my udev line

BUS="usb", KERNEL="sd*", NAME="%k", PROGRAM="/etc/udev/scripts/usb.sh %k"

this works fine.  it calls the script below...

#! /bin/sh
#
# Mount Hotplug Device
#

. /etc/thinstation.env
. $TS_GLOBAL

get_filesystems

if [ ! -e /mnt/usbdevice ]; then
   mkdir /mnt/usbdevice
fi

  case $ACTION in
   add)
         mkdir /mnt/usbdevice/$1
        mount -t supermount -o fs=$filesystem,dev=/dev/$1 /mnt/usbdevice/$1 /mnt/usbdevice/$1
   ;;
   remove)
         umount /mnt/usbdevice/$1
         rmdir /mnt/usbdevice/$1
   ;;
   esac

exit 0

the add event works great.  however, the remove event never gets actioned.  In fact the script never 
gets run when the device is removed.  any ideas why?

Thanks

Miles


-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
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

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2005-08-24  9:27 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-08-24  7:47 udev PROGRAM action Miles Roper
2005-08-24  9:05 ` Kay Sievers
2005-08-24  9:27 ` Thierry Vignaud

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).