From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 18 00:13:57 2007 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AD9B216A419 for ; Tue, 18 Dec 2007 00:13:57 +0000 (UTC) (envelope-from romain@blogreen.org) Received: from smtp3-g19.free.fr (smtp3-g19.free.fr [212.27.42.29]) by mx1.freebsd.org (Postfix) with ESMTP id 7BEE313C45B for ; Tue, 18 Dec 2007 00:13:57 +0000 (UTC) (envelope-from romain@blogreen.org) Received: from smtp3-g19.free.fr (localhost.localdomain [127.0.0.1]) by smtp3-g19.free.fr (Postfix) with ESMTP id 6C44517B536; Tue, 18 Dec 2007 01:13:56 +0100 (CET) Received: from marvin.blogreen.org (marvin.blogreen.org [82.247.213.140]) by smtp3-g19.free.fr (Postfix) with ESMTP id D015B17B532; Tue, 18 Dec 2007 01:13:55 +0100 (CET) Received: by marvin.blogreen.org (Postfix, from userid 1001) id 6C66D5C053; Tue, 18 Dec 2007 01:13:55 +0100 (CET) Date: Tue, 18 Dec 2007 01:13:55 +0100 From: Romain =?iso-8859-1?Q?Tarti=E8re?= To: Yuri Message-ID: <20071218001355.GA40289@marvin.blogreen.org> Mail-Followup-To: Yuri , freebsd-hackers@freebsd.org References: <1197889622.4766585626a92@webmail.rawbw.com> <1197916368.4766c0d0db6a8@webmail.rawbw.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="Nq2Wo0NMKNjxTN9z" Content-Disposition: inline In-Reply-To: <1197916368.4766c0d0db6a8@webmail.rawbw.com> User-Agent: Mutt/1.4.2.3i Cc: freebsd-hackers@freebsd.org Subject: Re: Stale mount on disconnected device: how to delete it? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Dec 2007 00:13:57 -0000 --Nq2Wo0NMKNjxTN9z Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Dec 17, 2007 at 10:32:48AM -0800, Yuri wrote : > In case of USB device (which device in question in this problem > happens to be) usbd can be used to mount it. >=20 > If attach/detach events trigger mount/unmount commands this problem > shouldn't exist. I didn't try though. The problem is that the detach event can be caught only too late to unmount the device properly. How may it be possible to sync a disk ``as soon as it is detached'' (that is when it is not physically connected to the computer anymore)? Mounting the disk read-only may be a workaround, just as not caching writes (default behaviour of some versions of Windows) and syncing the disk all the time, but this is not as reliable as the mount system provided by Unix and Unix like operating systems. AFAICR, this is the sole weakness of the FreeBSD operating system I know :) And since it is, according to me, an operator error, the best we can do is to use the system as it was designed for ;) Regards, Romain --=20 Romain Tarti=E8re http://romain.blogreen.org/ pgp: 8DAB A124 0DA4 7024 F82A E748 D8E9 A33F FF56 FF43 (ID: 0xFF56FF43) (plain text =3Dnon-HTML=3D PGP/GPG encrypted/signed e-mail much appreciated) --Nq2Wo0NMKNjxTN9z Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.4 (FreeBSD) iD8DBQFHZxDD2OmjP/9W/0MRAlwzAJ0Yj6cpBPrY86/bYVcNbwo7HJhI9gCgmdEK /hW7fX2atEgzK6mcsfDqz6M= =f/wW -----END PGP SIGNATURE----- --Nq2Wo0NMKNjxTN9z--