[802] in arla-drinkers
Re: inode clashes (linux 2.2.x, arla 0.2x)
daemon@ATHENA.MIT.EDU (Simon Josefsson)
Sat May 1 14:15:16 1999
From owner-arla-drinkers@stacken.kth.se Sat May 01 18:15:15 1999
Return-Path: <owner-arla-drinkers@stacken.kth.se>
Delivered-To: arla-drinkers-mtg@bloom-picayune.mit.edu
Received: (qmail 19547 invoked from network); 1 May 1999 18:15:14 -0000
Received: from unknown (HELO sundance.stacken.kth.se) (130.237.234.41)
by bloom-picayune.mit.edu with SMTP; 1 May 1999 18:15:14 -0000
Received: (from majordom@localhost)
by sundance.stacken.kth.se (8.8.8/8.8.8) id UAA22975
for arla-drinkers-list; Sat, 1 May 1999 20:09:40 +0200 (MET DST)
Received: from xiphias.pdc.kth.se (xiphias.pdc.kth.se [130.237.221.226])
by sundance.stacken.kth.se (8.8.8/8.8.8) with ESMTP id UAA22971;
Sat, 1 May 1999 20:09:35 +0200 (MET DST)
Received: (from jas@localhost)
by xiphias.pdc.kth.se (8.8.5/8.8.5) id UAA14600;
Sat, 1 May 1999 20:09:34 +0200 (METDST)
To: Magnus Ahltorp <map@stacken.kth.se>
Cc: arla-drinkers@stacken.kth.se
Subject: Re: inode clashes (linux 2.2.x, arla 0.2x)
References: <ilur9p1u8go.fsf@xiphias.pdc.kth.se> <ixdzp3oaeoz.fsf@turbot.pdc.kth.se>
From: Simon Josefsson <jas@pdc.kth.se>
In-Reply-To: Magnus Ahltorp's message of "01 May 1999 19:21:32 +0200"
Date: 01 May 1999 20:09:33 +0200
Message-ID: <ilu7lqs7jc2.fsf@xiphias.pdc.kth.se>
Lines: 46
User-Agent: Gnus/5.070083 (Pterodactyl Gnus v0.83) Emacs/20.3.8
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: 8bit
Sender: owner-arla-drinkers@stacken.kth.se
Precedence: bulk
Magnus Ahltorp <map@stacken.kth.se> writes:
> > I assume this is due to mapping AFS inodes (or whatever the AFS
> > equivalent is called) into UFS inodes failes to produce unique UFS
> > inodes.
>
> This is a problem, and it's an even worse problem on Linux, since
> in-use inode numbers must be unique. I'm using a naïve approach: the
> struct xnode pointer is used as the inode number. This guarantees that
> the functions (machine, time, file)->inum and (machine, time,
> inum)->file indeed are functions. However, it is not guaranteed that
> file->inum is a function, which, as I understand, is a POSIX
> requirement.
I just discovered that using fully qualified file names tend to give
every file in a directory the same inode number:
p01$ ls -lai $PWD|tail -8
3463758816 -rw-r--r-- 1 jas usr 4425 May 1 17:57 rfc2231.elc
3463758816 -rw-r--r-- 1 jas usr 3771 Oct 20 1998 score-mode.el
3463758816 -rw-r--r-- 1 jas usr 3397 May 1 17:57 score-mode.elc
3463758816 -rw-r--r-- 1 jas usr 10084 Mar 4 02:38 smiley.el
3463758816 -rw-r--r-- 1 jas usr 4268 Jan 20 01:52 time-date.el
3463758816 -rw-r--r-- 1 jas usr 3652 May 1 17:57 time-date.elc
3463758816 -rw-r--r-- 1 jas usr 6600 Apr 18 14:44 uudecode.el
3463758816 -rw-r--r-- 1 jas usr 4803 May 1 17:57 uudecode.elc
p01$ ls -lai |tail -8
3237889344 -rw-r--r-- 1 jas usr 4425 May 1 17:57 rfc2231.elc
3464520320 -rw-r--r-- 1 jas usr 3771 Oct 20 1998 score-mode.el
3237889824 -rw-r--r-- 1 jas usr 3397 May 1 17:57 score-mode.elc
3464520960 -rw-r--r-- 1 jas usr 10084 Mar 4 02:38 smiley.el
3464521280 -rw-r--r-- 1 jas usr 4268 Jan 20 01:52 time-date.el
3237889664 -rw-r--r-- 1 jas usr 3652 May 1 17:57 time-date.elc
3464522400 -rw-r--r-- 1 jas usr 6600 Apr 18 14:44 uudecode.el
3237888224 -rw-r--r-- 1 jas usr 4803 May 1 17:57 uudecode.elc
It's not consistent, sometimes it behaves like this and sometimes
not. Roughly 50/50 so it's fairly common. It doesn't make any
difference whether the files stat()ed is in the cache or not.
Does it make sense at all? Could it be something else causing it?
> You are welcome to suggest better ways of doing this.
Is it possible to use the same algorithm as the other major afs client
vendor does? It seem to produce unique inodes even across platforms.