Re: Query related to lookup
Re: Query related to lookup
- Subject: Re: Query related to lookup
- From: Ken Hornstein <email@hidden>
- Date: Wed, 10 Apr 2013 09:44:25 -0400
>By staring and experimenting in last few days: I saw that I could cause
>VFS to send me a lookup call for every stat() syscall, if I call below
>function for a mountpoint: Vfs_setauthcache_ttl(mp, 0);
>
>Above call is supposed to disable auth cache, I am still confused about
>why affects lookup behavior. If you know more details about it, please
>let me know.
You _do_ know all of the kernel source code is available, right?
It looks like ... vfs_setauthcache_ttl() sets the mount flag MNTK_AUTH_OPAQUE,
which sets the flag ttl_enabled to be TRUE in cache_lookup_path(), which
invokes this code in the main loop in that function:
if (ttl_enabled && ((tv.tv_sec - dp->v_cred_timestamp) > dp->v_mount->mnt_authcache_ttl))
break;
I think the idea there is that if the directory credential timestamp has
expired you need to go back through the noncached code path to make sure you
have permission to search the directory; that has the effect of calling
lookup again.
--Ken
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Filesystem-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden