Messages in this thread |  | | Date | Fri, 25 Aug 2000 00:12:26 +0200 | From | "Andi Kleen" <> | Subject | Re: NWFS rename() problem |
| |
On Thu, Aug 24, 2000 at 03:59:27PM -0600, Jeff V. Merkey wrote: > > > Andi Kleen wrote: > > > > On Thu, Aug 24, 2000 at 01:49:20PM -0600, Jeff V. Merkey wrote: > > > It sounds like inode numbers are arbitrary, and so long as I have cached > > > a hash structure in the inode (which I do), I can just make up inode > > > numbers for files (provided they are unique), and use the > > > inode->generic_ip pointer to access the actual directory number. > > > > > > Is this correct? > > > > Just note that you'll break the NFS server when you don't have stable > > inode numbers in your file system (at least in 2.2, 2.4 or 2.5 may get an > > better "file key" interface so that you could manage nfs file handles > > yourself)
I forgot to mention: you always need a unique inode number because the NFS clients require it. This inode number needs to be valid over server reboots.
> > Also there are applications that make assumption about the inode numbers -- > > like the popular maildir format. They should be better unique over the > > file system, not just over the referenced inodes. > > So if I make them unique across all volumes for the fs driver (i.e. a > counter in the driver that generates unique numbers across all volumes) > this should work? Yes?
A simple counter will not work, unless you store the counter result into the "inode" and search the volumes to avoid collisions (would be kinda like a pid)
-Andi - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org Please read the FAQ at http://www.tux.org/lkml/
|  |