[Dovecot] ext3/ext4 performance issue

Steffen Kaiser
Tue, 19 May 2009 14:14:12 -0000

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Fri, 15 May 2009, Timo Sirainen wrote:

on my production system, I've scanned 97559 dirs in total, including
'tmp's, Maildir & homedirs. Control and Indexes are located
elsewhere.

There a total of 97406, 5238 of them use more than one block, hence,
92168 are skipped from the stats below.

Then I compared the size of the directory file with this:

filename size    sum of length of all entries in the directory
   + 10 * number of entries in the directory

The ratio is calculated:
  size of directory file divided by filename size

ratio	num of
 	dirs
<2	1593
3	810
4	228
5	129
6	122
7	65
8	56
9	31
10	30
11	27
12	21
13	18


Top ranks are:
fnamsiz dirsiz ratio
23	1417216	61618.09
23	1089536	47371.13
23	872448	37932.52
23	839680	36507.83
23	802816	34905.04
23	684032	29740.52
23	684032	29740.52
23	655360	28493.91
70	1847296	26389.94
23	593920	25822.61
23	581632	25288.35
23	536576	23329.39
23	532480	23151.3
23	516096	22438.96
23	503808	21904.7
23	471040	20480
23	446464	19411.48
23	425984	18521.04
287	5005312	17440.11
23	376832	16384

There are 2175 dirs with a ratio >= 10.

There are 1613 directories with a ratio >= 100,
747	"/cur"
492	"/new"
372	"/tmp"
1	Maildir itself
1	.dovecot.rawlog

Nearly all of them are: INBOX, Trash & SPAM folders.  The two last ones
with various names depending of the IMAP client used.

I used this Perl script:
http://www2.inf.fh-brs.de/skdata/dovecot/cntDirsize.bz2

Bye,

- --
Steffen Kaiser
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iQEVAwUBShK+t3WSIuGy1ktrAQJRdQf/UGv6Z/zzcqK88SZ9Axgx2PAmU8kH498w
w7enifmjKpPMw0NOv2a4uPf1BNaVdTC/Ln/MMILSnZIqWYYo1RyB35HdXylFH2NQ
wtOkYDJuowtcdw8JXz3lxlDNpuWJLCjIRFSoodihmPVdwEvsEScbyOb9QH90F3Yb
DUK/VrI9M63fOggushVNr8iROoP4D3U+C/G0DLkPSdBfRXIBkNUldmrRiBAsMvMf
/1seK3bQPsPHsSQrGG4zi4j4NXYcLXmyuvmS/V7QmBAUaA2lzLXAI8da5AokD947
SLrvUA9BQTlwldisossY2YbpX+4dtBTbVNULsCKF//tY9UXvFu1NKg==3TPJ
-----END PGP SIGNATURE-----