Linux Symposium, July 13th - 17th, 2009, Montreal, Canada
Centre Mont-Royal
Montreal, Canada
July 13-17, 2009

Register / Login

CFP
Paper Guide

Schedule

Keynotes
Summits
Presentations
Tutorials
Project Updates
BOFS

Venue
Travel & Hotel
Costs & Savings

FAQ

Media
Archives
Contact

Home



20 Years Later: Still Improving the Correctness of an NFS Server

Robert Gardner (rob.gardner@hp.com)

The NFS Reply Cache, also known as the Duplicate Request Cache, was first described in its current form over twenty years ago as a way to help a server give correct responses to certain types of replayed operations. Some operations, called idempotent, can be safely repeated and will do no harm. Other operations, called non-idempotent, can only succeed once, and an attempt to repeat one results in failure. For example, a request to read a certain block of a file will produce the same result each time. But an operation such as rename can only succeed once. A subsequent retry of the same request will result in an error being reported to the client, even though the original operation did succeed. The Reply Cache keeps track of responses to recently performed non-idempotent transactions, and in case of a replay, the cached response is sent instead of attempting to perform the operation again. In addition to avoiding these client-visible errors, performance is also improved by avoiding unnecessary work.

The trouble begins when the size of the cache is not adequate to deal with the rate of incoming transactions. Now the mechanism breaks down, and replayed requests may result in duplicate work being done and erroneous results generated. Even modest workloads can result in enormous incoming transaction rates which would necessitate enlarging the reply cache to unacceptable levels. Heavy workloads can cause network congestion and delays that can foil attempts to cache enough transactions to maintain correctness.

We address these problems by making the cache smarter instead of larger. First, we add the concept of protecting a cache entry, which temporarily makes it exempt from the usual replacement process. Next, we add some heuristics that grant or revoke the protection of a cache entry. Finally, we eliminate automatic expiration of cache entries. Taken all together, this scheme drastically reduces the number of errors reported by clients on a large network.



Major Sponsors
Minor Sponsors
Wireless Networking

register | call for papers

Copyright © 2009 Linux Symposium Inc. All rights reserved.
Linux is a registered trademark of Linus Torvalds.