From: Theodore Ts'o <tytso@mit.edu>
To: Jeff Moyer <jmoyer@redhat.com>
Cc: Ext4 Developers List <linux-ext4@vger.kernel.org>
Subject: Re: [PATCH] ext4: add max_dir_size_kb mount option
Date: Fri, 10 Aug 2012 17:58:11 -0400 [thread overview]
Message-ID: <20120810215811.GA1137@thunk.org> (raw)
In-Reply-To: <x49r4repkwj.fsf@segfault.boston.devel.redhat.com>
On Fri, Aug 10, 2012 at 04:11:24PM -0400, Jeff Moyer wrote:
>
> I have no idea what a reasonable number for this would be. Can you
> provide guidelines that would help admins understand what factors
> influence performance degradation due to directory size?
Well, for example, if you have a job which is a 512mb memory
container, and the directory has grown to 176mb, an attempt to readdir
said directory will cause that job to thrash badly, and perhaps get
killed by the OOM killer. If you know that no sane directory should
ever grow beyond a single megabyte, you might pick a max_dir_size_kb
of 1024.
> Finally, I don't pretend to understand how your mount option parsing
> routines work, but based on what I see in this patch it looks like the
> default will be set to and enforced as 0. What am I missing?
Sorry, I sent out the wrong version of the patch. The limit was only
supposed to be used if maximum directory size is greater than 0; that
is, the default is that the directory size is unlimited, as before.
I'll send out a revised v2 version of the patch.
I view this as a very specialized option, but if you're running in a
tightly constrained memory cgroup, or a tiny EC2 instance, or the
equivalent Cloud Open VM, it might be a very useful thing to be able
to cap.
Regards,
- Ted
next prev parent reply other threads:[~2012-08-10 21:58 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-10 19:23 [PATCH] ext4: add max_dir_size_kb mount option Theodore Ts'o
2012-08-10 19:38 ` Eric Sandeen
2012-08-10 19:59 ` Theodore Ts'o
2012-08-10 20:16 ` Eric Sandeen
2012-08-10 21:59 ` Theodore Ts'o
2012-08-10 20:11 ` Jeff Moyer
2012-08-10 21:58 ` Theodore Ts'o [this message]
2012-08-10 23:14 ` Andreas Dilger
2012-08-11 1:40 ` [PATCH -v2] " Theodore Ts'o
2012-08-11 3:22 ` Andreas Dilger
2012-08-11 19:26 ` Theodore Ts'o
2012-08-11 21:10 ` Andreas Dilger
2012-08-11 21:13 ` Ted Ts'o
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=20120810215811.GA1137@thunk.org \
--to=tytso@mit.edu \
--cc=jmoyer@redhat.com \
--cc=linux-ext4@vger.kernel.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).