Re: More on 2.1.65 slowdown (disc thrashing)

Alan Cox (
Fri, 21 Nov 1997 16:10:43 +0000 (GMT)

> > fsync ( fileno (fp) );
> IIRC the fsync() function in ext2 was changed into a plain sync(). The
> reason for this is that fsync() was extremely slow on large files, much
> slower than a full sync would be.
> Perhaps the decision to sync or fsync could be made on the basis of the
> file size?

When I played with that for 2.0 the break point seems to between about 1 and
3Mbytes depending on RAM, disks etc. fsync is normally done on small files
so it would be good to handle it nicely