From owner-freebsd-hackers@FreeBSD.ORG Sun May 16 01:28:34 2004 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6490B16A4CF for ; Sun, 16 May 2004 01:28:34 -0700 (PDT) Received: from salmon.maths.tcd.ie (salmon.maths.tcd.ie [134.226.81.11]) by mx1.FreeBSD.org (Postfix) with SMTP id 599F043D41 for ; Sun, 16 May 2004 01:28:33 -0700 (PDT) (envelope-from dwmalone@maths.tcd.ie) Received: from walton.maths.tcd.ie by salmon.maths.tcd.ie with SMTP id ; 16 May 2004 09:28:29 +0100 (BST) Date: Sun, 16 May 2004 09:28:23 +0100 From: David Malone To: "Marc G. Fournier" Message-ID: <20040516082823.GA21655@walton.maths.tcd.ie> References: <20040516022353.V37455@ganymede.hub.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20040516022353.V37455@ganymede.hub.org> User-Agent: Mutt/1.5.3i Sender: dwmalone@maths.tcd.ie cc: freebsd-hackers@freebsd.org Subject: Re: How do inodes work? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 May 2004 08:28:34 -0000 On Sun, May 16, 2004 at 02:25:37AM -0300, Marc G. Fournier wrote: > so I take there are 'gaps' in the inode list? it doesn't re-use freed > ones but keeps climbing until maybe it rolls around or something? A particular numbered inode always lives in the same place on the disk. When choosing what inode to use for a new file, the filesystem tries to pick a inode to put the file close to the directory it is being created in. This is the dirpref optimisation introduced a few years ago - previously inodes were chosen from a part of a disk that had the most nearby free space. David.