Subject: Re: Extension of fsync_range() to permit forcing disk cache flushing
To: Manuel Bouyer <bouyer@antioche.lip6.fr>
From: Thor Lancelot Simon <tls@rek.tjls.com>
List: tech-kern
Date: 12/17/2004 07:24:46
On Fri, Dec 17, 2004 at 10:08:48AM +0100, Manuel Bouyer wrote:
> 
> I'm not really happy with this. IMHO this should be the default behavior of
> fsync(). A programmer using fsync in his software uses it to make use data
> is on stable storage.

The problem is that syncing 1K of data from one file could cause an
entire 8MB cache to be written back (in fact, on an IDE disk, *will*
cause that).  Some applications "defensively" call fsync on every write;
think what that will do to overall system performance.

-- 
 Thor Lancelot Simon	                                      tls@rek.tjls.com

"The inconsistency is startling, though admittedly, if consistency is to be
 abandoned or transcended, there is no problem."		- Noam Chomsky