From owner-freebsd-questions@FreeBSD.ORG Thu Jan 20 20:31:05 2005 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C149816A4CF for ; Thu, 20 Jan 2005 20:31:05 +0000 (GMT) Received: from ms-smtp-01-eri0.socal.rr.com (ms-smtp-01-qfe0.socal.rr.com [66.75.162.133]) by mx1.FreeBSD.org (Postfix) with ESMTP id C99F043D2D for ; Thu, 20 Jan 2005 20:31:02 +0000 (GMT) (envelope-from hoe-waa@hawaii.rr.com) Received: from localhost.localdomain (cpe-66-8-190-99.hawaii.rr.com [66.8.190.99])j0KKUvkM013486; Thu, 20 Jan 2005 12:30:58 -0800 (PST) From: Robert Marella To: Alexander Anderson In-Reply-To: <0IAL009L5GTUU8@ms-mss-01.socal.rr.com> References: <0IAL009L5GTUU8@ms-mss-01.socal.rr.com> Content-Type: text/plain Date: Thu, 20 Jan 2005 10:25:37 -1000 Message-Id: <1106252737.754.3.camel@localhost> Mime-Version: 1.0 X-Mailer: Evolution 2.0.3 FreeBSD GNOME Team Port Content-Transfer-Encoding: 7bit X-Virus-Scanned: Symantec AntiVirus Scan Engine cc: freebsd-questions@freebsd.org Subject: Re: usbd: Executing umount: Device not configured X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Jan 2005 20:31:05 -0000 On Wed, 2005-01-19 at 21:41 -0500, Alexander Anderson wrote: > Greetings all, > > I have a Sony DSC-P32 digital camera with a USB interface. I can't get > usbd to unmount the camera when it's disconnected, powered off, or > detached. > > I have to remember to execute umount(8) manually before the camera is > physically disconnected, or else it stays mounted to a stale device forever > (which makes it impossible to use the camera again until a reboot), and an > attempt to forcibly unmount the stale device causes the kernel to panic. > > The relevant entry in /etc/usbd.conf: > > device "Sony DSC" > vendor 0x054c > product 0x0010 > attach "sleep 1 ; /sbin/mount_msdosfs /dev/da0s1 /mnt/camera" > detach "/sbin/umount /dev/da0s1" > > It mounts without problems. But when I disconnect the camera, here's what > I see (the output was obtained from usbd -dvv): > > umass0: at uhub1 port 1 (addr 2) disconnected > (da0:umass-sim0:0:0:0): lost device > umass0: detached > usbd: processing event queue on /dev/usb > usbd: device-detach event at 1106184871.250725000, DSC cameras, Sony: > vndr=0x054c prdct=0x0010 rlse=0x0450 clss=0x0000 subclss=0x0000 prtcl=0x0000 > usbd: Found action 'Sony DSC' for DSC cameras, Sony > usbd: action 0: Sony DSC > vndr=0x054c prdct=0x0010 > attach='sleep 1 ; /sbin/mount_msdosfs /dev/da0s1 /mnt/camera' > detach='/sbin/umount /dev/da0s1' > usbd: Executing '/sbin/umount /dev/da0s1' > umount: unmount of /mnt/camera failed: Device not configured > usbd: '/sbin/umount /dev/da0s1' returned 1 > > Not so long ago upgraded from 4.9-RELEASE to 5.3-RELEASE, and this > configuration used to work before, but not now. > > I'm wondering if usbd can execute the detach command before the special > device has disappeared, not after the fact, as it seems to be. > > And I'm also wondering, why does "/sbin/umount -f /dev/da0s1" when > /dev/da0s1 does not exist cause a kernel panic? Though, I wouldn't care > about it if all worked without this hitch. Ummm, your mount point is /mnt/camera. The command should be umount /mnt/camera