From: Stewart Smith <stewart@flamingspork.com>
To: Keyur Govande <keyurgovande@gmail.com>,
Dave Chinner <david@fromorbit.com>
Cc: linux-fsdevel@vger.kernel.org, xfs@oss.sgi.com
Subject: Re: XFS fragmentation on file append
Date: Wed, 23 Apr 2014 21:48:54 +1000 [thread overview]
Message-ID: <874n1k466x.fsf@flamingspork.com> (raw)
In-Reply-To: <CAJhmKHk5fWVaDTEfL_oESULspavk83eBEsyw7=qEp8bC7f2S2g@mail.gmail.com>
[-- Attachment #1.1: Type: text/plain, Size: 975 bytes --]
Keyur Govande <keyurgovande@gmail.com> writes:
> I spent some more time figuring out the MySQL write semantics and it
> doesn't open/close files often and initial test script was incorrect.
MySQL will open/close files depending on some configuration parameters
and the number of tables that exist/are open/are in the working set.
If InnoDB tables, it's innodb_max_open_files (IIRC it's named that, or
something similar). If you have less than that number of tables and
innodb_file_per_table=true, then you'll never close. If you have the max
set to 10 times the working set of active tables, you're going to be
opening and closing files a lot - it's basically a LRU of unused tables
(open files).
> It uses O_DIRECT and appends to the file; I modified my test binary to
> take this into account here:
> https://gist.github.com/keyurdg/54e0613e27dbe7946035
You can also make it not use O_DIRECT, but that's generally a bad idea :)
--
Stewart Smith
[-- Attachment #1.2: Type: application/pgp-signature, Size: 818 bytes --]
[-- Attachment #2: Type: text/plain, Size: 121 bytes --]
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
next prev parent reply other threads:[~2014-04-23 11:49 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-04-07 22:53 XFS fragmentation on file append Keyur Govande
2014-04-08 1:50 ` Dave Chinner
2014-04-08 1:50 ` Dave Chinner
2014-04-08 3:42 ` Keyur Govande
2014-04-08 5:31 ` Dave Chinner
2014-04-08 5:31 ` Dave Chinner
2014-04-22 23:35 ` Keyur Govande
2014-04-22 23:35 ` Keyur Govande
2014-04-23 5:47 ` Dave Chinner
2014-04-23 5:47 ` Dave Chinner
2014-04-23 8:11 ` Dave Chinner
2014-04-23 8:11 ` Dave Chinner
2014-04-23 19:05 ` Keyur Govande
2014-04-23 22:52 ` Dave Chinner
2014-04-23 22:52 ` Dave Chinner
2014-04-23 11:48 ` Stewart Smith [this message]
2014-04-24 6:54 ` Stefan Ring
2014-04-24 21:49 ` Keyur Govande
2014-05-15 20:25 ` Stefan Ring
2014-05-15 20:25 ` Stefan Ring
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=874n1k466x.fsf@flamingspork.com \
--to=stewart@flamingspork.com \
--cc=david@fromorbit.com \
--cc=keyurgovande@gmail.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=xfs@oss.sgi.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.