home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / comp / unix / wizards / 4575 < prev    next >
Encoding:
Internet Message Format  |  1992-11-09  |  2.2 KB

  1. Path: sparky!uunet!auspex-gw!mohan
  2. From: mohan@Auspex.COM (Mohan Srinivasan)
  3. Newsgroups: comp.unix.wizards
  4. Subject: Re: SUN NFS sync
  5. Keywords: sync
  6. Message-ID: <15402@auspex-gw.auspex.com>
  7. Date: 9 Nov 92 18:43:17 GMT
  8. References: <bharat.720655786@Xenon.Stanford.EDU> <1d1vksINN3d@playroom.rochester.East.Sun.COM> <15358@auspex-gw.auspex.com> <1992Nov6.223031.13503@netcom.com>
  9. Sender: news@auspex-gw.auspex.com
  10. Organization: Auspex Systems, Santa Clara
  11. Lines: 36
  12. Nntp-Posting-Host: osiris.auspex.com
  13.  
  14. In article <1992Nov6.223031.13503@netcom.com> netapp@netcom.com (Network Appliance) writes:
  15. >In article <15358@auspex-gw.auspex.com> guy@Auspex.COM (Guy Harris) writes:
  16. >>Umm, I don't think it was even the case in 3.x - or 2.x, for that matter
  17. >>- that NFS writes were synchronous on the client side.  
  18. >
  19. >Last time I checked, NFS writes were handled very differently in the
  20. >SunOS client code as compared with the client code that Sun distributes
  21. >to other UNIX vendors who buy NFS from Sun.
  22. >
  23. >In SunOS, the write(2) system call just dirties buffers in memory, and
  24. >expects biod's to do the writes when they are able.  In the
  25. >distributed NFS, the write(2) system call tries to schedule a biod to
  26. >immediately send the write, and if no biod is available, then the
  27. >process doing the write(2) does the send itself.
  28. >
  29.  
  30. Actually, even in SunOS (both 4.X and 5.X), if the write rounds up to a
  31. 8K chunk, the write is scheduled to the biod's immediately (ie. if there is
  32. a biod available, the write'ing process hands over the write to it. 
  33. Otherwise, if there's no free biod available, the write is done
  34. by the writing process itself - this is 4.x behavior, in 5.x an async
  35. write is always queued up to be picked up by the biod threads).
  36.  
  37. Scheduling the write is done by the function in the segmap driver code
  38. that releases the mapped (segkmap) segment. It calls VOP_PUTPAGE() with
  39. the flags that were passed to itself. (So, it handles cases like ASYNC,
  40. INVAL, DONTNEED etc).
  41.  
  42. However, you're right in that if the write is < 8k, then it just dirties
  43. the page(s).
  44.  
  45. -- 
  46. ===============================================================================
  47. Ram Mohan Srinivasan
  48. mohan@auspex.com
  49. ===============================================================================
  50.