Subject: Re: large inode numbers
To: None <tech-kern@NetBSD.org>
From: Alan Barrett <email@example.com>
Date: 12/17/2003 20:34:26
On Wed, 17 Dec 2003, Bill Studenmund wrote:
> On Tue, Dec 16, 2003 at 10:01:34PM -0500, der Mouse wrote:
> > Now _that_ could confuse code: fstat()ting the same fd gives different
> > inumbers at different times! Above, I'd suggested that perhaps unionfs
> > should shift all inumbers over one bit, with a 0 low bit being one
> > layer and a 1 low bit being the other - but that doesn't address this
> > problem; I don't really see any choice except a mapping table.
> Remember we started this thread talking about going to 64-bit inode
> numbers. Let's just use the most significant bit as you describe above.
You can't assume that there will not be more than two layers. I have
personally found reasons to stack at least 4 layers of unionfs on top of
a layer of ffs (with each layer having different reasons why it would
sometimes get nuked or updated). You could possibly assume that the
number of layers will be representable in 8 bits or so.
--apb (Alan Barrett)