[Dovecot] NFS cache flush tester

Andrew Ziem andrewz at springsrescuemission.org
Thu Jul 12 07:12:26 EEST 2007


Timo Sirainen wrote:
> http://dovecot.org/tools/nfstest.c
>
> I wrote a test utility that tests different ways to flush NFS attribute
> cache and data cache. Please test in your NFS setup and show me the
> results, so I can make Dovecot v1.1 works well with NFS.
>
> Run the test several times (3 should be enough) to make sure the output
> stays the same, because the attribute cache flushes might incorrectly
> say "OK". And of course attribute cache must not be disabled for this
> test to work.
>
> If you have other ideas how to flush either cache please tell me and
> I'll update the test utility. I'd like to have a way to flush the cache
> without having the NFS client send anything to server. Unfortunately all
> of the below ways do that.
>
> Results for Linux v2.6.15 and v2.6.18:
>   
** Test 1
Machine 1: Fedora Core 6, Linux 2.6.20-1.2952.fc6 #1 SMP Wed May 16 
17:59:13 EDT 2007 i686 athlon i386 GNU/Linux
Machine 2: Fedora Core 7, Linux 2.6.21-1.3228.fc7 #1 SMP Tue Jun 12 
15:37:31 EDT 2007 i686 i686 i386 GNU/Linux
NFS Server: Trustix Secure Linux 2.2, Linux 2.4.34-1tr #1 Thu Jan 4 
11:36:05 GMT 2007 i686 i686 i386 GNU/Linux

Because the server is Linux 2.4, that implies the protocol is NFS 
version 3. 

Info: Connected: client
Info: O_EXCL works
Info: Testing attribute cache..
Info: Attr cache flush fchown(-1, -1): failed
Info: Attr cache flush fchown(uid, -1): OK
Info: Attr cache flush fchmod(mode): OK
Info: Attr cache flush chown(-1, -1): failed
Info: Attr cache flush chown(uid, -1): OK
Info: Attr cache flush chmod(mode): OK
Info: Testing write flushing..
Info: Write flush no caching: failed
Info: Write flush fcntl(shared): OK
Info: Write flush fcntl(exclusive): OK
Info: Write flush flock(shared): OK
Info: Write flush flock(exclusive): OK
Info: Write flush reopen: OK
Info: Testing data cache..
Info: data cache: Reading EOF requires attribute cache flush
Info: Data cache flush no caching: failed
Info: Data cache flush attr cache: failed
Info: Data cache flush fcntl(shared): OK
Info: Data cache flush fcntl(exclusive): OK
Info: Data cache flush flock(shared): OK
Info: Data cache flush flock(exclusive): OK
Info: Data cache flush dotlock: failed
Info: Data cache flush O_DIRECT: OK


** Test 2
Machines 1 and 2 switched roles.

Info: Connected: client
Info: O_EXCL works
Info: Testing attribute cache..
Info: Attr cache flush fchown(-1, -1): failed
Info: Attr cache flush fchown(uid, -1): OK
Info: Attr cache flush fchmod(mode): OK
Info: Attr cache flush chown(-1, -1): failed
Info: Attr cache flush chown(uid, -1): OK
Info: Attr cache flush chmod(mode): OK
Info: Testing write flushing..
Info: Write flush no caching: failed
Info: Write flush fcntl(shared): OK
Info: Write flush fcntl(exclusive): OK
Info: Write flush flock(shared): OK
Info: Write flush flock(exclusive): OK
Info: Write flush reopen: OK
Info: Testing data cache..
Info: data cache: Reading EOF requires attribute cache flush
Info: Data cache flush no caching: failed
Info: Data cache flush attr cache: failed
Info: Data cache flush fcntl(shared): OK
Info: Data cache flush fcntl(exclusive): OK
Info: Data cache flush flock(shared): OK
Info: Data cache flush flock(exclusive): OK
Info: Data cache flush dotlock: failed
Info: Data cache flush O_DIRECT: OK




Andrew


More information about the dovecot mailing list