home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / os / vms / 19980 < prev    next >
Encoding:
Internet Message Format  |  1992-12-29  |  1.7 KB

  1. Path: sparky!uunet!cs.utexas.edu!sun-barr!sh.wide!wnoc-tyo-news!sranha!anprda!akira
  2. From: akira@atson.asahi-np.co.jp (Akira Takiguchi)
  3. Newsgroups: comp.os.vms
  4. Subject: Re: flushing in VAXC and DECC
  5. Message-ID: <3088@anprda.atson.asahi-np.co.jp>
  6. Date: 29 Dec 92 00:11:31 GMT
  7. References: <1hjtr9INN34t@gap.caltech.edu> <1992Dec27.200611.24473@nntpd2.cxo.dec.com> <1hn91uINNnna@gap.caltech.edu>
  8. Organization: ATSON, Inc. (a subsidiary of the Asahi Shimbun)
  9. Lines: 31
  10.  
  11. In article <1hn91uINNnna@gap.caltech.edu> carl@SOL1.GPS.CALTECH.EDU writes:
  12. >And,
  13. >byt the way, despite the claim by another person, the program:
  14. >
  15. >#include stdio
  16. >main()
  17. >{    int fd;
  18. >    fd = creat("TEST.DAT");
  19.                          ,0600);
  20. >    write(fd, "This is a test.\n", 16);
  21. >    fsync(fd);
  22. >    sleep(30);
  23. >}
  24. >
  25. >Also exhibits exactly the same behavior.
  26.  
  27.      Thanks for pointing this out.  I believe this is (one of) the reason
  28. why fsync() was undocumented.  Since it's documented now in AXP manual,
  29. doesn't this example work as expected on AXP machines?  (I guess Paul used
  30. AXP machines for testing?)
  31.  
  32.      Anyway, this does not invalidate my argument.  Since fsync is named
  33. after the unix function (though actual semantics is quite different;  as
  34. you know, on unix "written" data are immediatedly shared among processes.
  35. Fsync() merely guarantees the data is on disk and can be considered safe
  36. from crash), it should reasonably imitate unix behaviour - no wonder you
  37. need fflush() before fsync().
  38. -- 
  39.        Akira Takiguchi  at ATSON, Inc. (a subsidiary of the Asahi Shimbun)
  40.                    WAKO GINZA bldg.  8-10-4 Ginza Chuo-ku Tokyo 104  Japan
  41.    +81 3 3289 7051(voice) 7066(fax)  EMAIL TO <akira@atson.asahi-np.co.jp>
  42.