* NFS cache
@ 2010-05-16 8:26 hce
[not found] ` <AANLkTikZfdnCMm0TkEaVnN2kqVzMZ7CYmbe1YengmRMY-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
0 siblings, 1 reply; 4+ messages in thread
From: hce @ 2010-05-16 8:26 UTC (permalink / raw)
To: linux-nfs
Hi,
I posted following message on list, but did not see it on list, sorry
if it is duplicated.
I have an application to use NFS over FUSE, if I keep typing "ls" in
the same directory, the client NFS only sent GETATT, no more READDIR,
all directory contents displayed on screen came from NFS cache. That
caused many problems and I'd like to disable NFS client cache. But it
did not work when I add "-o noac" option to mount. Also I don't want
NFS GETATT retransmission during file copy. Appreciate your advice and
sample examples for how to mount nfs to disable client cache and
retransmission.
Thank you.
hce
^ permalink raw reply [flat|nested] 4+ messages in thread[parent not found: <AANLkTikZfdnCMm0TkEaVnN2kqVzMZ7CYmbe1YengmRMY-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>]
* Re: NFS cache [not found] ` <AANLkTikZfdnCMm0TkEaVnN2kqVzMZ7CYmbe1YengmRMY-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org> @ 2010-05-16 23:54 ` hce 2010-05-23 22:11 ` Neil Brown 0 siblings, 1 reply; 4+ messages in thread From: hce @ 2010-05-16 23:54 UTC (permalink / raw) To: linux-nfs On Sun, May 16, 2010 at 6:26 PM, hce <webmail.hce@gmail.com> wrote: > Hi, > > I posted following message on list, but did not see it on list, sorry > if it is duplicated. > > I have an application to use NFS over FUSE, if I keep typing "ls" in > the same directory, the client NFS only sent GETATT, no more READDIR, > all directory contents displayed on screen came from NFS cache. That > caused many problems and I'd like to disable NFS client cache. But it > did not work when I add "-o noac" option to mount. I've just realised that the noac is only for NFS attribute cache, so add "-o noac" only generates more getatt for up paths, the "readdir" was still not called if I keep typing "ls" in the same directory. Does NFS has another cache for directory structure as well? It seems it displayed directory contents on the screen from cache as it did not call readdir to FUSe. > Also I don't want > NFS GETATT retransmission during file copy. Appreciate your advice and > sample examples for how to mount nfs to disable client cache and > retransmission. ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: NFS cache 2010-05-16 23:54 ` hce @ 2010-05-23 22:11 ` Neil Brown 2010-05-26 12:03 ` hce 0 siblings, 1 reply; 4+ messages in thread From: Neil Brown @ 2010-05-23 22:11 UTC (permalink / raw) To: hce; +Cc: linux-nfs On Mon, 17 May 2010 09:54:12 +1000 hce <webmail.hce@gmail.com> wrote: > On Sun, May 16, 2010 at 6:26 PM, hce <webmail.hce@gmail.com> wrote: > > Hi, > > > > I posted following message on list, but did not see it on list, sorry > > if it is duplicated. > > > > I have an application to use NFS over FUSE, if I keep typing "ls" in > > the same directory, the client NFS only sent GETATT, no more READDIR, > > all directory contents displayed on screen came from NFS cache. That > > caused many problems and I'd like to disable NFS client cache. But it > > did not work when I add "-o noac" option to mount. > > I've just realised that the noac is only for NFS attribute cache, so > add "-o noac" only generates more getatt for up paths, the "readdir" > was still not called if I keep typing "ls" in the same directory. > > Does NFS has another cache for directory structure as well? It seems > it displayed directory contents on the screen from cache as it did not > call readdir to FUSe. (almost) all linux filesystems use the 'page cache' for storing parts or all of files and directories. Linux/NFS uses the page cache to store the contents of a directory. It will normally only refresh the cached directory when the 'mtime' or the 'ctime' of the directory (as reported by GETATTR) changes. If FUSE ensures that the mtime changes whenever the directory content changes you should get the same cache behaviour as with regular nfs filesystems. If FUSE does not update the mtime, then it will not work reliably with NFS. NeilBrown > > > Also I don't want > > NFS GETATT retransmission during file copy. Appreciate your advice and > > sample examples for how to mount nfs to disable client cache and > > retransmission. > -- > To unsubscribe from this list: send the line "unsubscribe linux-nfs" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: NFS cache 2010-05-23 22:11 ` Neil Brown @ 2010-05-26 12:03 ` hce 0 siblings, 0 replies; 4+ messages in thread From: hce @ 2010-05-26 12:03 UTC (permalink / raw) To: Neil Brown; +Cc: linux-nfs On Mon, May 24, 2010 at 8:11 AM, Neil Brown <neilb@suse.de> wrote: > On Mon, 17 May 2010 09:54:12 +1000 > hce <webmail.hce@gmail.com> wrote: > >> On Sun, May 16, 2010 at 6:26 PM, hce <webmail.hce@gmail.com> wrote: >> > Hi, >> > >> > I posted following message on list, but did not see it on list, sorry >> > if it is duplicated. >> > >> > I have an application to use NFS over FUSE, if I keep typing "ls" in >> > the same directory, the client NFS only sent GETATT, no more READDIR, >> > all directory contents displayed on screen came from NFS cache. That >> > caused many problems and I'd like to disable NFS client cache. But it >> > did not work when I add "-o noac" option to mount. >> >> I've just realised that the noac is only for NFS attribute cache, so >> add "-o noac" only generates more getatt for up paths, the "readdir" >> was still not called if I keep typing "ls" in the same directory. >> >> Does NFS has another cache for directory structure as well? It seems >> it displayed directory contents on the screen from cache as it did not >> call readdir to FUSe. > > (almost) all linux filesystems use the 'page cache' for storing parts or all > of files and directories. > Linux/NFS uses the page cache to store the contents of a directory. It will > normally only refresh the cached directory when the 'mtime' or the 'ctime' of > the directory (as reported by GETATTR) changes. I guess you were talking about NFS client uses the page cache to store contents of a directory. Is any way I can disable NFS to use page cache to store contents of a directory? I have an application which has its own cache, There are various problems as the NFS / FUSE does not work well together expecially it took excessive large time when to list large number files (100 K). Thanks NeilBrown. ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2010-05-26 12:03 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-05-16 8:26 NFS cache hce
[not found] ` <AANLkTikZfdnCMm0TkEaVnN2kqVzMZ7CYmbe1YengmRMY-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-05-16 23:54 ` hce
2010-05-23 22:11 ` Neil Brown
2010-05-26 12:03 ` hce
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).