From owner-freebsd-fs Mon Aug 26 15: 0:50 2002 Delivered-To: freebsd-fs@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5A82637B400 for ; Mon, 26 Aug 2002 15:00:48 -0700 (PDT) Received: from bilver.wjv.com (user38.net339.fl.sprint-hsd.net [65.40.24.38]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8B27143E4A for ; Mon, 26 Aug 2002 15:00:47 -0700 (PDT) (envelope-from bv@bilver.wjv.com) Received: from bilver.wjv.com (localhost [127.0.0.1]) by bilver.wjv.com (8.12.5/8.12.5) with ESMTP id g7QM0kkv027649 for ; Mon, 26 Aug 2002 18:00:46 -0400 (EDT) (envelope-from bv@bilver.wjv.com) Received: (from bv@localhost) by bilver.wjv.com (8.12.5/8.12.5/Submit) id g7QM0k51027648 for freebsd-fs@freebsd.org; Mon, 26 Aug 2002 18:00:46 -0400 (EDT) Date: Mon, 26 Aug 2002 18:00:45 -0400 From: Bill Vermillion To: freebsd-fs@freebsd.org Subject: Re: optimization changed from TIME to SPACE ?! Message-ID: <20020826220045.GB27088@wjv.com> Reply-To: bv@wjv.com References: <31269226357BD211979E00A0C9866DAB02BB998B@rios.sitaranetworks.com> <20020826204811.GA337@HAL9000.homeunix.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20020826204811.GA337@HAL9000.homeunix.com> User-Agent: Mutt/1.3.25i Organization: W.J.Vermillion / Orlando - Winter Park Sender: owner-freebsd-fs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org -segmentation fault- press any key to reboot Damn damn damn David Schultz said, after restarting his PC and mailer on Mon, Aug 26, 2002 at 13:48 . > Thus spake Chris Ptacek : > > What actually causes the fragmentation to occur? Read the docs or take a look at one of the books on the BSD file system to explain it fully. > I'm not an expert on FFS, but hopefully someone will correct me if > I have missed something. .... > One problem with fragments is that dealing with them can be > inefficient. If your 9K file grows to a 12K file, then to a 14K > file, then to a 16K file, the filesystem may have to copy > fragments around in order to fit all of the fragments for the end > of the file into a single block. But at the point the files goes to 16K it has no fragmentation at all and there is a good chance those two 8K allocation units will be contiguous. The FFS systme is good at this. > This is the kind of > fragmentation fsck is telling you about. If you have FFS optimize > for space, it will happily manage all of these fragments for you. > If you tell it to optimize for time, FFS will still use fragments, > but it won't bother to keep reallocating them when a file grows; > instead, it will upgrade the file to a full block. The latter > method is more efficient, but you lose a bit more space due to > internal fragmentation. Thus, if FFS expects to run out of space, > or if there are too many free fragments lying around, it will > revert to space optimization until the situation improves. I've been using FFS style systems since about 1993 - and I really like them. If you do get to the poinn where you see optimization changed from time to space - then it's time to get a bigger drive or get rid of some of the cruft. Bill -- Bill Vermillion - bv @ wjv . com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-fs" in the body of the message