From owner-freebsd-current@FreeBSD.ORG Thu Jun 30 11:07:29 2005 Return-Path: X-Original-To: freebsd-current@freebsd.org Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6940816A41C for ; Thu, 30 Jun 2005 11:07:29 +0000 (GMT) (envelope-from philip@paeps.cx) Received: from gateway.nixsys.be (gateway.nixsys.be [195.144.77.33]) by mx1.FreeBSD.org (Postfix) with ESMTP id E59E643D48 for ; Thu, 30 Jun 2005 11:07:28 +0000 (GMT) (envelope-from philip@paeps.cx) Received: from loge.nixsys.be (loge.nixsys.be [IPv6:2001:838:37f:0:20c:6eff:fe4b:23f]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "loge.home.paeps.cx", Issuer "NixSys CA" (verified OK)) by gateway.nixsys.be (Postfix) with ESMTP id D4BFEC0E0 for ; Thu, 30 Jun 2005 13:07:26 +0200 (CEST) Received: from loge.nixsys.be (philip@localhost [127.0.0.1]) by loge.nixsys.be (8.13.4/8.13.4) with ESMTP id j5UB7Qdn093401 for ; Thu, 30 Jun 2005 13:07:26 +0200 (CEST) (envelope-from philip@loge.nixsys.be) Received: (from philip@localhost) by loge.nixsys.be (8.13.4/8.13.4/Submit) id j5UB7Qan093400 for freebsd-current@freebsd.org; Thu, 30 Jun 2005 13:07:26 +0200 (CEST) (envelope-from philip) Date: Thu, 30 Jun 2005 13:07:26 +0200 From: Philip Paeps To: freebsd-current@freebsd.org Message-ID: <20050630110726.GC66269@loge.nixsys.be> Mail-Followup-To: freebsd-current@freebsd.org References: <20050622065357.GA694@loge.nixsys.be> <20050623083804.GV738@obiwan.tataz.chchile.org> <20050623104843.GA698@loge.nixsys.be> <20050623142117.GE738@obiwan.tataz.chchile.org> <20050625141320.GA605@fasolt.home.paeps.cx> <20050627134519.GR1283@obiwan.tataz.chchile.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20050627134519.GR1283@obiwan.tataz.chchile.org> X-Date-in-Rome: pridie Kalendas Iulias MMDCCLVIII ab Urbe Condida X-PGP-Fingerprint: FA74 3C27 91A6 79D5 F6D3 FC53 BF4B D0E6 049D B879 X-Message-Flag: Get a proper mailclient! Organization: Happily Disorganized User-Agent: Mutt/1.5.9i Subject: Re: Unable to umount union-parts after umounting unionfs X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 30 Jun 2005 11:07:29 -0000 On 2005-06-27 15:45:19 (+0200), Jeremie Le Hen wrote: > On Sat, Jun 25, 2005 at 04:13:20PM +0200, Philip Paeps wrote: > > Note that the problem is not in unmounting the union filesystem, that > > works fine, it's unmounting the top layer. Unmounting the bottom layer is > > not a problem either. > > Ah, I misread. This is the expected behaviour : the top layer is obviously > busy while the unionfs mount is active. Here is the same setup that you > first described : > %%% > /dev/md0 on /root/tests/mnt0 (ufs, local) > /dev/md1 on /root/tests/mnt1 (ufs, local) > :/root/tests/mnt1 on /root/tests/mnt0 (unionfs, local, noclusterw) > %%% > > Imagine what would happen to the unionfs mount if /root/tests/mnt1 was > unmounted. This is nonsense. Indeed. But after the unionfs has been unmounted (umount /root/tests/mnt0 in your example), it should also be possible to unmount the top layer after it's had some time to sync up any changes that happened. Something must be keeping the top layer 'busy' for some reason. It would be nice to be able to find out what. :-) > > %%% > > vflush: busy vnode > > 0xc2578bb0: tag ufs, type VDIR > > usecount 1, writecount 0, refcount 4 mountedhere 0 > > flags (VV_ROOT) > > VI_LOCKed v_object 0xc256c630 ref 0 pages 1 > > lock type ufs: EXCL (count 1) by thread 0xc2547900 (pid 687) > > ino 2, on dev md1 > > %%% > > This is a bug, I can reproduce it here. I am not enough skilled to correct > this filesystem. It has been known to be broken for a long time and I > expect things goes bader with time, as the second thermothynamics principle > states :-). I'm willing to try to fix it, but I'm getting a little lost in all the twisty passages of the filesystem code. :-) > PS: I'm willing to try to foreport FiST [1] to FreeBSD 6, it is known > to have, among others, a very good union filesystem implementation, Ooh! I'll try that out. Thanks! - Philip -- Philip Paeps Please don't Cc me, I am philip@freebsd.org subscribed to the list. BOFH Excuse #325: Your processor does not develop enough heat.