Excerpts from ext.misc.info-afs: 12-Jul-94 stat() system call and AFS?
Tim [EMAIL PROTECTED] (606)
> I have a question from a coworker that is looking into more efficent
> access to afs files. We have found out about the even/odd inode
> rule. However, we were wondering about the following:
Strangely enough, I was just working on similar code this morning within
the Andrew Toolkit. The code does an ioctl(fd, VIOCIGETCELL, &dummy),
where dummy is declared as struct ViceIoctl (initialized correctly). If
this succeeds on the directory, we are in AFS.
The even/odd inode hack still seems to work, but it does not work for
AFS mount points, probably because they are symlinks. And of course it
doesn't work for symlinks to valid directories. Does anyone have a
terribly nice hack for detecting a mount point as well? Is a
VIOC_AFS_STAT_MT_PT pioctl on all files (obviously I can skip dirs found
with the odd/even hack) fast, or is there something more clever I can do?
On a related note, what happens in DFS? I'd hate to see this most
excellent hack go away :-(.
-todd inglett