From: Jens Axboe <axboe@kernel.dk>
To: Ken Raeburn <raeburn@permabit.com>
Cc: fio@vger.kernel.org
Subject: Re: fio --direct=1 and Linux page cache effects
Date: Wed, 12 Dec 2012 08:24:13 +0100 [thread overview]
Message-ID: <50C8311D.3060800@kernel.dk> (raw)
In-Reply-To: <50C79326.8010903@permabit.com>
On 2012-12-11 21:10, Ken Raeburn wrote:
> On 12/11/12 08:29, Jens Axboe wrote:
>> You are right, blkid likely wont be done by then, so it's still down
>> to timing whether it'll help or not. This is pretty annoying. This
>> issue is due to the file being opened for write. But unfortunately we
>> cannot open for read always, as fcntl() wont allow change of file
>> access mode flags. So how about the below. Basically DON'T close the
>> fd, defer that until we really close the file. This will keep one
>> extra fd open until the original is closed, but I don't see that as
>> being an issue.
>
> This patch seems to be working just fine. I have reproduced the case
> where it uses the shadow_fd field, but blkid doesn't run and the page
> cache entries don't get loaded, and in my initial tests with dm-zero, it
> looks like the bimodal performance distribution is gone.
>
> Thanks!
Excellent, I think this is probably as good as it is going to get. I
have committed the fix. Thanks a lot for reporting it, especially in
such great detail. When a problem is fully understood, fixing it is then
the smallest part of the effort.
--
Jens Axboe
prev parent reply other threads:[~2012-12-12 7:24 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-12-05 0:23 fio --direct=1 and Linux page cache effects Ken Raeburn
2012-12-06 21:06 ` Jens Axboe
2012-12-07 9:00 ` Jens Axboe
2012-12-11 1:00 ` Ken Raeburn
2012-12-11 13:29 ` Jens Axboe
2012-12-11 20:10 ` Ken Raeburn
2012-12-12 7:24 ` Jens Axboe [this message]
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=50C8311D.3060800@kernel.dk \
--to=axboe@kernel.dk \
--cc=fio@vger.kernel.org \
--cc=raeburn@permabit.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.