From owner-freebsd-questions@FreeBSD.ORG Sun Oct 19 16:52:27 2008 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C1532106568C for ; Sun, 19 Oct 2008 16:52:27 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mx02.qsc.de (mx02.qsc.de [213.148.130.14]) by mx1.freebsd.org (Postfix) with ESMTP id 820CD8FC0C for ; Sun, 19 Oct 2008 16:52:27 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from r55.edvax.de (port-92-195-41-11.dynamic.qsc.de [92.195.41.11]) by mx02.qsc.de (Postfix) with ESMTP id 7306216C008A; Sun, 19 Oct 2008 18:52:25 +0200 (CEST) Received: from r55.edvax.de (localhost [127.0.0.1]) by r55.edvax.de (8.14.2/8.14.2) with SMTP id m9JGqOG3001610; Sun, 19 Oct 2008 18:52:24 +0200 (CEST) (envelope-from freebsd@edvax.de) Date: Sun, 19 Oct 2008 18:52:24 +0200 From: Polytropon To: perryh@pluto.rain.com Message-Id: <20081019185224.d0ce3bd3.freebsd@edvax.de> In-Reply-To: <48fac99c.v09a2DdmpE7xdWZS%perryh@pluto.rain.com> References: <20081019044058.9ff31b6f.freebsd@edvax.de> <48fac99c.v09a2DdmpE7xdWZS%perryh@pluto.rain.com> Organization: EDVAX X-Mailer: Sylpheed 2.4.7 (GTK+ 2.12.1; i386-portbld-freebsd7.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: freebsd-questions@freebsd.org Subject: Re: Inode numbering X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Polytropon List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 19 Oct 2008 16:52:27 -0000 On Sat, 18 Oct 2008 22:46:04 -0700, perryh@pluto.rain.com wrote: > It might work in the special case where nothing > on the filesystem is ever moved or removed, and no hard links are > ever added. > > As a simple example, suppose I have directories foo and foo/bar, > and file foo/baz, with i(foo) == 15, i(foo/baz) == 20, and > i(foo/bar) == 25, satisfying your criterion. If I do > > mv foo/baz foo/bar > > (so baz is now foo/bar/baz), I will have i(foo/bar) == 25 and > i(foo/bar/baz) == 20. Thank you for this example. So I cannot assume inode numbers to be in a specific order. It will force me to do what I originally intended to do: Iterate from 2 up to the maximal number and then check the availability, and, if given, "trace back" the ".. chain" to an existing directory entry point - or re-create one, if it is missing, too. Will be a lot of work, but I think I can learn much from this. Remember, kids: Learning is fun. :-) -- Polytropon >From Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ...