On Fri, Joerg Schilling wrote: > Spencer Shepler <[EMAIL PROTECTED]> wrote: > > > Sorry, the code in Solaris would behave as I described. Upon the > > application closing the file, modified data is written to the server. > > The client waits for completion of those writes. If there is an error, > > it is returned to the caller of close(). > > So is this Solaris specific, or why are people warned to depend on the close() > return code only?
All unix NFS clients that I know of behave the way I described. I believe the warning about relying on close() is that by the time the application receives the error it is too late to recover. If the application uses fsync() and receives an error, the application can warn the user and they may be able to do something about it (your example of ENOSPC is a very good one). Space can be freed, and the fsync() can be done again and the client will again push the writes to the server and be successful. If an application doesn't care about recovery but wants the error to report back to the user, then close() is sufficient. Spencer _______________________________________________ zfs-discuss mailing list zfs-discuss@opensolaris.org http://mail.opensolaris.org/mailman/listinfo/zfs-discuss