From owner-freebsd-hackers Thu May 27 7:32:47 1999 Delivered-To: freebsd-hackers@freebsd.org Received: from gatekeeper.tsc.tdk.com (gatekeeper.tsc.tdk.com [207.113.159.21]) by hub.freebsd.org (Postfix) with ESMTP id 67B21150DE for ; Thu, 27 May 1999 07:32:42 -0700 (PDT) (envelope-from gdonl@tsc.tdk.com) Received: from sunrise.gv.tsc.tdk.com (root@sunrise.gv.tsc.tdk.com [192.168.241.191]) by gatekeeper.tsc.tdk.com (8.8.8/8.8.8) with ESMTP id HAA12118; Thu, 27 May 1999 07:32:40 -0700 (PDT) (envelope-from gdonl@tsc.tdk.com) Received: from salsa.gv.tsc.tdk.com (salsa.gv.tsc.tdk.com [192.168.241.194]) by sunrise.gv.tsc.tdk.com (8.8.5/8.8.5) with ESMTP id HAA28455; Thu, 27 May 1999 07:32:38 -0700 (PDT) Received: (from gdonl@localhost) by salsa.gv.tsc.tdk.com (8.8.5/8.8.5) id HAA10749; Thu, 27 May 1999 07:32:37 -0700 (PDT) From: Don Lewis Message-Id: <199905271432.HAA10749@salsa.gv.tsc.tdk.com> Date: Thu, 27 May 1999 07:32:37 -0700 In-Reply-To: Graeme Tait "File system gets too fragmented ???" (May 26, 6:59pm) X-Mailer: Mail User's Shell (7.2.6 alpha(3) 7/19/95) To: Graeme Tait , freebsd-hackers@FreeBSD.ORG Subject: Re: File system gets too fragmented ??? Cc: info@boatbooks.com Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On May 26, 6:59pm, Graeme Tait wrote: } Subject: File system gets too fragmented ??? } The filesystem is built with 4096 byte blocks, 512 byte fragments, and } 2048 bytes/inode, and is mounted 'async noatime'. } } It contains about 900,000 files, most of which are small, occupying } around 2-5 fragments. The small files are updated monthly from a tar } archive generated offline. In the course of updates, some files may grow } or shrink by a fragment or so, and some new files are created, and } periodically old files are deleted. If a file shrinks by one fragment, it'll most likely leave a one fragment gap in the block that can't be reused by another (new) file, since the the minimum file size is two fragments. You could easily get a 12.5% wasteage just from that. It might help somewhat if a file that grows by a fragment can allocate the free fragment immediately preceeding it instead of being relocated to a fresh block. I don't know if FFS does this or not. Forcing space optimization full time might help, but this is a pretty nasty allocation pattern ... To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message