From owner-freebsd-current@FreeBSD.ORG Wed Jun 1 15:42:20 2005 Return-Path: X-Original-To: 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 225EC16A41C; Wed, 1 Jun 2005 15:42:20 +0000 (GMT) (envelope-from andy@siliconlandmark.com) Received: from lexi.siliconlandmark.com (lexi.siliconlandmark.com [209.69.98.4]) by mx1.FreeBSD.org (Postfix) with ESMTP id C0BF943D49; Wed, 1 Jun 2005 15:42:19 +0000 (GMT) (envelope-from andy@siliconlandmark.com) Received: from lexi.siliconlandmark.com (localhost [127.0.0.1]) by lexi.siliconlandmark.com (8.13.3/8.13.3) with ESMTP id j51FgCoj038512; Wed, 1 Jun 2005 11:42:12 -0400 (EDT) (envelope-from andy@siliconlandmark.com) Received: from localhost (andy@localhost) by lexi.siliconlandmark.com (8.13.3/8.13.3/Submit) with ESMTP id j51Fg7fb038509; Wed, 1 Jun 2005 11:42:12 -0400 (EDT) (envelope-from andy@siliconlandmark.com) X-Authentication-Warning: lexi.siliconlandmark.com: andy owned process doing -bs Date: Wed, 1 Jun 2005 11:42:07 -0400 (EDT) From: Andre Guibert de Bruet To: Alexander Leidinger In-Reply-To: <20050601152244.cgb5pjihw4w4ssgg@netchild.homeip.net> Message-ID: <20050601113320.G69811@lexi.siliconlandmark.com> References: <41216.1117630645@critter.freebsd.dk> <20050601152244.cgb5pjihw4w4ssgg@netchild.homeip.net> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Information: Please contact the ISP for more information X-SL-MailScanner: Found to be clean X-SL-SpamCheck: not spam, SpamAssassin (score=-2.541, required 6, autolearn=not spam, AWL 0.06, BAYES_00 -2.60) X-MailScanner-From: andy@siliconlandmark.com Cc: Poul-Henning Kamp , Don Lewis , current@freebsd.org Subject: Re: [RFC] [PATCH] VM & VFS changes 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: Wed, 01 Jun 2005 15:42:20 -0000 On Wed, 1 Jun 2005, Alexander Leidinger wrote: > Poul-Henning Kamp wrote: > >> Maybe the simplest solution is also the best: keep track of the >> dependencies and do the cleanup leaf->root on the resulting tree. > > How many userland processes have to be running and consuming memory which > isn't available as physical RAM at this point in the shutdown sequence? > > Wouldn't a loop like the following be enough? > while swap > umount unbusy-FS > swap-off swap > > This assumes that swap-off doesn't turns off the swap if it isn't able to put > everything back into other swap or physical RAM areas. I would think that one would want to disable swapping before the unmount of filesystems for the very fact you could have vnode-backed swapspace in use. Once the system is swapless at this point in shutdown, there should no longer be any active vnodes on mounted filesystems (From my testing, the only exception at this point in time is devfs. I am working on another patch to address this). Andy /* Andre Guibert de Bruet * 6f43 6564 7020 656f 2e74 4220 7469 6a20 */ /* Code poet / Sysadmin * 636f 656b 2e79 5320 7379 6461 696d 2e6e */ /* GSM: +1 734 846 8758 * 5520 494e 2058 6c73 7565 6874 002e 0000 */ /* WWW: siliconlandmark.com * Tormenting bytes since 1980. */