On 05/08/11 09:22, Andrew Gabriel wrote:
Toby Thain wrote:
On 08/05/11 10:31 AM, Edward Ned Harvey wrote:
...
Incidentally, does fsync() and sync return instantly or wait? Cuz
"time
sync" might product 0 sec every time even if there were something
waiting to
be flushed to disk.
The semantics need to be synchronous. Anything else would be a
horrible bug.
sync(2) is not required to be synchronous.
I believe that for ZFS it is synchronous...
Indeed it is synchronous for zfs. Both sync(1)/sync(2) ensure that all
cached data and metadata at the time of the sync(2) call are written out
and stable before return from the call.
Neil.
_______________________________________________
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss