From: Theodore Tso <tytso@MIT.EDU>
To: bernie@codewiz.org
Cc: lkml <linux-kernel@vger.kernel.org>,
David Woodhouse <dwmw2@infradead.org>,
ext3-users@redhat.com, ext2-devel@lists.sourceforge.net,
Stefano Fedrigo <aleph@develer.com>
Subject: Re: ext3_dx_add_entry: Directory index full!
Date: Sun, 18 May 2008 17:04:35 -0400 [thread overview]
Message-ID: <20080518210435.GA8335@mit.edu> (raw)
In-Reply-To: <48304D92.1080306@develer.com>
On Sun, May 18, 2008 at 05:38:58PM +0200, Bernie Innocenti wrote:
> Bernie Innocenti wrote:
>> On 2.6.24.4-64.fc8, I createed and mounted a filesystem like this:
>> mke2fs -m0 -b 1024 -R stride=64 -I 128 -i 2048 -j -L mail -O
>> dir_index,sparse_super -v /dev/sdc1
>
> I cannot reproduce it any more if I reformat omitting "-b 1024".
> Maybe it would reappear with 200K * 4 = 800K files?
Using a filesystem with 4k blocks, and assuming the filenames are of
the same average length, you should be able to get approximately 200k
* (4**3) = 12.8 million files in a single directory. If you use a 2k
block filesystem, the limit will be approximately 200k * (2**3) = 1.6
million files in a single directory.
Regards,
- Ted
P.S. Past a certain point, you really don't want to have that many
files in a Maildir directory; if the user is never going to be
deleting his SPAM, then you should seriously think about using a Unix
mbox style storage scheme. Even with a 1k block filesystem, at 12
million files you'll be wasting 6 gigabytes of disk space of slack
space that is totally being wasted since the whole point of using
Maildir is to make it easy to delete or replace individual mail
messages. If you want to archive all of your SPAM, why use a Maildir
format mbox at all?
next prev parent reply other threads:[~2008-05-19 0:24 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-05-18 15:36 ext3_dx_add_entry: Directory index full! Bernie Innocenti
2008-05-18 15:38 ` Bernie Innocenti
2008-05-18 18:32 ` Jan Engelhardt
2008-05-18 21:04 ` Theodore Tso [this message]
2008-05-19 0:58 ` Bernie Innocenti
2008-05-18 15:39 ` David Woodhouse
2008-05-18 15:44 ` Bernie Innocenti
2008-05-18 16:24 ` Theodore Tso
2008-05-18 23:01 ` Stefano Fedrigo
2008-05-19 0:49 ` Theodore Tso
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=20080518210435.GA8335@mit.edu \
--to=tytso@mit.edu \
--cc=aleph@develer.com \
--cc=bernie@codewiz.org \
--cc=dwmw2@infradead.org \
--cc=ext2-devel@lists.sourceforge.net \
--cc=ext3-users@redhat.com \
--cc=linux-kernel@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