From owner-freebsd-stable@FreeBSD.ORG Thu Jul 19 07:17:52 2007 Return-Path: X-Original-To: freebsd-stable@FreeBSD.ORG Delivered-To: freebsd-stable@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id D961216A400 for ; Thu, 19 Jul 2007 07:17:52 +0000 (UTC) (envelope-from LoN_Kamikaze@gmx.de) Received: from mail.gmx.net (mail.gmx.net [213.165.64.20]) by mx1.freebsd.org (Postfix) with SMTP id 2FCA013C4BA for ; Thu, 19 Jul 2007 07:17:51 +0000 (UTC) (envelope-from LoN_Kamikaze@gmx.de) Received: (qmail invoked by alias); 19 Jul 2007 07:17:50 -0000 Received: from nat-wh-1.rz.uni-karlsruhe.de (EHLO mobileKamikaze.norad) [129.13.72.169] by mail.gmx.net (mp054) with SMTP; 19 Jul 2007 09:17:50 +0200 X-Authenticated: #5465401 X-Provags-ID: V01U2FsdGVkX1/2H3ddFZX2Q2D6lh0vyiXyeX80006g/BvraVFkaE b+MahwE9hBFtL0 Message-ID: <469F101C.5060906@gmx.de> Date: Thu, 19 Jul 2007 09:17:48 +0200 From: "[LoN]Kamikaze" User-Agent: Thunderbird 2.0.0.4 (X11/20070616) MIME-Version: 1.0 To: Norberto Meijome References: <200707181703.07480.idiotbg@gmail.com> <200707181541.l6IFf4ht051775@lurza.secnetix.de> <20070719130252.6880b967@localhost> In-Reply-To: <20070719130252.6880b967@localhost> X-Enigmail-Version: 0.95.1 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 Cc: josh@tcbug.org, olli@lurza.secnetix.de, freebsd-stable@FreeBSD.ORG, idiotbg@gmail.com Subject: Re: removing external usb hdd without unmounting causes reboot? X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Jul 2007 07:17:52 -0000 Norberto Meijome wrote: > On Wed, 18 Jul 2007 17:41:04 +0200 (CEST) > Oliver Fromme wrote: >> another work-around >> is to use the auto mounter daemon (amd(8)). It umounts >> file systems automatically that are not in use. >> Another nice feature of amd(8) is that you don't have >> to mount the file system either -- Simply plug the USB >> stick in, then access it, and amd(8) will automatically >> mount it for you. > > > Now, something I dont understand - amd runs > at user level, and it mounts filesystems, and nothing dies when the filesystems > go away (other than the obvious cases for the applications trying to write to > the FS in question). Doesn't amd , at some point , have to tell the kernel > 'please mount this filesystem' here or there? Isn't the kernel STILL involved > in all this? and why doesnt the kernel panic when the FS goes away? > The trick is that amd unmounts the device after a couple of seconds, so when someone accidentally removes a usb drive, it doesn't really matter. Amd will simply fail to mount it on the next access. If you remove the device during or shortly after accessing it, it still will panic the system.