[lkml]   [1999]   [Jun]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [RFC] symlink caching and network filesystems
In message <>, Alexander Viro writes:
> On Mon, 7 Jun 1999, David S. Miller wrote:
> > Date: Mon, 7 Jun 1999 02:33:35 -0400 (EDT)
> > From: Alexander Viro <>
> >
> > On Mon, 7 Jun 1999, Erez Zadok wrote:
> >
> > > I'm not sure this is relevant, but please ensure that there's a
> > > way for mount() to turn off such symlink caching. It's useful
> > > for my user-level hlfsd to turn off symlink caching, esp. over
> > > nfs. (Hlfsd creates a symlink that points to different places
> > > depending on the euid accessing the symlink; it's used to
> > > redirect /var/mail to users' home dirs.)
> >
> > Wait a minute. Are you talking about the userland server + normal
> > NFS client combination? <scratching head> Hrrrmm... But READLINK in
> > NFSv2 (and IIRC in v3 too) doesn't pass credentials, right? Could
> > you elaborate on that?
> >
> > This is a non-issue. Alexander, if I understand your proposal
> > correctly, the hlfsd issue is solved by using an attribute timeout of
> > zero. NFS must revalidate the inode on every access, so the symlink
> > cache validity is a by-product of inode revalidation. See?
> Yes, that will work, but I'm still curious what did Erez do ;-) Anyway, I
> think that I did the Rigth Thing(tm) with name handling and it solved the
> problem in a different way. Basically it's a new structure, holding a

My apologies for the brief message. I'm soon leaving town for a week.

Hlfsd is part of am-utils (aka Amd). It makes the value of the symlink
different based on the euid that it gets off of RPC info (via AUTH_UNIX).
You can check the sources to it if you're interested. Get the latest
am-utils in You can find my
LISA-7 paper on hlfsd in

Dave is right that Linux does it right. As long as there's a way to ensure
that access to nfs-based symlinks can pass to the server on each user
access, I'm fine. Most OSs don't have NFS symlink caches, and thus a simple
turning off of the attr cache works ok; that usually happens with a mount
flag (noac) or by explicitly setting the ac{dir,reg}{min,max} to 0. But
I've seen OSs, where 0 doesn't work, and you have to set it to a small
positive number. I've seen OSs (Solaris and Irix) where there's an explicit
nfs symlink cache, and normal attr cache mechanisms do not turn that off.
Luckily Solaris and Irix have a special mount flag to turn off nfs symlink

Also someone reported to me that at some point freebsd added symlink caches
but that their attribute turning off code got broken. I've not verified
that with recent freebsd versions.


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
Please read the FAQ at

 \ /
  Last update: 2005-03-22 13:52    [W:0.118 / U:8.028 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site