From: Mathis Ahrens <Mathis.Ahrens@gmx.de>
To: Chris Mason <mason@suse.com>
Cc: Andrew Morton <akpm@osdl.org>,
col-pepper@piments.com, linux-kernel@vger.kernel.org
Subject: Re: o_sync in vfat driver
Date: Wed, 29 Mar 2006 04:13:03 +0200 [thread overview]
Message-ID: <4429ED2F.10407@gmx.de> (raw)
In-Reply-To: <200602281347.46169.mason@suse.com>
Hi all,
Chris Mason wrote:
> On Monday 27 February 2006 18:12, Andrew Morton wrote:
>
>> We don't know that the same number of same-sized write()s were happening in
>> each case.
>>
>> There's been some talk about implementing fsync()-on-file-close for this
>> problem, and some protopatches. But nothing final yet.
>>
>
> Here's the patch I'm using in -suse right now. What I want to do is make a
> much more generic -o flush, but it'll still need a few bits in individual
> filesystem to kick off metadata writes quickly.
>
> The basic goal behind the code is to trigger writes without waiting for both
> data and metadata. If the user is watching the memory stick, when the
> little light stops flashing all the data and metadata will be on disk.
>
> It also generally throttles userland a little during file release. This
> could be changed to throttle for each page dirtied, but most users I
> asked liked the current setup better.
>
I like the idea and would like to see something like this in mainline.
Here is some non-scientific benchmark done with 2.6.16, comparing
default mount and flush mount of a USB2 stick:
/////////////////////////////////////////////////////////////////////
Single File "Test": 43MB
$ time cp Test /media/usbdisk/test/ && time umount /media/usbdisk/
/////////////////////////////////////////////////////////////////////
VANILLA:
real 0m3.770s
user 0m0.004s
sys 0m0.308s
real 0m9.439s
user 0m0.000s
sys 0m0.040s
FLUSH:
real 0m6.000s
user 0m0.012s
sys 0m0.400s
real 0m3.668s
user 0m0.000s
sys 0m0.028s
REAL TIME RATIO (FLUSH/VANILLA):
9.6 / 13.1 = 0.73
/////////////////////////////////////////////////////////////////////
Directory Tree "flushtest": 44MB (8866 files, 1820 dirs)
$ time cp -R flushtest/ /media/usbdisk/ && time umount /media/usbdisk/
/////////////////////////////////////////////////////////////////////
VANILLA:
real 0m0.966s
user 0m0.024s
sys 0m0.860s
real 1m11.962s
user 0m0.004s
sys 0m0.160s
FLUSH:
real 1m41.645s
user 0m0.032s
sys 0m1.112s
real 0m4.660s
user 0m0.004s
sys 0m0.068s
REAL TIME RATIO (FLUSH/VANILLA):
106.3 / 77.9 = 1.36
next prev parent reply other threads:[~2006-03-29 2:12 UTC|newest]
Thread overview: 42+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-02-26 23:08 o_sync in vfat driver col-pepper
2006-02-27 0:51 ` Andrew Morton
2006-02-27 22:19 ` col-pepper
2006-02-27 23:12 ` Andrew Morton
2006-02-28 18:47 ` Chris Mason
2006-02-28 19:10 ` Andrew Morton
2006-02-28 19:48 ` Chris Mason
[not found] ` <87u0aiw6pi.fsf@duaron.myhome.or.jp>
2006-03-01 15:23 ` Chris Mason
[not found] ` <87mzg9wst0.fsf@duaron.myhome.or.jp>
2006-03-02 13:45 ` Chris Mason
2006-03-02 14:07 ` OGAWA Hirofumi
2006-03-02 17:01 ` Chris Mason
2006-03-02 18:14 ` OGAWA Hirofumi
2006-03-29 2:13 ` Mathis Ahrens [this message]
2006-03-30 17:35 ` col-pepper
2006-02-28 0:52 ` Machida, Hiroyuki
-- strict thread matches above, loose matches on Subject: below --
2006-02-26 22:55 col-pepper
[not found] <op.s5cj47sxj68xd1@mail.piments.com>
[not found] ` <op.s5jpqvwhui3qek@mail.piments.com>
[not found] ` <op.s5kxhyzgfx0war@mail.piments.com>
[not found] ` <op.s5kx7xhfj68xd1@mail.piments.com>
[not found] ` <op.s5kya3t0j68xd1@mail.piments.com>
[not found] ` <op.s5ky2dbcj68xd1@mail.piments.com>
[not found] ` <op.s5ky71nwj68xd1@mail.piments.com>
[not found] ` <op.s5kzao2jj68xd1@mail.piments.com>
2006-02-26 22:50 ` col-pepper
2006-02-27 13:28 ` Lennart Sorensen
2006-02-27 13:50 ` Arjan van de Ven
2006-02-27 14:06 ` Anton Altaparmakov
2006-02-27 14:27 ` Arjan van de Ven
2006-02-27 14:41 ` Anton Altaparmakov
2006-02-27 21:04 ` col-pepper
2006-02-27 21:17 ` Arjan van de Ven
2006-02-27 23:21 ` col-pepper
2006-02-27 21:32 ` linux-os (Dick Johnson)
2006-02-27 23:21 ` col-pepper
2006-02-28 13:10 ` linux-os (Dick Johnson)
2006-02-28 13:52 ` Sergei Organov
2006-02-28 15:18 ` Lennart Sorensen
2006-02-28 16:16 ` linux-os (Dick Johnson)
2006-02-28 17:23 ` Sergei Organov
2006-02-28 18:09 ` Krzysztof Halasa
2006-02-28 17:16 ` col-pepper
2006-02-28 22:38 ` Pavel Machek
2006-03-01 4:28 ` Kyle Moffett
2006-03-02 8:23 ` col-pepper
2006-03-02 8:32 ` Pavel Machek
2006-02-28 16:11 ` Helge Hafting
2006-02-28 22:37 ` Pavel Machek
2006-02-27 14:26 ` linux-os (Dick Johnson)
2006-02-27 18:53 ` Jan Engelhardt
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4429ED2F.10407@gmx.de \
--to=mathis.ahrens@gmx.de \
--cc=akpm@osdl.org \
--cc=col-pepper@piments.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mason@suse.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.