3 .\" Copyright (c) 1993 The Usenix Association. All rights reserved.
5 .\" This document is derived from software contributed to Berkeley by
6 .\" Rick Macklem at The University of Guelph with the permission of
7 .\" the Usenix Association.
9 .\" Redistribution and use in source and binary forms, with or without
10 .\" modification, are permitted provided that the following conditions
12 .\" 1. Redistributions of source code must retain the above copyright
13 .\" notice, this list of conditions and the following disclaimer.
14 .\" 2. Redistributions in binary form must reproduce the above copyright
15 .\" notice, this list of conditions and the following disclaimer in the
16 .\" documentation and/or other materials provided with the distribution.
17 .\" 3. All advertising materials mentioning features or use of this software
18 .\" must display the following acknowledgement:
19 .\" This product includes software developed by the University of
20 .\" California, Berkeley and its contributors.
21 .\" 4. Neither the name of the University nor the names of its contributors
22 .\" may be used to endorse or promote products derived from this software
23 .\" without specific prior written permission.
25 .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
26 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
27 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
28 .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
29 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
30 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
31 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
32 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
33 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
34 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
37 .\" @(#)nqnfs.me 8.1 (Berkeley) 4/20/94
42 Reprinted with permission from the "Proceedings of the Winter 1994 Usenix
43 Conference", January 1994, San Francisco, CA, Copyright The Usenix
49 \fBNot Quite NFS, Soft Cache Consistency for NFS\fR
56 \fIUniversity of Guelph\fR
65 There are some constraints inherent in the NFS\(tm\(mo protocol
66 that result in performance limitations
68 workstation environments.
69 This paper discusses an NFS-like protocol named Not Quite NFS (NQNFS),
70 designed to address some of these limitations.
71 This protocol provides full cache consistency during normal
72 operation, while permitting more effective client-side caching in an
73 effort to improve performance.
74 There are also a variety of minor protocol changes, in order to resolve
76 The emphasis is on observed performance of a
77 preliminary implementation of the protocol, in order to show
78 how well this design works
79 and to suggest possible areas for further improvement.
82 It has been observed that
83 overall workstation performance has not been scaling with
84 processor speed and that file system I/O is a limiting factor [Ousterhout90].
87 that a principal challenge for operating system developers is the
88 decoupling of system calls from their underlying I/O operations, in order
89 to improve average system call response times.
90 For distributed file systems, every synchronous Remote Procedure Call (RPC)
91 takes a minimum of a few milliseconds and, as such, is analogous to an
92 underlying I/O operation.
93 This suggests that client caching with a very good
94 hit ratio for read type operations, along with asynchronous writing, is required in order to avoid delays waiting for RPC replies.
95 However, the NFS protocol requires that the server be stateless\**
97 \**The server must not require any state that may be lost due to a crash, to
100 and does not provide any explicit mechanism for client cache
102 constraints on how the client may cache data.
103 This paper describes an NFS-like protocol that includes a cache consistency
104 component designed to enhance client caching performance. It does provide
105 full consistency under normal operation, but without requiring that hard
106 state information be maintained on the server.
107 Design tradeoffs were made towards simplicity and
108 high performance over cache consistency under abnormal conditions.
109 The protocol design uses a variation of Leases [Gray89]
110 to provide state on the server that does not need to be recovered after a
113 The protocol also includes changes designed to address other limitations
114 of NFS in a modern workstation environment.
115 The use of TCP transport is optionally available to avoid
116 the pitfalls of Sun RPC over UDP transport when running across an internetwork [Nowicki89].
117 Kerberos [Steiner88] support is available
118 to do proper user authentication, in order to provide improved security and
119 arbitrary client to server user ID mappings.
120 There are also a variety of other changes to accommodate large file systems,
121 such as 64bit file sizes and offsets, as well as lifting the 8Kbyte I/O size
123 The remainder of this paper gives an overview of the protocol, highlighting
124 performance related components, followed by an evaluation of resultant performance
125 for the 4.4BSD implementation.
126 .sh 1 "Distributed File Systems and Caching"
128 Clients using distributed file systems cache recently-used data in order
129 to reduce the number of synchronous server operations, and therefore improve
130 average response times for system calls.
131 Unfortunately, maintaining consistency between these caches is a problem
132 whenever write sharing occurs; that is, when a process on a client writes
133 to a file and one or more processes on other client(s) read the file.
134 If the writer closes the file before any reader(s) open the file for reading,
135 this is called sequential write sharing. Both the Andrew ITC file system
136 [Howard88] and NFS [Sandberg85] maintain consistency for sequential write
137 sharing by requiring the writer to push all the writes through to the
138 server on close and having readers check to see if the file has been
139 modified upon open. If the file has been modified, the client throws away
140 all cached data for that file, as it is now stale.
141 NFS implementations typically detect file modification by checking a cached
142 copy of the file's modification time; since this cached value is often
143 several seconds out of date and only has a resolution of one second, an NFS
144 client often uses stale cached data for some time after the file has
145 been updated on the server.
147 A more difficult case is concurrent write sharing, where write operations are intermixed
148 with read operations.
149 Consistency for this case, often referred to as "full cache consistency,"
150 requires that a reader always receives the most recently written data.
151 Neither NFS nor the Andrew ITC file system maintain consistency for this
153 The simplest mechanism for maintaining full cache consistency is the one
154 used by Sprite [Nelson88], which disables all client caching of the
155 file whenever concurrent write sharing might occur.
156 There are other mechanisms described in the literature [Kent87a,
157 Burrows88], but they appeared to be too elaborate for incorporation
158 into NQNFS (for example, Kent's requires specialized hardware).
159 NQNFS differs from Sprite in the way it
160 detects write sharing. The Sprite server maintains a list of files currently open
161 by the various clients and detects write sharing when a file open request
162 for writing is received and the file is already open for reading
164 This list of open files is hard state information that must be recovered
165 after a server crash, which is a significant problem in its own
166 right [Mogul93, Welch90].
168 The approach used by NQNFS is a variant of the Leases mechanism [Gray89].
169 In this model, the server issues to a client a promise, referred to as a
170 "lease," that the client may cache a specific object without fear of
172 A lease has a limited duration and must be renewed by the client if it
173 wishes to continue to cache the object.
174 In NQNFS, clients hold short-term (up to one minute) leases on files
175 for reading or writing.
176 The leases are analogous to entries in the open file list, except that
177 they expire after the lease term unless renewed by the client.
178 As such, one minute after issuing the last lease there are no current
179 leases and therefore no lease records to be recovered after a crash, hence
180 the term "soft server state."
182 A related design consideration is the way client writing is done.
183 Synchronous writing requires that all writes be pushed through to the server
184 during the write system call.
185 This is the simplest variant, from a consistency point of view, since the
186 server always has the most recently written data. It also permits any write
187 errors, such as "file system out of space" to be propagated back to the
188 client's process via the write system call return.
189 Unfortunately this approach limits the client write rate, based on server write
190 performance and client/server RPC round trip time (RTT).
192 An alternative to this is delayed writing, where the write system call returns
193 as soon as the data is cached on the client and the data is written to the
194 server sometime later.
195 This permits client writing to occur at the rate of local storage access
196 up to the size of the local cache.
197 Also, for cases where file truncation/deletion occurs shortly after writing,
198 the write to the server may be avoided since the data has already been
199 deleted, reducing server write load.
200 There are some obvious drawbacks to this approach.
201 For any Sprite-like system to maintain
202 full consistency, the server must "callback" to the client to cause the
203 delayed writes to be written back to the server when write sharing is about to
205 There are also problems with the propagation of errors
206 back to the client process that issued the write system call.
207 The reason for this is that
208 the system call has already returned without reporting an error and the
209 process may also have already terminated.
210 As well, there is a risk of the loss of recently written data if the client
211 crashes before the data is written back to the server.
213 A compromise between these two alternatives is asynchronous writing, where
214 the write to the server is initiated during the write system call but the write system
215 call returns before the write completes.
216 This approach minimizes the risk of data loss due to a client crash, but negates
217 the possibility of reducing server write load by throwing writes away when
218 a file is truncated or deleted.
220 NFS implementations usually do a mix of asynchronous and delayed writing
221 but push all writes to the server upon close, in order to maintain open/close
223 Pushing the delayed writes on close
224 negates much of the performance advantage of delayed writing, since the
225 delays that were avoided in the write system calls are observed in the close
227 Akin to Sprite, the NQNFS protocol does delayed writing in an effort to achieve
228 good client performance and uses a callback mechanism to maintain full cache
232 There has been a great deal of effort put into improving the performance and
233 consistency of the NFS protocol. This work can be put in two categories.
234 The first category are implementation enhancements for the NFS protocol and
235 the second involve modifications to the protocol.
237 The work done on implementation enhancements have attacked two problem areas,
238 NFS server write performance and RPC transport problems.
239 Server write performance is a major problem for NFS, in part due to the
240 requirement to push all writes to the server upon close and in part due
241 to the fact that, for writes, all data and meta-data must be committed to
242 non-volatile storage before the server replies to the write RPC.
243 The Prestoserve\(tm\(dg
245 system uses non-volatile RAM as a buffer for recently written data on the server,
246 so that the write RPC replies can be returned to the client before the data is written to the
248 Write gathering [Juszczak94] is a software technique used on the server where a write
249 RPC request is delayed for a short time in the hope that another contiguous
250 write request will arrive, so that they can be merged into one write operation.
251 Since the replies to all of the merged writes are not returned to the client until the write
252 operation is completed, this delay does not violate the protocol.
253 When write operations are merged, the number of disk writes can be reduced,
254 improving server write performance.
255 Although either of the above reduces write RPC response time for the server,
256 it cannot be reduced to zero, and so, any client side caching mechanism
257 that reduces write RPC load or client dependence on server RPC response time
258 should still improve overall performance.
259 Good client side caching should be complementary to these server techniques,
260 although client performance improvements as a result of caching may be less
261 dramatic when these techniques are used.
263 In NFS, each Sun RPC request is packaged in a UDP datagram for transmission
264 to the server. A timer is started, and if a timeout occurs before the corresponding
265 RPC reply is received, the RPC request is retransmitted.
266 There are two problems with this model.
267 First, when a retransmit timeout occurs, the RPC may be redone, instead of
268 simply retransmitting the RPC request message to the server. A recent-request
269 cache can be used on the server to minimize the negative impact of redoing
271 The second problem is that a large UDP datagram, such as a read request or
272 write reply, must be fragmented by IP and if any one IP fragment is lost in
273 transit, the entire UDP datagram is lost [Kent87]. Since entire requests and replies
274 are packaged in a single UDP datagram, this puts an upper bound on the read/write
275 data size (8 kbytes).
277 Adjusting the retransmit timeout (RTT) interval dynamically and applying a
278 congestion window on outstanding requests has been shown to be of some help
279 [Nowicki89] with the retransmission problem.
280 An alternative to this is to use TCP transport to delivery the RPC messages
281 reliably [Macklem90] and one of the performance results in this paper
282 shows the effects of this further.
284 Srinivasan and Mogul [Srinivasan89] enhanced the NFS protocol to use the Sprite cache
285 consistency algorithm in an effort to improve performance and to provide
286 full client cache consistency.
287 This experimental implementation demonstrated significantly better
288 performance than NFS, but suffered from a lack of crash recovery support.
289 The NQNFS protocol design borrowed heavily from this work, but differed
290 from the Sprite algorithm by using Leases instead of file open state
291 to detect write sharing.
292 The decision to use Leases was made primarily to avoid the crash recovery
294 More recent work by the Sprite group [Baker91] and Mogul [Mogul93] have
295 addressed the crash recovery problem, making this design tradeoff more
298 Sun has recently updated the NFS protocol to Version 3 [SUN93], using some
299 changes similar to NQNFS to address various issues. The Version 3 protocol
300 uses 64bit file sizes and offsets, provides a Readdir_and_Lookup RPC and
302 It also provides cache hints, to permit a client to be able to determine
303 whether a file modification is the result of that client's write or some
304 other client's write.
305 It would be possible to add either Spritely NFS or NQNFS support for cache
306 consistency to the NFS Version 3 protocol.
307 .sh 1 "NQNFS Consistency Protocol and Recovery"
309 The NQNFS cache consistency protocol uses a somewhat Sprite-like [Nelson88]
310 mechanism, but is based on Leases [Gray89] instead of hard server state information
312 The basic principle is that the server disables client caching of files whenever
313 concurrent write sharing could occur, by performing a server-to-client
315 forcing the client to flush its caches and to do all subsequent I/O on the file with
317 A Sprite server maintains a record of the open state of files for
318 all clients and uses this to determine when concurrent write sharing might
320 This \fIopen state\fR information might also be referred to as an infinite-term
321 lease for the file, with explicit lease cancellation.
322 NQNFS, on the other hand, uses a short-term lease that expires due to timeout
323 after a maximum of one minute, unless explicitly renewed by the client.
324 The fundamental difference is that an NQNFS client must keep renewing
325 a lease to use cached data whereas a Sprite client assumes the data is valid until canceled
327 or the file is closed.
328 Using leases permits the server to remain "stateless," since the soft
329 state information, which consists of the set of current leases, is
330 moot after one minute, when all the leases expire.
332 Whenever a client wishes to access a file's data it must hold one of
333 three types of lease: read-caching, write-caching or non-caching.
334 The latter type requires that all file operations be done synchronously with
335 the server via the appropriate RPCs.
337 A read-caching lease allows for client data caching but no modifications
339 It may, however, be shared between multiple clients. Diagram 1 shows a typical
340 read-caching scenario. The vertical solid black lines depict the lease records.
341 Note that the time lines are nowhere near to scale, since a client/server
342 interaction will normally take less than one hundred milliseconds, whereas the
343 normal lease duration is thirty seconds.
344 Every lease includes a \fImodrev\fR value, which changes upon every modification
345 of the file. It may be used to check to see if data cached on the client is
348 A write-caching lease permits delayed write caching,
349 but requires that all data be pushed to the server when the lease expires
350 or is terminated by an eviction callback.
351 When a write-caching lease has almost expired, the client will attempt to
352 extend the lease if the file is still open, but is required to push the delayed writes to the server
353 if renewal fails (as depicted by diagram 2).
354 The writes may not arrive at the server until after the write lease has
355 expired on the client, but this does not result in a consistency problem,
356 so long as the write lease is still valid on the server.
357 Note that, in diagram 2, the lease record on the server remains current after
358 the expiry time, due to the conditions mentioned in section 5.
359 If a write RPC is done on the server after the write lease has expired on
360 the server, this could be considered an error since consistency could be
361 lost, but it is not handled as such by NQNFS.
363 Diagram 3 depicts how read and write leases are replaced by a non-caching
364 lease when there is the potential for write sharing.
370 line from 0.738,5.388 to 1.238,5.388
374 line dashed from 1.488,10.075 to 1.488,5.450
375 line dashed from 2.987,10.075 to 2.987,5.450
376 line dashed from 4.487,10.075 to 4.487,5.450
379 line from 4.487,7.013 to 4.487,5.950
380 line from 2.987,7.700 to 2.987,5.950 to 2.987,6.075
381 line from 1.488,7.513 to 1.488,5.950
382 line from 2.987,9.700 to 2.987,8.325
383 line from 1.488,9.450 to 1.488,8.325
386 line from 2.987,6.450 to 4.487,6.200
387 line from 4.385,6.192 to 4.487,6.200 to 4.393,6.241
388 line from 4.487,6.888 to 2.987,6.575
389 line from 3.080,6.620 to 2.987,6.575 to 3.090,6.571
390 line from 2.987,7.263 to 4.487,7.013
391 line from 4.385,7.004 to 4.487,7.013 to 4.393,7.054
392 line from 4.487,7.638 to 2.987,7.388
393 line from 3.082,7.429 to 2.987,7.388 to 3.090,7.379
394 line from 2.987,6.888 to 1.488,6.575
395 line from 1.580,6.620 to 1.488,6.575 to 1.590,6.571
396 line from 1.488,7.200 to 2.987,6.950
397 line from 2.885,6.942 to 2.987,6.950 to 2.893,6.991
398 line from 2.987,7.700 to 1.488,7.513
399 line from 1.584,7.550 to 1.488,7.513 to 1.590,7.500
400 line from 1.488,8.012 to 2.987,7.763
401 line from 2.885,7.754 to 2.987,7.763 to 2.893,7.804
402 line from 2.987,9.012 to 1.488,8.825
403 line from 1.584,8.862 to 1.488,8.825 to 1.590,8.813
404 line from 1.488,9.325 to 2.987,9.137
405 line from 2.885,9.125 to 2.987,9.137 to 2.891,9.175
406 line from 2.987,9.637 to 1.488,9.450
407 line from 1.584,9.487 to 1.488,9.450 to 1.590,9.438
408 line from 1.488,9.887 to 2.987,9.700
409 line from 2.885,9.688 to 2.987,9.700 to 2.891,9.737
414 "Lease valid on machine" at 1.363,5.296 ljust
415 "with same modrev" at 1.675,7.421 ljust
416 "miss)" at 2.612,9.233 ljust
417 "(cache" at 2.300,9.358 ljust
420 "Diagram #1: Read Caching Leases" at 0.738,5.114 ljust
421 "Client B" at 4.112,10.176 ljust
422 "Server" at 2.612,10.176 ljust
423 "Client A" at 0.925,10.176 ljust
426 "from cache" at 4.675,6.546 ljust
427 "Read syscalls" at 4.675,6.796 ljust
428 "Reply" at 3.737,6.108 ljust
429 "(cache miss)" at 3.675,6.421 ljust
430 "Read req" at 3.737,6.608 ljust
431 "to lease" at 3.112,6.796 ljust
432 "Client B added" at 3.112,6.983 ljust
433 "Reply" at 3.237,7.296 ljust
434 "Read + lease req" at 3.175,7.671 ljust
435 "Read syscall" at 4.675,7.608 ljust
436 "Reply" at 1.675,6.796 ljust
437 "miss)" at 2.487,7.108 ljust
438 "Read req (cache" at 1.675,7.233 ljust
439 "from cache" at 0.425,6.296 ljust
440 "Read syscalls" at 0.425,6.546 ljust
441 "cache" at 0.425,6.858 ljust
442 "so can still" at 0.425,7.108 ljust
443 "Modrev same" at 0.425,7.358 ljust
444 "Reply" at 1.675,7.671 ljust
445 "Get lease req" at 1.675,8.108 ljust
446 "Read syscall" at 0.425,7.983 ljust
447 "Lease times out" at 0.425,8.296 ljust
448 "from cache" at 0.425,9.046 ljust
449 "Read syscalls" at 0.425,9.296 ljust
450 "for Client A" at 3.112,9.296 ljust
451 "Read caching lease" at 3.112,9.483 ljust
452 "Reply" at 1.675,8.983 ljust
453 "Read req" at 1.675,9.358 ljust
454 "Reply" at 1.675,9.608 ljust
455 "Read + lease req" at 1.675,9.921 ljust
456 "Read syscall" at 0.425,9.921 ljust
467 line from 1.175,5.700 to 1.300,5.700
468 line from 0.738,5.700 to 1.175,5.700
469 line from 2.987,6.638 to 2.987,6.075
473 line dashed from 2.987,6.575 to 2.987,5.950
474 line dashed from 1.488,6.575 to 1.488,5.888
477 line from 2.987,9.762 to 2.987,6.638
478 line from 1.488,9.450 to 1.488,7.700
481 line from 2.987,6.763 to 1.488,6.575
482 line from 1.584,6.612 to 1.488,6.575 to 1.590,6.563
483 line from 1.488,7.013 to 2.987,6.825
484 line from 2.885,6.813 to 2.987,6.825 to 2.891,6.862
485 line from 2.987,7.325 to 1.488,7.075
486 line from 1.582,7.116 to 1.488,7.075 to 1.590,7.067
487 line from 1.488,7.700 to 2.987,7.388
488 line from 2.885,7.383 to 2.987,7.388 to 2.895,7.432
489 line from 2.987,8.575 to 1.488,8.325
490 line from 1.582,8.366 to 1.488,8.325 to 1.590,8.317
491 line from 1.488,8.887 to 2.987,8.637
492 line from 2.885,8.629 to 2.987,8.637 to 2.893,8.679
493 line from 2.987,9.637 to 1.488,9.450
494 line from 1.584,9.487 to 1.488,9.450 to 1.590,9.438
495 line from 1.488,9.887 to 2.987,9.762
496 line from 2.886,9.746 to 2.987,9.762 to 2.890,9.796
497 line dashed from 2.987,10.012 to 2.987,6.513
498 line dashed from 1.488,10.012 to 1.488,6.513
503 "write" at 4.237,5.921 ljust
504 "Lease valid on machine" at 1.425,5.733 ljust
507 "Diagram #2: Write Caching Lease" at 0.738,5.551 ljust
508 "Server" at 2.675,10.114 ljust
509 "Client A" at 1.113,10.114 ljust
512 "seconds after last" at 3.112,5.921 ljust
513 "Expires write_slack" at 3.112,6.108 ljust
514 "due to write activity" at 3.112,6.608 ljust
515 "Expiry delayed" at 3.112,6.796 ljust
516 "Lease times out" at 3.112,7.233 ljust
517 "Lease renewed" at 3.175,8.546 ljust
518 "Lease for client A" at 3.175,9.358 ljust
519 "Write caching" at 3.175,9.608 ljust
520 "Reply" at 1.675,6.733 ljust
521 "Write req" at 1.988,7.046 ljust
522 "Reply" at 1.675,7.233 ljust
523 "Write req" at 1.675,7.796 ljust
524 "Lease expires" at 0.487,7.733 ljust
525 "Close syscall" at 0.487,8.108 ljust
526 "lease granted" at 1.675,8.546 ljust
527 "Get write lease" at 1.675,8.921 ljust
528 "before expiry" at 0.487,8.608 ljust
529 "Lease renewal" at 0.487,8.796 ljust
530 "syscalls" at 0.487,9.046 ljust
531 "Delayed write" at 0.487,9.233 ljust
532 "lease granted" at 1.675,9.608 ljust
533 "Get write lease req" at 1.675,9.921 ljust
534 "Write syscall" at 0.487,9.858 ljust
545 line from 0.613,2.638 to 1.238,2.638
546 line from 1.488,4.075 to 1.488,3.638
547 line from 2.987,4.013 to 2.987,3.575
548 line from 4.487,4.013 to 4.487,3.575
551 line from 2.987,3.888 to 4.487,3.700
552 line from 4.385,3.688 to 4.487,3.700 to 4.391,3.737
553 line from 4.487,4.138 to 2.987,3.950
554 line from 3.084,3.987 to 2.987,3.950 to 3.090,3.938
555 line from 2.987,4.763 to 4.487,4.450
556 line from 4.385,4.446 to 4.487,4.450 to 4.395,4.495
559 line from 4.487,4.438 to 4.487,4.013
562 line from 4.487,5.138 to 2.987,4.888
563 line from 3.082,4.929 to 2.987,4.888 to 3.090,4.879
566 line from 4.487,6.513 to 4.487,5.513
567 line from 4.487,6.513 to 4.487,6.513 to 4.487,5.513
568 line from 2.987,5.450 to 2.987,5.200
569 line from 1.488,5.075 to 1.488,4.075
570 line from 2.987,5.263 to 2.987,4.013
571 line from 2.987,7.700 to 2.987,5.325
572 line from 4.487,7.575 to 4.487,6.513
573 line from 1.488,8.512 to 1.488,8.075
574 line from 2.987,8.637 to 2.987,8.075
575 line from 2.987,9.637 to 2.987,8.825
576 line from 1.488,9.450 to 1.488,8.950
579 line from 2.987,4.450 to 1.488,4.263
580 line from 1.584,4.300 to 1.488,4.263 to 1.590,4.250
581 line from 1.488,4.888 to 2.987,4.575
582 line from 2.885,4.571 to 2.987,4.575 to 2.895,4.620
583 line from 2.987,5.263 to 1.488,5.075
584 line from 1.584,5.112 to 1.488,5.075 to 1.590,5.063
585 line from 4.487,5.513 to 2.987,5.325
586 line from 3.084,5.362 to 2.987,5.325 to 3.090,5.313
587 line from 2.987,5.700 to 4.487,5.575
588 line from 4.386,5.558 to 4.487,5.575 to 4.390,5.608
589 line from 4.487,6.013 to 2.987,5.825
590 line from 3.084,5.862 to 2.987,5.825 to 3.090,5.813
591 line from 2.987,6.200 to 4.487,6.075
592 line from 4.386,6.058 to 4.487,6.075 to 4.390,6.108
593 line from 4.487,6.450 to 2.987,6.263
594 line from 3.084,6.300 to 2.987,6.263 to 3.090,6.250
595 line from 2.987,6.700 to 4.487,6.513
596 line from 4.385,6.500 to 4.487,6.513 to 4.391,6.550
597 line from 1.488,6.950 to 2.987,6.763
598 line from 2.885,6.750 to 2.987,6.763 to 2.891,6.800
599 line from 2.987,7.700 to 4.487,7.575
600 line from 4.386,7.558 to 4.487,7.575 to 4.390,7.608
601 line from 4.487,7.950 to 2.987,7.763
602 line from 3.084,7.800 to 2.987,7.763 to 3.090,7.750
603 line from 2.987,8.637 to 1.488,8.512
604 line from 1.585,8.546 to 1.488,8.512 to 1.589,8.496
605 line from 1.488,8.887 to 2.987,8.700
606 line from 2.885,8.688 to 2.987,8.700 to 2.891,8.737
607 line from 2.987,9.637 to 1.488,9.450
608 line from 1.584,9.487 to 1.488,9.450 to 1.590,9.438
609 line from 1.488,9.950 to 2.987,9.762
610 line from 2.885,9.750 to 2.987,9.762 to 2.891,9.800
612 line dashed from 4.487,10.137 to 4.487,2.825
613 line dashed from 2.987,10.137 to 2.987,2.825
614 line dashed from 1.488,10.137 to 1.488,2.825
619 "(not cached)" at 4.612,3.858 ljust
622 "Diagram #3: Write sharing case" at 0.613,2.239 ljust
625 "Write syscall" at 4.675,7.546 ljust
626 "Read syscall" at 0.550,9.921 ljust
629 "Lease valid on machine" at 1.363,2.551 ljust
632 "(can still cache)" at 1.675,8.171 ljust
633 "Reply" at 3.800,3.858 ljust
634 "Write" at 3.175,4.046 ljust
635 "writes" at 4.612,4.046 ljust
636 "synchronous" at 4.612,4.233 ljust
637 "write syscall" at 4.675,5.108 ljust
638 "non-caching lease" at 3.175,4.296 ljust
639 "Reply " at 3.175,4.483 ljust
640 "req" at 3.175,4.983 ljust
641 "Get write lease" at 3.175,5.108 ljust
642 "Vacated msg" at 3.175,5.483 ljust
643 "to the server" at 4.675,5.858 ljust
644 "being flushed to" at 4.675,6.046 ljust
645 "Delayed writes" at 4.675,6.233 ljust
648 "Server" at 2.675,10.182 ljust
649 "Client B" at 3.925,10.182 ljust
650 "Client A" at 0.863,10.182 ljust
653 "(not cached)" at 0.550,4.733 ljust
654 "Read data" at 0.550,4.921 ljust
655 "Reply data" at 1.675,4.421 ljust
656 "Read request" at 1.675,4.921 ljust
657 "lease" at 1.675,5.233 ljust
658 "Reply non-caching" at 1.675,5.421 ljust
659 "Reply" at 3.737,5.733 ljust
660 "Write" at 3.175,5.983 ljust
661 "Reply" at 3.737,6.171 ljust
662 "Write" at 3.175,6.421 ljust
663 "Eviction Notice" at 3.175,6.796 ljust
664 "Get read lease" at 1.675,7.046 ljust
665 "Read syscall" at 0.550,6.983 ljust
666 "being cached" at 4.675,7.171 ljust
667 "Delayed writes" at 4.675,7.358 ljust
668 "lease" at 3.175,7.233 ljust
669 "Reply write caching" at 3.175,7.421 ljust
670 "Get write lease" at 3.175,7.983 ljust
671 "Write syscall" at 4.675,7.983 ljust
672 "with same modrev" at 1.675,8.358 ljust
673 "Lease" at 0.550,8.171 ljust
674 "Renewed" at 0.550,8.358 ljust
675 "Reply" at 1.675,8.608 ljust
676 "Get Lease Request" at 1.675,8.983 ljust
677 "Read syscall" at 0.550,8.733 ljust
678 "from cache" at 0.550,9.108 ljust
679 "Read syscall" at 0.550,9.296 ljust
680 "Reply " at 1.675,9.671 ljust
681 "plus lease" at 2.050,9.983 ljust
682 "Read Request" at 1.675,10.108 ljust
688 A write-caching lease is not used in the Stanford V Distributed System [Gray89],
689 since synchronous writing is always used. A side effect of this change
690 is that the five to ten second lease duration recommended by Gray was found
691 to be insufficient to achieve good performance for the write-caching lease.
692 Experimentation showed that thirty seconds was about optimal for cases where
693 the client and server are connected to the same local area network, so
694 thirty seconds is the default lease duration for NQNFS.
695 A maximum of twice that value is permitted, since Gray showed that for some
696 network topologies, a larger lease duration functions better.
697 Although there is an explicit get_lease RPC defined for the protocol,
698 most lease requests are piggybacked onto the other RPCs to minimize the
699 additional overhead introduced by leasing.
702 Leasing was chosen over hard server state information for the following
705 The server must maintain state information about all current
707 Since at most one lease is allocated for each RPC and the leases expire
708 after their lease term,
709 the upper bound on the number of current leases is the product of the
710 lease term and the server RPC rate.
711 In practice, it has been observed that less than 10% of RPCs request new leases
712 and since most leases have a term of thirty seconds, the following rule of
713 thumb should estimate the number of server lease records:
716 Number of Server Lease Records \(eq 0.1 * 30 * RPC rate
719 Since each lease record occupies 64 bytes of server memory, storing the lease
720 records should not be a serious problem.
721 If a server has exhausted lease storage, it can simply wait a few seconds
722 for a lease to expire and free up a record.
723 On the other hand, a Sprite-like server must store records for all files
724 currently open by all clients, which can require significant storage for
725 a large, heavily loaded server.
726 In [Mogul93], it is proposed that a mechanism vaguely similar to paging could be
727 used to deal with this for Spritely NFS, but this
728 appears to introduce a fair amount of complexity and may limit the
729 usefulness of open records for storing other state information, such
732 After a server crashes it must recover lease records for
733 the current outstanding leases, which actually implies that if it waits
734 until all leases have expired, there is no state to recover.
735 The server must wait for the maximum lease duration of one minute, and it must serve
736 all outstanding write requests resulting from terminated write-caching
737 leases before issuing new leases. The one minute delay can be overlapped with
738 file system consistency checking (eg. fsck).
739 Because no state must be recovered, a lease-based server, like an NFS server,
740 avoids the problem of state recovery after a crash.
742 There can, however, be problems during crash recovery
743 because of a potentially large number of write backs due to terminated
744 write-caching leases.
745 One of these problems is a "recovery storm" [Baker91], which could occur when
746 the server is overloaded by the number of write RPC requests.
747 The NQNFS protocol deals with this by replying
748 with a return status code called
749 try_again_later to all
750 RPC requests (except write) until the write requests subside.
751 At this time, there has not been sufficient testing of server crash
752 recovery while under heavy server load to determine if the try_again_later
753 reply is a sufficient solution to the problem.
754 The other problem is that consistency will be lost if other RPCs are performed
755 before all of the write backs for terminated write-caching leases have completed.
756 This is handled by only performing write RPCs until
757 no write RPC requests arrive
758 for write_slack seconds, where write_slack is set to several times
759 the client timeout retransmit interval,
760 at which time it is assumed all clients have had an opportunity to send their writes
763 Another advantage of leasing is that, since leases are required at times when other I/O operations occur,
764 lease requests can almost always be piggybacked on other RPCs, avoiding some of the
765 overhead associated with the explicit open and close RPCs required by a Sprite-like system.
766 Compared with Sprite cache consistency,
767 this can result in a significantly lower RPC load (see table #1).
768 .sh 1 "Limitations of the NQNFS Protocol"
770 There is a serious risk when leasing is used for delayed write
772 If the server is simply too busy to service a lease renewal before a write-caching
773 lease terminates, the client will not be able to push the write
774 data to the server before the lease has terminated, resulting in
776 Note that the danger of inconsistency occurs when the server assumes that
777 a write-caching lease has terminated before the client has
778 had the opportunity to write the data back to the server.
779 In an effort to avoid this problem, the NQNFS server does not assume that
780 a write-caching lease has terminated until three conditions are met:
783 1 - clock time > (expiry time + clock skew)
784 2 - there is at least one server daemon (nfsd) waiting for an RPC request
785 3 - no write RPCs received for leased file within write_slack after the corrected expiry time
788 The first condition ensures that the lease has expired on the client.
789 The clock_skew, by default three seconds, must be
790 set to a value larger than the maximum time-of-day clock error that is likely to occur
791 during the maximum lease duration.
792 The second condition attempts to ensure that the client
793 is not waiting for replies to any writes that are still queued for service by
794 an nfsd. The third condition tries to guarantee that the client has
795 transmitted all write requests to the server, since write_slack is set to
796 several times the client's timeout retransmit interval.
798 There are also certain file system semantics that are problematic for both NFS and NQNFS,
800 lack of state information maintained by the
801 server. If a file is unlinked on one client while open on another it will
802 be removed from the file server, resulting in failed file accesses on the
803 client that has the file open.
804 If the file system on the server is out of space or the client user's disk
805 quota has been exceeded, a delayed write can fail long after the write system
806 call was successfully completed.
807 With NFS this error will be detected by the close system call, since
808 the delayed writes are pushed upon close. With NQNFS however, the delayed write
809 RPC may not occur until after the close system call, possibly even after the process
812 if a process must check for write errors,
813 a system call such as \fIfsync\fR must be used.
815 Another problem occurs when a process on one client is
816 running an executable file
817 and a process on another client starts to write to the file. The read lease on
818 the first client is terminated by the server, but the client has no recourse but
819 to terminate the process, since the process is already in progress on the old
822 The NQNFS protocol does not support file locking, since a file lock would have
823 to involve hard, recovered after a crash, state information.
824 .sh 1 "Other NQNFS Protocol Features"
826 NQNFS also includes a variety of minor modifications to the NFS protocol, in an
827 attempt to address various limitations.
828 The protocol uses 64bit file sizes and offsets in order to handle large files.
829 TCP transport may be used as an alternative to UDP
830 for cases where UDP does not perform well.
832 such as TCP also permit the use of much larger read/write data sizes,
833 which might improve performance in certain environments.
835 The NQNFS protocol replaces the Readdir RPC with a Readdir_and_Lookup
836 RPC that returns the file handle and attributes for each file in the
837 directory as well as name and file id number.
838 This additional information may then be loaded into the lookup and file-attribute
839 caches on the client.
840 Thus, for cases such as "ls -l", the \fIstat\fR system calls can be performed
841 locally without doing any lookup or getattr RPCs.
842 Another additional RPC is the Access RPC that checks for file
843 accessibility against the server. This is necessary since in some cases the
844 client user ID is mapped to a different user on the server and doing the
845 access check locally on the client using file attributes and client credentials is
847 One case where this becomes necessary is when the NQNFS mount point is using
848 Kerberos authentication, where the Kerberos authentication ticket is translated
849 to credentials on the server that are mapped to the client side user id.
850 For further details on the protocol, see [Macklem93].
853 In order to evaluate the effectiveness of the NQNFS protocol,
854 a benchmark was used that was
856 real work on the client workstation.
857 Benchmarks, such as Laddis [Wittle93], that perform server load characterization
858 are not appropriate for this work, since it is primarily client caching
859 efficiency that needs to be evaluated.
860 Since these tests are measuring overall client system performance and
861 not just the performance of the file system,
862 each sequence of runs was performed on identical hardware and operating system in order to factor out the system
863 components affecting performance other than the file system protocol.
865 The equipment used for the all the benchmarks are members of the DECstation\(tm\(dg
866 family of workstations using the MIPS\(tm\(sc RISC architecture.
867 The operating system running on these systems was a pre-release version of
869 For all benchmarks, the file server was a DECstation 2100 (10 MIPS) with 8Mbytes of
870 memory and a local RZ23 SCSI disk (27msec average access time).
871 The clients range in speed from DECstation 2100s
872 to a DECstation 5000/25, and always run with six block I/O daemons
873 and a 4Mbyte buffer cache, except for the test runs where the
874 buffer cache size was the independent variable.
875 In all cases /tmp is mounted on the local SCSI disk\**, all machines were
876 attached to the same uncongested Ethernet, and ran in single user mode during the benchmarks.
878 \**Testing using the 4.4BSD MFS [McKusick90] resulted in slightly degraded performance,
879 probably since the machines only had 16Mbytes of memory, and so paging
882 Unless noted otherwise, test runs used UDP RPC transport
883 and the results given are the average values of four runs.
885 The benchmark used is the Modified Andrew Benchmark (MAB)
887 which is a slightly modified version of the benchmark used to characterize
888 performance of the Andrew ITC file system [Howard88].
889 The MAB was set up with the executable binaries in the remote mounted file
890 system and the final load step was commented out, due to a linkage problem
891 during testing under 4.4BSD.
892 Therefore, these results are not directly comparable to other reported MAB
894 The MAB is made up of five distinct phases:
897 Makes five directories (no significant cost)
899 Copy a file system subtree to a working directory
901 Get file attributes (stat) of all the working files
903 Search for strings (grep) in the files
905 Compile a library of C sources and archive them
907 Of the five phases, the fifth is by far the largest and is the one affected most
908 by client caching mechanisms.
909 The results for phase #1 are invariant over all
910 the caching mechanisms.
911 .sh 2 "Buffer Cache Size Tests"
913 The first experiment was done to see what effect changing the size of the
914 buffer cache would have on client performance. A single DECstation 5000/25
915 was used to do a series of runs of MAB with different buffer cache sizes
916 for four variations of the file system protocol. The four variations are
919 NFS - The NFS protocol as implemented in 4.4BSD
921 Leases - The NQNFS protocol using leases for cache consistency
923 Leases, Rdirlookup - The NQNFS protocol using leases for cache consistency
924 and with the readdir RPC replaced by Readdir_and_Lookup
926 Leases, Attrib leases, Rdirlookup - The NQNFS protocol using leases for
927 cache consistency, with the readdir
928 RPC replaced by the Readdir_and_Lookup,
929 and requiring a valid lease not only for file-data access, but also for file-attribute access.
931 As can be seen in figure 1, the buffer cache achieves about optimal
932 performance for the range of two to ten megabytes in size. At eleven
933 megabytes in size, the system pages heavily and the runs did not
934 complete in a reasonable time. Even at 64Kbytes, the buffer cache improves
935 performance over no buffer cache by a significant margin of 136-148 seconds
937 This may be due, in part, to the fact that the Compile Phase of the MAB
938 uses a rather small working set of file data.
939 All variants of NQNFS achieve about
940 the same performance, running around 30% faster than NFS, with a slightly
941 larger difference for large buffer cache sizes.
942 Based on these results, all remaining tests were run with the buffer cache
944 Although I do not know what causes the local peak in the curves between 0.5 and 2 megabytes,
945 there is some indication that contention for buffer cache blocks, between the update process
946 (which pushes delayed writes to the server every thirty seconds) and the I/O
947 system calls, may be involved.
953 line dashed from 0.900,7.888 to 4.787,7.888
954 line dashed from 0.900,7.888 to 0.900,10.262
955 line from 0.900,7.888 to 0.963,7.888
956 line from 4.787,7.888 to 4.725,7.888
957 line from 0.900,8.188 to 0.963,8.188
958 line from 4.787,8.188 to 4.725,8.188
959 line from 0.900,8.488 to 0.963,8.488
960 line from 4.787,8.488 to 4.725,8.488
961 line from 0.900,8.775 to 0.963,8.775
962 line from 4.787,8.775 to 4.725,8.775
963 line from 0.900,9.075 to 0.963,9.075
964 line from 4.787,9.075 to 4.725,9.075
965 line from 0.900,9.375 to 0.963,9.375
966 line from 4.787,9.375 to 4.725,9.375
967 line from 0.900,9.675 to 0.963,9.675
968 line from 4.787,9.675 to 4.725,9.675
969 line from 0.900,9.963 to 0.963,9.963
970 line from 4.787,9.963 to 4.725,9.963
971 line from 0.900,10.262 to 0.963,10.262
972 line from 4.787,10.262 to 4.725,10.262
973 line from 0.900,7.888 to 0.900,7.950
974 line from 0.900,10.262 to 0.900,10.200
975 line from 1.613,7.888 to 1.613,7.950
976 line from 1.613,10.262 to 1.613,10.200
977 line from 2.312,7.888 to 2.312,7.950
978 line from 2.312,10.262 to 2.312,10.200
979 line from 3.025,7.888 to 3.025,7.950
980 line from 3.025,10.262 to 3.025,10.200
981 line from 3.725,7.888 to 3.725,7.950
982 line from 3.725,10.262 to 3.725,10.200
983 line from 4.438,7.888 to 4.438,7.950
984 line from 4.438,10.262 to 4.438,10.200
985 line from 0.900,7.888 to 4.787,7.888
986 line from 4.787,7.888 to 4.787,10.262
987 line from 4.787,10.262 to 0.900,10.262
988 line from 0.900,10.262 to 0.900,7.888
989 line from 3.800,8.775 to 4.025,8.775
990 line from 0.925,10.088 to 0.925,10.088
991 line from 0.925,10.088 to 0.938,9.812
992 line from 0.938,9.812 to 0.988,9.825
993 line from 0.988,9.825 to 1.075,9.838
994 line from 1.075,9.838 to 1.163,9.938
995 line from 1.163,9.938 to 1.250,9.838
996 line from 1.250,9.838 to 1.613,9.825
997 line from 1.613,9.825 to 2.312,9.750
998 line from 2.312,9.750 to 3.025,9.713
999 line from 3.025,9.713 to 3.725,9.850
1000 line from 3.725,9.850 to 4.438,9.875
1002 line dotted from 3.800,8.625 to 4.025,8.625
1003 line dotted from 0.925,9.912 to 0.925,9.912
1004 line dotted from 0.925,9.912 to 0.938,9.887
1005 line dotted from 0.938,9.887 to 0.988,9.713
1006 line dotted from 0.988,9.713 to 1.075,9.562
1007 line dotted from 1.075,9.562 to 1.163,9.562
1008 line dotted from 1.163,9.562 to 1.250,9.562
1009 line dotted from 1.250,9.562 to 1.613,9.675
1010 line dotted from 1.613,9.675 to 2.312,9.363
1011 line dotted from 2.312,9.363 to 3.025,9.375
1012 line dotted from 3.025,9.375 to 3.725,9.387
1013 line dotted from 3.725,9.387 to 4.438,9.450
1014 line dashed from 3.800,8.475 to 4.025,8.475
1015 line dashed from 0.925,10.000 to 0.925,10.000
1016 line dashed from 0.925,10.000 to 0.938,9.787
1017 line dashed from 0.938,9.787 to 0.988,9.650
1018 line dashed from 0.988,9.650 to 1.075,9.537
1019 line dashed from 1.075,9.537 to 1.163,9.613
1020 line dashed from 1.163,9.613 to 1.250,9.800
1021 line dashed from 1.250,9.800 to 1.613,9.488
1022 line dashed from 1.613,9.488 to 2.312,9.375
1023 line dashed from 2.312,9.375 to 3.025,9.363
1024 line dashed from 3.025,9.363 to 3.725,9.325
1025 line dashed from 3.725,9.325 to 4.438,9.438
1027 line dotted from 3.800,8.325 to 4.025,8.325
1028 line dotted from 0.925,9.963 to 0.925,9.963
1029 line dotted from 0.925,9.963 to 0.938,9.750
1030 line dotted from 0.938,9.750 to 0.988,9.662
1031 line dotted from 0.988,9.662 to 1.075,9.613
1032 line dotted from 1.075,9.613 to 1.163,9.613
1033 line dotted from 1.163,9.613 to 1.250,9.700
1034 line dotted from 1.250,9.700 to 1.613,9.438
1035 line dotted from 1.613,9.438 to 2.312,9.463
1036 line dotted from 2.312,9.463 to 3.025,9.312
1037 line dotted from 3.025,9.312 to 3.725,9.387
1038 line dotted from 3.725,9.387 to 4.438,9.425
1043 "0" at 0.825,7.810 rjust
1044 "20" at 0.825,8.110 rjust
1045 "40" at 0.825,8.410 rjust
1046 "60" at 0.825,8.697 rjust
1047 "80" at 0.825,8.997 rjust
1048 "100" at 0.825,9.297 rjust
1049 "120" at 0.825,9.597 rjust
1050 "140" at 0.825,9.885 rjust
1051 "160" at 0.825,10.185 rjust
1058 "Time (sec)" at 0.150,8.997
1059 "Buffer Cache Size (MBytes)" at 2.837,7.510
1060 "Figure #1: MAB Phase 5 (compile)" at 2.837,10.335
1061 "NFS" at 3.725,8.697 rjust
1062 "Leases" at 3.725,8.547 rjust
1063 "Leases, Rdirlookup" at 3.725,8.397 rjust
1064 "Leases, Attrib leases, Rdirlookup" at 3.725,8.247 rjust
1069 .sh 2 "Multiple Client Load Tests"
1071 During preliminary runs of the MAB, it was observed that the server RPC
1072 counts were reduced significantly by NQNFS as compared to NFS (table 1).
1073 (Spritely NFS and Ultrix\(tm4.3/NFS numbers were taken from [Mogul93]
1074 and are not directly comparable, due to numerous differences in the
1075 experimental setup including deletion of the load step from phase 5.)
1077 that the NQNFS protocol might scale better with
1078 respect to the number of clients accessing the server.
1079 The experiment described in this section
1080 ran the MAB on from one to ten clients concurrently, to observe the
1081 effects of heavier server load.
1082 The clients were started at roughly the same time by pressing all the
1083 <return> keys together and, although not synchronized beyond that point,
1084 all clients would finish the test run within about two seconds of each
1086 This was not a realistic load of N active clients, but it did
1087 result in a reproducible increasing client load on the server.
1088 The results for the four variants
1089 are plotted in figures 2-5.
1098 Table #1: MAB RPC Counts
1099 RPC Getattr Read Write Lookup Other GetLease/Open-Close Total
1101 BSD/NQNFS 277 139 306 575 294 127 1718
1102 BSD/NFS 1210 506 451 489 238 0 2894
1103 Spritely NFS 259 836 192 535 306 1467 3595
1104 Ultrix4.3/NFS 1225 1186 476 810 305 0 4002
1109 For the MAB benchmark, the NQNFS protocol reduces the RPC counts significantly,
1110 but with a minimum of extra overhead (the GetLease/Open-Close count).
1116 line dashed from 0.900,7.888 to 4.787,7.888
1117 line dashed from 0.900,7.888 to 0.900,10.262
1118 line from 0.900,7.888 to 0.963,7.888
1119 line from 4.787,7.888 to 4.725,7.888
1120 line from 0.900,8.225 to 0.963,8.225
1121 line from 4.787,8.225 to 4.725,8.225
1122 line from 0.900,8.562 to 0.963,8.562
1123 line from 4.787,8.562 to 4.725,8.562
1124 line from 0.900,8.900 to 0.963,8.900
1125 line from 4.787,8.900 to 4.725,8.900
1126 line from 0.900,9.250 to 0.963,9.250
1127 line from 4.787,9.250 to 4.725,9.250
1128 line from 0.900,9.588 to 0.963,9.588
1129 line from 4.787,9.588 to 4.725,9.588
1130 line from 0.900,9.925 to 0.963,9.925
1131 line from 4.787,9.925 to 4.725,9.925
1132 line from 0.900,10.262 to 0.963,10.262
1133 line from 4.787,10.262 to 4.725,10.262
1134 line from 0.900,7.888 to 0.900,7.950
1135 line from 0.900,10.262 to 0.900,10.200
1136 line from 1.613,7.888 to 1.613,7.950
1137 line from 1.613,10.262 to 1.613,10.200
1138 line from 2.312,7.888 to 2.312,7.950
1139 line from 2.312,10.262 to 2.312,10.200
1140 line from 3.025,7.888 to 3.025,7.950
1141 line from 3.025,10.262 to 3.025,10.200
1142 line from 3.725,7.888 to 3.725,7.950
1143 line from 3.725,10.262 to 3.725,10.200
1144 line from 4.438,7.888 to 4.438,7.950
1145 line from 4.438,10.262 to 4.438,10.200
1146 line from 0.900,7.888 to 4.787,7.888
1147 line from 4.787,7.888 to 4.787,10.262
1148 line from 4.787,10.262 to 0.900,10.262
1149 line from 0.900,10.262 to 0.900,7.888
1150 line from 3.800,8.900 to 4.025,8.900
1151 line from 1.250,8.325 to 1.250,8.325
1152 line from 1.250,8.325 to 1.613,8.500
1153 line from 1.613,8.500 to 2.312,8.825
1154 line from 2.312,8.825 to 3.025,9.175
1155 line from 3.025,9.175 to 3.725,9.613
1156 line from 3.725,9.613 to 4.438,10.012
1158 line dotted from 3.800,8.750 to 4.025,8.750
1159 line dotted from 1.250,8.275 to 1.250,8.275
1160 line dotted from 1.250,8.275 to 1.613,8.412
1161 line dotted from 1.613,8.412 to 2.312,8.562
1162 line dotted from 2.312,8.562 to 3.025,9.088
1163 line dotted from 3.025,9.088 to 3.725,9.375
1164 line dotted from 3.725,9.375 to 4.438,10.000
1165 line dashed from 3.800,8.600 to 4.025,8.600
1166 line dashed from 1.250,8.250 to 1.250,8.250
1167 line dashed from 1.250,8.250 to 1.613,8.438
1168 line dashed from 1.613,8.438 to 2.312,8.637
1169 line dashed from 2.312,8.637 to 3.025,9.088
1170 line dashed from 3.025,9.088 to 3.725,9.525
1171 line dashed from 3.725,9.525 to 4.438,10.075
1173 line dotted from 3.800,8.450 to 4.025,8.450
1174 line dotted from 1.250,8.262 to 1.250,8.262
1175 line dotted from 1.250,8.262 to 1.613,8.425
1176 line dotted from 1.613,8.425 to 2.312,8.613
1177 line dotted from 2.312,8.613 to 3.025,9.137
1178 line dotted from 3.025,9.137 to 3.725,9.512
1179 line dotted from 3.725,9.512 to 4.438,9.988
1184 "0" at 0.825,7.810 rjust
1185 "20" at 0.825,8.147 rjust
1186 "40" at 0.825,8.485 rjust
1187 "60" at 0.825,8.822 rjust
1188 "80" at 0.825,9.172 rjust
1189 "100" at 0.825,9.510 rjust
1190 "120" at 0.825,9.847 rjust
1191 "140" at 0.825,10.185 rjust
1198 "Time (sec)" at 0.150,8.997
1199 "Number of Clients" at 2.837,7.510
1200 "Figure #2: MAB Phase 2 (copying)" at 2.837,10.335
1201 "NFS" at 3.725,8.822 rjust
1202 "Leases" at 3.725,8.672 rjust
1203 "Leases, Rdirlookup" at 3.725,8.522 rjust
1204 "Leases, Attrib leases, Rdirlookup" at 3.725,8.372 rjust
1214 line dashed from 0.900,7.888 to 4.787,7.888
1215 line dashed from 0.900,7.888 to 0.900,10.262
1216 line from 0.900,7.888 to 0.963,7.888
1217 line from 4.787,7.888 to 4.725,7.888
1218 line from 0.900,8.188 to 0.963,8.188
1219 line from 4.787,8.188 to 4.725,8.188
1220 line from 0.900,8.488 to 0.963,8.488
1221 line from 4.787,8.488 to 4.725,8.488
1222 line from 0.900,8.775 to 0.963,8.775
1223 line from 4.787,8.775 to 4.725,8.775
1224 line from 0.900,9.075 to 0.963,9.075
1225 line from 4.787,9.075 to 4.725,9.075
1226 line from 0.900,9.375 to 0.963,9.375
1227 line from 4.787,9.375 to 4.725,9.375
1228 line from 0.900,9.675 to 0.963,9.675
1229 line from 4.787,9.675 to 4.725,9.675
1230 line from 0.900,9.963 to 0.963,9.963
1231 line from 4.787,9.963 to 4.725,9.963
1232 line from 0.900,10.262 to 0.963,10.262
1233 line from 4.787,10.262 to 4.725,10.262
1234 line from 0.900,7.888 to 0.900,7.950
1235 line from 0.900,10.262 to 0.900,10.200
1236 line from 1.613,7.888 to 1.613,7.950
1237 line from 1.613,10.262 to 1.613,10.200
1238 line from 2.312,7.888 to 2.312,7.950
1239 line from 2.312,10.262 to 2.312,10.200
1240 line from 3.025,7.888 to 3.025,7.950
1241 line from 3.025,10.262 to 3.025,10.200
1242 line from 3.725,7.888 to 3.725,7.950
1243 line from 3.725,10.262 to 3.725,10.200
1244 line from 4.438,7.888 to 4.438,7.950
1245 line from 4.438,10.262 to 4.438,10.200
1246 line from 0.900,7.888 to 4.787,7.888
1247 line from 4.787,7.888 to 4.787,10.262
1248 line from 4.787,10.262 to 0.900,10.262
1249 line from 0.900,10.262 to 0.900,7.888
1250 line from 3.800,8.775 to 4.025,8.775
1251 line from 1.250,8.975 to 1.250,8.975
1252 line from 1.250,8.975 to 1.613,8.963
1253 line from 1.613,8.963 to 2.312,8.988
1254 line from 2.312,8.988 to 3.025,9.037
1255 line from 3.025,9.037 to 3.725,9.062
1256 line from 3.725,9.062 to 4.438,9.100
1258 line dotted from 3.800,8.625 to 4.025,8.625
1259 line dotted from 1.250,9.312 to 1.250,9.312
1260 line dotted from 1.250,9.312 to 1.613,9.287
1261 line dotted from 1.613,9.287 to 2.312,9.675
1262 line dotted from 2.312,9.675 to 3.025,9.262
1263 line dotted from 3.025,9.262 to 3.725,9.738
1264 line dotted from 3.725,9.738 to 4.438,9.512
1265 line dashed from 3.800,8.475 to 4.025,8.475
1266 line dashed from 1.250,9.400 to 1.250,9.400
1267 line dashed from 1.250,9.400 to 1.613,9.287
1268 line dashed from 1.613,9.287 to 2.312,9.575
1269 line dashed from 2.312,9.575 to 3.025,9.300
1270 line dashed from 3.025,9.300 to 3.725,9.613
1271 line dashed from 3.725,9.613 to 4.438,9.512
1273 line dotted from 3.800,8.325 to 4.025,8.325
1274 line dotted from 1.250,9.400 to 1.250,9.400
1275 line dotted from 1.250,9.400 to 1.613,9.412
1276 line dotted from 1.613,9.412 to 2.312,9.700
1277 line dotted from 2.312,9.700 to 3.025,9.537
1278 line dotted from 3.025,9.537 to 3.725,9.938
1279 line dotted from 3.725,9.938 to 4.438,9.812
1284 "0" at 0.825,7.810 rjust
1285 "5" at 0.825,8.110 rjust
1286 "10" at 0.825,8.410 rjust
1287 "15" at 0.825,8.697 rjust
1288 "20" at 0.825,8.997 rjust
1289 "25" at 0.825,9.297 rjust
1290 "30" at 0.825,9.597 rjust
1291 "35" at 0.825,9.885 rjust
1292 "40" at 0.825,10.185 rjust
1299 "Time (sec)" at 0.150,8.997
1300 "Number of Clients" at 2.837,7.510
1301 "Figure #3: MAB Phase 3 (stat/find)" at 2.837,10.335
1302 "NFS" at 3.725,8.697 rjust
1303 "Leases" at 3.725,8.547 rjust
1304 "Leases, Rdirlookup" at 3.725,8.397 rjust
1305 "Leases, Attrib leases, Rdirlookup" at 3.725,8.247 rjust
1315 line dashed from 0.900,7.888 to 4.787,7.888
1316 line dashed from 0.900,7.888 to 0.900,10.262
1317 line from 0.900,7.888 to 0.963,7.888
1318 line from 4.787,7.888 to 4.725,7.888
1319 line from 0.900,8.188 to 0.963,8.188
1320 line from 4.787,8.188 to 4.725,8.188
1321 line from 0.900,8.488 to 0.963,8.488
1322 line from 4.787,8.488 to 4.725,8.488
1323 line from 0.900,8.775 to 0.963,8.775
1324 line from 4.787,8.775 to 4.725,8.775
1325 line from 0.900,9.075 to 0.963,9.075
1326 line from 4.787,9.075 to 4.725,9.075
1327 line from 0.900,9.375 to 0.963,9.375
1328 line from 4.787,9.375 to 4.725,9.375
1329 line from 0.900,9.675 to 0.963,9.675
1330 line from 4.787,9.675 to 4.725,9.675
1331 line from 0.900,9.963 to 0.963,9.963
1332 line from 4.787,9.963 to 4.725,9.963
1333 line from 0.900,10.262 to 0.963,10.262
1334 line from 4.787,10.262 to 4.725,10.262
1335 line from 0.900,7.888 to 0.900,7.950
1336 line from 0.900,10.262 to 0.900,10.200
1337 line from 1.613,7.888 to 1.613,7.950
1338 line from 1.613,10.262 to 1.613,10.200
1339 line from 2.312,7.888 to 2.312,7.950
1340 line from 2.312,10.262 to 2.312,10.200
1341 line from 3.025,7.888 to 3.025,7.950
1342 line from 3.025,10.262 to 3.025,10.200
1343 line from 3.725,7.888 to 3.725,7.950
1344 line from 3.725,10.262 to 3.725,10.200
1345 line from 4.438,7.888 to 4.438,7.950
1346 line from 4.438,10.262 to 4.438,10.200
1347 line from 0.900,7.888 to 4.787,7.888
1348 line from 4.787,7.888 to 4.787,10.262
1349 line from 4.787,10.262 to 0.900,10.262
1350 line from 0.900,10.262 to 0.900,7.888
1351 line from 3.800,8.775 to 4.025,8.775
1352 line from 1.250,9.412 to 1.250,9.412
1353 line from 1.250,9.412 to 1.613,9.425
1354 line from 1.613,9.425 to 2.312,9.463
1355 line from 2.312,9.463 to 3.025,9.600
1356 line from 3.025,9.600 to 3.725,9.875
1357 line from 3.725,9.875 to 4.438,10.075
1359 line dotted from 3.800,8.625 to 4.025,8.625
1360 line dotted from 1.250,9.450 to 1.250,9.450
1361 line dotted from 1.250,9.450 to 1.613,9.438
1362 line dotted from 1.613,9.438 to 2.312,9.438
1363 line dotted from 2.312,9.438 to 3.025,9.525
1364 line dotted from 3.025,9.525 to 3.725,9.550
1365 line dotted from 3.725,9.550 to 4.438,9.662
1366 line dashed from 3.800,8.475 to 4.025,8.475
1367 line dashed from 1.250,9.438 to 1.250,9.438
1368 line dashed from 1.250,9.438 to 1.613,9.412
1369 line dashed from 1.613,9.412 to 2.312,9.450
1370 line dashed from 2.312,9.450 to 3.025,9.500
1371 line dashed from 3.025,9.500 to 3.725,9.613
1372 line dashed from 3.725,9.613 to 4.438,9.675
1374 line dotted from 3.800,8.325 to 4.025,8.325
1375 line dotted from 1.250,9.387 to 1.250,9.387
1376 line dotted from 1.250,9.387 to 1.613,9.600
1377 line dotted from 1.613,9.600 to 2.312,9.625
1378 line dotted from 2.312,9.625 to 3.025,9.738
1379 line dotted from 3.025,9.738 to 3.725,9.850
1380 line dotted from 3.725,9.850 to 4.438,9.800
1385 "0" at 0.825,7.810 rjust
1386 "5" at 0.825,8.110 rjust
1387 "10" at 0.825,8.410 rjust
1388 "15" at 0.825,8.697 rjust
1389 "20" at 0.825,8.997 rjust
1390 "25" at 0.825,9.297 rjust
1391 "30" at 0.825,9.597 rjust
1392 "35" at 0.825,9.885 rjust
1393 "40" at 0.825,10.185 rjust
1400 "Time (sec)" at 0.150,8.997
1401 "Number of Clients" at 2.837,7.510
1402 "Figure #4: MAB Phase 4 (grep/wc/find)" at 2.837,10.335
1403 "NFS" at 3.725,8.697 rjust
1404 "Leases" at 3.725,8.547 rjust
1405 "Leases, Rdirlookup" at 3.725,8.397 rjust
1406 "Leases, Attrib leases, Rdirlookup" at 3.725,8.247 rjust
1416 line dashed from 0.900,7.888 to 4.787,7.888
1417 line dashed from 0.900,7.888 to 0.900,10.262
1418 line from 0.900,7.888 to 0.963,7.888
1419 line from 4.787,7.888 to 4.725,7.888
1420 line from 0.900,8.150 to 0.963,8.150
1421 line from 4.787,8.150 to 4.725,8.150
1422 line from 0.900,8.412 to 0.963,8.412
1423 line from 4.787,8.412 to 4.725,8.412
1424 line from 0.900,8.675 to 0.963,8.675
1425 line from 4.787,8.675 to 4.725,8.675
1426 line from 0.900,8.938 to 0.963,8.938
1427 line from 4.787,8.938 to 4.725,8.938
1428 line from 0.900,9.213 to 0.963,9.213
1429 line from 4.787,9.213 to 4.725,9.213
1430 line from 0.900,9.475 to 0.963,9.475
1431 line from 4.787,9.475 to 4.725,9.475
1432 line from 0.900,9.738 to 0.963,9.738
1433 line from 4.787,9.738 to 4.725,9.738
1434 line from 0.900,10.000 to 0.963,10.000
1435 line from 4.787,10.000 to 4.725,10.000
1436 line from 0.900,10.262 to 0.963,10.262
1437 line from 4.787,10.262 to 4.725,10.262
1438 line from 0.900,7.888 to 0.900,7.950
1439 line from 0.900,10.262 to 0.900,10.200
1440 line from 1.613,7.888 to 1.613,7.950
1441 line from 1.613,10.262 to 1.613,10.200
1442 line from 2.312,7.888 to 2.312,7.950
1443 line from 2.312,10.262 to 2.312,10.200
1444 line from 3.025,7.888 to 3.025,7.950
1445 line from 3.025,10.262 to 3.025,10.200
1446 line from 3.725,7.888 to 3.725,7.950
1447 line from 3.725,10.262 to 3.725,10.200
1448 line from 4.438,7.888 to 4.438,7.950
1449 line from 4.438,10.262 to 4.438,10.200
1450 line from 0.900,7.888 to 4.787,7.888
1451 line from 4.787,7.888 to 4.787,10.262
1452 line from 4.787,10.262 to 0.900,10.262
1453 line from 0.900,10.262 to 0.900,7.888
1454 line from 3.800,8.675 to 4.025,8.675
1455 line from 1.250,8.800 to 1.250,8.800
1456 line from 1.250,8.800 to 1.613,8.912
1457 line from 1.613,8.912 to 2.312,9.113
1458 line from 2.312,9.113 to 3.025,9.438
1459 line from 3.025,9.438 to 3.725,9.750
1460 line from 3.725,9.750 to 4.438,10.088
1462 line dotted from 3.800,8.525 to 4.025,8.525
1463 line dotted from 1.250,8.637 to 1.250,8.637
1464 line dotted from 1.250,8.637 to 1.613,8.700
1465 line dotted from 1.613,8.700 to 2.312,8.713
1466 line dotted from 2.312,8.713 to 3.025,8.775
1467 line dotted from 3.025,8.775 to 3.725,8.887
1468 line dotted from 3.725,8.887 to 4.438,9.037
1469 line dashed from 3.800,8.375 to 4.025,8.375
1470 line dashed from 1.250,8.675 to 1.250,8.675
1471 line dashed from 1.250,8.675 to 1.613,8.688
1472 line dashed from 1.613,8.688 to 2.312,8.713
1473 line dashed from 2.312,8.713 to 3.025,8.825
1474 line dashed from 3.025,8.825 to 3.725,8.887
1475 line dashed from 3.725,8.887 to 4.438,9.062
1477 line dotted from 3.800,8.225 to 4.025,8.225
1478 line dotted from 1.250,8.700 to 1.250,8.700
1479 line dotted from 1.250,8.700 to 1.613,8.688
1480 line dotted from 1.613,8.688 to 2.312,8.762
1481 line dotted from 2.312,8.762 to 3.025,8.812
1482 line dotted from 3.025,8.812 to 3.725,8.925
1483 line dotted from 3.725,8.925 to 4.438,9.025
1488 "0" at 0.825,7.810 rjust
1489 "50" at 0.825,8.072 rjust
1490 "100" at 0.825,8.335 rjust
1491 "150" at 0.825,8.597 rjust
1492 "200" at 0.825,8.860 rjust
1493 "250" at 0.825,9.135 rjust
1494 "300" at 0.825,9.397 rjust
1495 "350" at 0.825,9.660 rjust
1496 "400" at 0.825,9.922 rjust
1497 "450" at 0.825,10.185 rjust
1504 "Time (sec)" at 0.150,8.997
1505 "Number of Clients" at 2.837,7.510
1506 "Figure #5: MAB Phase 5 (compile)" at 2.837,10.335
1507 "NFS" at 3.725,8.597 rjust
1508 "Leases" at 3.725,8.447 rjust
1509 "Leases, Rdirlookup" at 3.725,8.297 rjust
1510 "Leases, Attrib leases, Rdirlookup" at 3.725,8.147 rjust
1516 In figure 2, where a subtree of seventy small files is copied, the difference between the protocol variants is minimal,
1517 with the NQNFS variants performing slightly better.
1518 For this case, the Readdir_and_Lookup RPC is a slight hindrance under heavy
1519 load, possibly because it results in larger directory blocks in the buffer
1522 In figure 3, for the phase that gets file attributes for a large number
1523 of files, the leasing variants take about 50% longer, indicating that
1524 there are performance problems in this area. For the case where valid
1525 current leases are required for every file when attributes are returned,
1526 the performance is significantly worse than when the attributes are allowed
1527 to be stale by a few seconds on the client.
1528 I have not been able to explain the oscillation in the curves for the
1531 For the string searching phase depicted in figure 4, the leasing variants
1532 that do not require valid leases for files when attributes are returned
1533 appear to scale better with server load than NFS.
1534 However, the effect appears to be
1535 negligible until the server load is fairly heavy.
1537 Most of the time in the MAB benchmark is spent in the compilation phase
1538 and this is where the differences between caching methods are most
1540 In figure 5 it can be seen that any protocol variant using Leases performs
1541 about a factor of two better than NFS
1542 at a load of ten clients. This indicates that the use of NQNFS may
1543 allow servers to handle significantly more clients for this type of
1546 Table 2 summarizes the MAB run times for all phases for the single client
1547 DECstation 5000/25. The \fILeases\fR case refers to using leases, whereas
1548 the \fILeases, Rdirl\fR case uses the Readdir_and_Lookup RPC as well and
1549 the \fIBCache Only\fR case uses leases, but only the buffer cache and not
1550 the attribute or name caches.
1551 The \fINo Caching\fR cases does not do any client side caching, performing
1552 all system calls via synchronous RPCs to the server.
1561 Table #2: Single DECstation 5000/25 Client Elapsed Times (sec)
1562 Phase 1 2 3 4 5 Total % Improvement
1564 No Caching 6 35 41 40 258 380 -93
1565 NFS 5 24 15 20 133 197 0
1566 BCache Only 5 20 24 23 116 188 5
1567 Leases, Rdirl 5 20 21 20 105 171 13
1568 Leases 5 19 21 21 99 165 16
1572 .sh 2 "Processor Speed Tests"
1574 An important goal of client-side file system caching is to decouple the
1575 I/O system calls from the underlying distributed file system, so that the
1576 client's system performance might scale with processor speed. In order
1577 to test this, a series of MAB runs were performed on three
1578 DECstations that are similar except for processor speed.
1579 In addition to the four protocol variants used for the above tests, runs
1580 were done with the client caches turned off, for
1581 worst case performance numbers for caching mechanisms with a 100% miss rate. The CPU utilization
1582 was measured, as an indicator of how much the processor was blocking for
1583 I/O system calls. Note that since the systems were running in single user mode
1584 and otherwise quiescent, almost all CPU activity was directly related
1586 The results are presented in
1588 The CPU time is simply the product of the CPU utilization and
1589 elapsed running time and, as such, is the optimistic bound on performance
1590 achievable with an ideal client caching scheme that never blocks for I/O.
1600 l | n n n n n n n n n.
1601 Table #3: MAB Phase 5 (compile)
1602 DS2100 (10.5 MIPS) DS3100 (14.0 MIPS) DS5000/25 (26.7 MIPS)
1603 Elapsed CPU CPU Elapsed CPU CPU Elapsed CPU CPU
1604 time Util(%) time time Util(%) time time Util(%) time
1606 Leases 143 89 127 113 87 98 99 89 88
1607 Leases, Rdirl 150 89 134 110 91 100 105 88 92
1608 BCache Only 169 85 144 129 78 101 116 75 87
1609 NFS 172 77 132 135 74 100 133 71 94
1610 No Caching 330 47 155 256 41 105 258 39 101
1614 As can be seen in the table, any caching mechanism achieves significantly
1615 better performance than when caching is disabled, roughly doubling the CPU
1616 utilization with a corresponding reduction in run time. For NFS, the CPU
1617 utilization is dropping with increase in CPU speed, which would suggest that
1618 it is not scaling with CPU speed. For the NQNFS variants, the CPU utilization
1619 remains at just below 90%, which suggests that the caching mechanism is working
1620 well and scaling within this CPU range.
1621 Note that for this benchmark, the ratio of CPU times for
1622 the DECstation 3100 and DECstation 5000/25 are quite different than the
1623 Dhrystone MIPS ratings would suggest.
1625 Overall, the results seem encouraging, although it remains to be seen whether
1626 or not the caching provided by NQNFS can continue to scale with CPU
1628 There is a good indication that NQNFS permits a server to scale
1629 to more clients than does NFS, at least for workloads akin to the MAB compile phase.
1630 A more difficult question is "What if the server is much faster doing
1631 write RPCs?" as a result of some technology such as Prestoserve
1633 Since a significant part of the difference between NFS and NQNFS is
1634 the synchronous writing, it is difficult to predict how much a server
1635 capable of fast write RPCs will negate the performance improvements of NQNFS.
1636 At the very least, table 1 indicates that the write RPC load on the server
1637 has decreased by approximately 30%, and this reduced write load should still
1638 result in some improvement.
1640 Indications are that the Readdir_and_Lookup RPC has not improved performance
1641 for these tests and may in fact be degrading performance slightly.
1642 The results in figure 3 indicate some problems, possibly with handling
1643 of the attribute cache. It seems logical that the Readdir_and_Lookup RPC
1644 should be permit priming of the attribute cache improving hit rate, but the
1645 results are counter to that.
1646 .sh 2 "Internetwork Delay Tests"
1648 This experimental setup was used to explore how the different protocol
1649 variants might perform over internetworks with larger RPC RTTs. The
1650 server was moved to a separate Ethernet, using a MicroVAXII\(tm as an
1651 IP router to the other Ethernet. The 4.3Reno BSD Unix system running on the
1652 MicroVAXII was modified to delay IP packets being forwarded by a tunable N
1653 millisecond delay. The implementation was rather crude and did not try to
1654 simulate a distribution of delay times nor was it programmed to drop packets
1655 at a given rate, but it served as a simple emulation of a long,
1656 fat network\** [Jacobson88].
1658 \**Long fat networks refer to network interconnections with
1659 a Bandwidth X RTT product > 10\u5\d bits.
1661 The MAB was run using both UDP and TCP RPC transports
1662 for a variety of RTT delays from five to two hundred milliseconds,
1663 to observe the effects of RTT delay on RPC transport.
1664 It was found that, due to a high variability between runs, four runs was not
1665 suffice, so eight runs at each value was done.
1666 The results in figure 6 and table 4 are the average for the eight runs.
1672 line dashed from 0.900,7.888 to 4.787,7.888
1673 line dashed from 0.900,7.888 to 0.900,10.262
1674 line from 0.900,7.888 to 0.963,7.888
1675 line from 4.787,7.888 to 4.725,7.888
1676 line from 0.900,8.350 to 0.963,8.350
1677 line from 4.787,8.350 to 4.725,8.350
1678 line from 0.900,8.800 to 0.963,8.800
1679 line from 4.787,8.800 to 4.725,8.800
1680 line from 0.900,9.262 to 0.963,9.262
1681 line from 4.787,9.262 to 4.725,9.262
1682 line from 0.900,9.713 to 0.963,9.713
1683 line from 4.787,9.713 to 4.725,9.713
1684 line from 0.900,10.175 to 0.963,10.175
1685 line from 4.787,10.175 to 4.725,10.175
1686 line from 0.900,7.888 to 0.900,7.950
1687 line from 0.900,10.262 to 0.900,10.200
1688 line from 1.825,7.888 to 1.825,7.950
1689 line from 1.825,10.262 to 1.825,10.200
1690 line from 2.750,7.888 to 2.750,7.950
1691 line from 2.750,10.262 to 2.750,10.200
1692 line from 3.675,7.888 to 3.675,7.950
1693 line from 3.675,10.262 to 3.675,10.200
1694 line from 4.600,7.888 to 4.600,7.950
1695 line from 4.600,10.262 to 4.600,10.200
1696 line from 0.900,7.888 to 4.787,7.888
1697 line from 4.787,7.888 to 4.787,10.262
1698 line from 4.787,10.262 to 0.900,10.262
1699 line from 0.900,10.262 to 0.900,7.888
1700 line from 4.125,8.613 to 4.350,8.613
1701 line from 0.988,8.400 to 0.988,8.400
1702 line from 0.988,8.400 to 1.637,8.575
1703 line from 1.637,8.575 to 2.375,8.713
1704 line from 2.375,8.713 to 3.125,8.900
1705 line from 3.125,8.900 to 3.862,9.137
1706 line from 3.862,9.137 to 4.600,9.425
1708 line dotted from 4.125,8.463 to 4.350,8.463
1709 line dotted from 0.988,8.375 to 0.988,8.375
1710 line dotted from 0.988,8.375 to 1.637,8.525
1711 line dotted from 1.637,8.525 to 2.375,8.850
1712 line dotted from 2.375,8.850 to 3.125,8.975
1713 line dotted from 3.125,8.975 to 3.862,9.137
1714 line dotted from 3.862,9.137 to 4.600,9.625
1715 line dashed from 4.125,8.312 to 4.350,8.312
1716 line dashed from 0.988,8.525 to 0.988,8.525
1717 line dashed from 0.988,8.525 to 1.637,8.688
1718 line dashed from 1.637,8.688 to 2.375,8.838
1719 line dashed from 2.375,8.838 to 3.125,9.150
1720 line dashed from 3.125,9.150 to 3.862,9.275
1721 line dashed from 3.862,9.275 to 4.600,9.588
1723 line dotted from 4.125,8.162 to 4.350,8.162
1724 line dotted from 0.988,8.525 to 0.988,8.525
1725 line dotted from 0.988,8.525 to 1.637,8.838
1726 line dotted from 1.637,8.838 to 2.375,8.863
1727 line dotted from 2.375,8.863 to 3.125,9.137
1728 line dotted from 3.125,9.137 to 3.862,9.387
1729 line dotted from 3.862,9.387 to 4.600,10.200
1734 "0" at 0.825,7.810 rjust
1735 "100" at 0.825,8.272 rjust
1736 "200" at 0.825,8.722 rjust
1737 "300" at 0.825,9.185 rjust
1738 "400" at 0.825,9.635 rjust
1739 "500" at 0.825,10.097 rjust
1742 "100" at 2.750,7.660
1743 "150" at 3.675,7.660
1744 "200" at 4.600,7.660
1745 "Time (sec)" at 0.150,8.997
1746 "Round Trip Delay (msec)" at 2.837,7.510
1747 "Figure #6: MAB Phase 5 (compile)" at 2.837,10.335
1748 "Leases,UDP" at 4.050,8.535 rjust
1749 "Leases,TCP" at 4.050,8.385 rjust
1750 "NFS,UDP" at 4.050,8.235 rjust
1751 "NFS,TCP" at 4.050,8.085 rjust
1765 l | n n n n n n n n.
1766 Table #4: MAB Phase 5 (compile) for Internetwork Delays
1767 NFS,UDP NFS,TCP Leases,UDP Leases,TCP
1768 Delay Elapsed Standard Elapsed Standard Elapsed Standard Elapsed Standard
1769 (msec) time (sec) Deviation time (sec) Deviation time (sec) Deviation time (sec) Deviation
1771 5 139 2.9 139 2.4 112 7.0 108 6.0
1772 40 175 5.1 208 44.5 150 23.8 139 4.3
1773 80 207 3.9 213 4.7 180 7.7 210 52.9
1774 120 276 29.3 273 17.1 221 7.7 238 5.8
1775 160 304 7.2 328 77.1 275 21.5 274 10.1
1776 200 372 35.0 506 235.1 338 25.2 379 69.2
1781 I found these results somewhat surprising, since I had assumed that stability
1782 across an internetwork connection would be a function of RPC transport
1784 Looking at the standard deviations observed between the eight runs, there is an indication
1785 that the NQNFS protocol plays a larger role in
1786 maintaining stability than the underlying RPC transport protocol.
1787 It appears that NFS over TCP transport
1788 is the least stable variant tested.
1789 It should be noted that the TCP implementation used was roughly at 4.3BSD Tahoe
1790 release and that the 4.4BSD TCP implementation was far less stable and would
1791 fail intermittently, due to a bug I was not able to isolate.
1792 It would appear that some of the recent enhancements to the 4.4BSD TCP
1793 implementation have a detrimental effect on the performance of
1794 RPC-type traffic loads, which intermix small and large
1795 data transfers in both directions.
1796 It is obvious that more exploration of this area is needed before any
1797 conclusions can be made
1798 beyond the fact that over a local area network, TCP transport provides
1799 performance comparable to UDP.
1800 .sh 1 "Lessons Learned"
1802 Evaluating the performance of a distributed file system is fraught with
1803 difficulties, due to the many software and hardware factors involved.
1804 The limited benchmarking presented here took a considerable amount of time
1805 and the results gained by the exercise only give indications of what the
1806 performance might be for a few scenarios.
1808 The IP router with delay introduction proved to be a valuable tool for protocol debugging\**,
1810 \**It exposed two bugs in the 4.4BSD networking, one a problem in the Lance chip
1811 driver for the DECstation and the other a TCP window sizing problem that I was
1812 not able to isolate.
1814 and may be useful for a more extensive study of performance over internetworks
1815 if enhanced to do a better job of simulating internetwork delay and packet loss.
1817 The Leases mechanism provided a simple model for the provision of cache
1818 consistency and did seem to improve performance for various scenarios.
1819 Unfortunately, it does not provide the server state information that is required
1820 for file system semantics, such as locking, that many software systems demand.
1821 In production environments on my campus, the need for file locking and the correct
1822 generation of the ETXTBSY error code
1823 are far more important that full cache consistency, and leasing
1824 does not satisfy these needs.
1825 Another file system semantic that requires hard server state is the delay
1826 of file removal until the last close system call. Although Spritely NFS
1827 did not support this semantic either, it is logical that the open file
1828 state maintained by that system would facilitate the implementation of
1829 this semantic more easily than would the Leases mechanism.
1830 .sh 1 "Further Work"
1832 The current implementation uses a fixed, moderate sized buffer cache designed
1833 for the local UFS [McKusick84] file system.
1834 The results in figure 1 suggest that this is adequate so long as the cache
1835 is of an appropriate size.
1836 However, a mechanism permitting the cache to vary in size
1837 has been shown to outperform fixed sized buffer caches [Nelson90], and could
1838 be beneficial. It could also be useful to allow the buffer cache to grow very
1839 large by making use of local backing store for cases where server performance
1841 A very large buffer cache size would in turn permit experimentation with
1842 much larger read/write data sizes, facilitating bulk data transfers
1843 across long fat networks, such as will characterize the Internet of the
1845 A careful redesign of the buffer cache mechanism to provide
1846 support for these features would probably be the next implementation step.
1848 The results in figure 3 indicate that the mechanics of caching file
1849 attributes and maintaining the attribute cache's consistency needs to
1850 be looked at further.
1851 There also needs to be more work done on the interaction between a
1852 Readdir_and_Lookup RPC and the name and attribute caches, in an effort
1853 to reduce Getattr and Lookup RPC loads.
1855 The NQNFS protocol has never been used in a production environment and doing
1856 so would provide needed insight into how well the protocol saisfies the
1857 needs of real workstation environments.
1858 It is hoped that the distribution of the implementation in 4.4BSD will
1859 facilitate use of the protocol in production environments elsewhere.
1861 The big question that needs to be resolved is whether Leases are an adequate
1862 mechanism for cache consistency or whether hard server state is required.
1863 Given the work presented here and in the papers related to Sprite and Spritely
1864 NFS, there are clear indications that a cache consistency algorithm can
1865 improve both performance and file system semantics.
1866 As yet, however, it is unclear what the best approach to maintain consistency is.
1867 It would appear that hard state information is required for file locking and
1868 other mechanisms and, if so, it seems appropriate to use it for cache
1869 consistency as well.
1870 .sh 1 "Acknowledgements"
1872 I would like to thank the members of the CSRG at the University of California,
1873 Berkeley for their continued support over the years. Without their encouragement and assistance this
1874 software would never have been implemented.
1875 Prof. Jim Linders and Prof. Tom Wilson here at the University of Guelph helped
1876 proofread this paper and Jeffrey Mogul provided a great deal of
1877 assistance, helping to turn my gibberish into something at least moderately
1881 Mary Baker and John Ousterhout, Availability in the Sprite Distributed
1882 File System, In \fIOperating System Review\fR, (25)2, pg. 95-98,
1885 Mary Baker, private communication, May 1991.
1887 Michael Burrows, Efficient Data Sharing, Technical Report #153,
1888 Computer Laboratory, University of Cambridge, Dec. 1988.
1890 Cary G. Gray and David R. Cheriton, Leases: An Efficient Fault-Tolerant
1891 Mechanism for Distributed File Cache Consistency, In \fIProc. of the
1892 Twelfth ACM Symposium on Operating Systems Principals\fR, Litchfield Park,
1895 John H. Howard, Michael L. Kazar, Sherri G. Menees, David A. Nichols,
1896 M. Satyanarayanan, Robert N. Sidebotham and Michael J. West,
1897 Scale and Performance in a Distributed File System, \fIACM Trans. on
1898 Computer Systems\fR, (6)1, pg 51-81, Feb. 1988.
1900 Van Jacobson and R. Braden, \fITCP Extensions for Long-Delay Paths\fR,
1901 ARPANET Working Group Requests for Comment, DDN Network Information Center,
1902 SRI International, Menlo Park, CA, October 1988, RFC-1072.
1904 Van Jacobson, Sun NFS Performance Problems, \fIPrivate Communication,\fR
1907 Chet Juszczak, Improving the Performance and Correctness of an NFS Server,
1908 In \fIProc. Winter 1989 USENIX Conference,\fR pg. 53-63, San Diego, CA, January 1989.
1910 Chet Juszczak, Improving the Write Performance of an NFS Server,
1911 to appear in \fIProc. Winter 1994 USENIX Conference,\fR San Francisco, CA, January 1994.
1913 Michael L. Kazar, Synchronization and Caching Issues in the Andrew File System,
1914 In \fIProc. Winter 1988 USENIX Conference,\fR pg. 27-36, Dallas, TX, February
1917 Christopher. A. Kent and Jeffrey C. Mogul, \fIFragmentation Considered Harmful\fR, Research Report 87/3,
1918 Digital Equipment Corporation Western Research Laboratory, Dec. 1987.
1920 Christopher. A. Kent, \fICache Coherence in Distributed Systems\fR, Research Report 87/4,
1921 Digital Equipment Corporation Western Research Laboratory, April 1987.
1923 Rick Macklem, Lessons Learned Tuning the 4.3BSD Reno Implementation of the
1925 In \fIProc. Winter 1991 USENIX Conference,\fR pg. 53-64, Dallas, TX,
1928 Rick Macklem, The 4.4BSD NFS Implementation,
1929 In \fIThe System Manager's Manual\fR, 4.4 Berkeley Software Distribution,
1930 University of California, Berkeley, June 1993.
1932 Marshall K. McKusick, William N. Joy, Samuel J. Leffler and Robert S. Fabry,
1933 A Fast File System for UNIX, \fIACM Transactions on Computer Systems\fR,
1934 Vol. 2, Number 3, pg. 181-197, August 1984.
1936 Marshall K. McKusick, Michael J. Karels and Keith Bostic, A Pageable Memory
1938 In \fIProc. Summer 1990 USENIX Conference,\fR pg. 137-143, Anaheim, CA, June
1941 Jeffrey C. Mogul, Recovery in Spritely NFS,
1942 Research Report 93/2, Digital Equipment Corporation Western Research
1943 Laboratory, June 1993.
1945 Joseph Moran, Russel Sandberg, Don Coleman, Jonathan Kepecs and Bob Lyon,
1946 Breaking Through the NFS Performance Barrier,
1947 In \fIProc. Spring 1990 EUUG Conference,\fR pg. 199-206, Munich, FRG,
1950 Michael N. Nelson, Brent B. Welch, and John K. Ousterhout, Caching in the
1951 Sprite Network File System, \fIACM Transactions on Computer Systems\fR (6)1
1952 pg. 134-154, February 1988.
1954 Michael N. Nelson, \fIVirtual Memory vs. The File System\fR, Research Report
1955 90/4, Digital Equipment Corporation Western Research Laboratory, March 1990.
1957 Bill Nowicki, Transport Issues in the Network File System, In \fIComputer
1958 Communication Review\fR, pg. 16-20, March 1989.
1959 .ip [Ousterhout90] 15
1960 John K. Ousterhout, Why Aren't Operating Systems Getting Faster As Fast as
1961 Hardware? In \fIProc. Summer 1990 USENIX Conference\fR, pg. 247-256, Anaheim,
1964 Russel Sandberg, David Goldberg, Steve Kleiman, Dan Walsh, and Bob Lyon,
1965 Design and Implementation of the Sun Network filesystem, In \fIProc. Summer
1966 1985 USENIX Conference\fR, pages 119-130, Portland, OR, June 1985.
1967 .ip [Srinivasan89] 15
1968 V. Srinivasan and Jeffrey. C. Mogul, Spritely NFS: Experiments with
1969 Cache-Consistency Protocols,
1971 Twelfth ACM Symposium on Operating Systems Principals\fR, Litchfield Park,
1974 J. G. Steiner, B. C. Neuman and J. I. Schiller, Kerberos: An Authentication
1975 Service for Open Network Systems,
1976 In \fIProc. Winter 1988 USENIX Conference,\fR pg. 191-202, Dallas, TX, February
1979 Sun Microsystems Inc., \fINFS: Network File System Protocol Specification\fR,
1980 ARPANET Working Group Requests for Comment, DDN Network Information Center,
1981 SRI International, Menlo Park, CA, March 1989, RFC-1094.
1983 Sun Microsystems Inc., \fINFS: Network File System Version 3 Protocol Specification\fR,
1984 Sun Microsystems Inc., Mountain View, CA, June 1993.
1986 Mark Wittle and Bruce E. Keith, LADDIS: The Next Generation in NFS File
1987 Server Benchmarking,
1988 In \fIProc. Summer 1993 USENIX Conference,\fR pg. 111-128, Cincinnati, OH, June
1992 NFS is believed to be a trademark of Sun Microsystems, Inc.
1996 Prestoserve is a trademark of Legato Systems, Inc.
2000 MIPS is a trademark of Silicon Graphics, Inc.
2004 DECstation, MicroVAXII and Ultrix are trademarks of Digital Equipment Corp.
2008 Unix is a trademark of Novell, Inc.