[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: sync writes - was Re: how to counteract slowdown

On Wednesday November 14, akpm zip com au wrote:
> I think your numbers fail to account for request
> merging?  A write of 40000 bytes to a data=journal
> fs should result in two requests at the SCSI layer,
> and that's what you (sometimes) get.

Certainly.  I'm expecting that a sync write of any variety will
produce 2 writes.  To the journal it would be the transation and the
commit.  To the filesystem (e.g. ext2) it would be the data and the
Where double syncing in happening (e.g. -o sync and fsync) then it
might be 3 or 4 writes.

> > ...
> > ext3 sync,data=journal
> >      async         0  200       sync mount option now honoured!
> >      fsync         0  300
> These need thinking about.

These ones make sense to me.
On the "async" line, each write() causes two writes to the journal
(transation plus commit) thus 200 in total.
On the "fsync" line, each write still causes 2 writes, but the fsync
causes another commit block (is that likely) hence 3 writes for the

> >      osync         0    2       but O_SYNC negates effect of -o sync!!
> That's expected - one request is the data+metadata into the
> journal.  The other is the commit block.

This is with "-o sync" and O_SYNC and 100 distinct writes.
Each write should be written to disc before it returns, so that is a
minimum of 100 writes expected.  Actually I would expect 200 for
above reasons.


> _______________________________________________
> Ext3-users mailing list
> Ext3-users redhat com
> https://listman.redhat.com/mailman/listinfo/ext3-users

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]