hi I read ( I think in dovecot wiki) that ext2 or ext3 fs on a 2.4 kernel can get slow due to the number of files in a directory. Does anyone know if kernel 2.6 has similar limitation? I'm not at that point now, but before the box goes live, I'm wondering if I should resolve that. Glenn
Actually - yes. Same problem. But the solution is to use the Reiser Filesystem. It doesn't have the ext3 problem. vmstech wrote:>hi >I read ( I think in dovecot wiki) that ext2 or ext3 fs on a 2.4 kernel >can get slow due to the number of files in a directory. Does anyone know >if kernel 2.6 has similar limitation? I'm not at that point now, but >before the box goes live, I'm wondering if I should resolve that. >Glenn > > >-- Marc Perkel - marc at perkel.com Spam Filter: http://www.junkemailfilter.com My Blog: http://marc.perkel.com
vmstech wrote:>hi >I read ( I think in dovecot wiki) that ext2 or ext3 fs on a 2.4 kernel >can get slow due to the number of files in a directory. Does anyone know >if kernel 2.6 has similar limitation? I'm not at that point now, but >before the box goes live, I'm wondering if I should resolve that. >Glenn > >i was trying to find out the same thing a few weeks back.. from what I understand, the 2.6 kernel has some significant optimisations to ext3... i think ext3 may now have B-trees to speed up access to directories with a lot of files/subdirectories? can anyone confirm this? I was also looking at Reiser as an alternative... but as RH doesn't support it at all anymore, i didn't want to risk my precious maildirs :) Michael
On Tue, 19 Jul 2005, vmstech wrote:> I read ( I think in dovecot wiki) that ext2 or ext3 fs on a 2.4 kernel > can get slow due to the number of files in a directory. Does anyone know > if kernel 2.6 has similar limitation? I'm not at that point now, but > before the box goes live, I'm wondering if I should resolve that.Yes, ext2/ext3 is subject to the performance degradation unless you use special patches. You can use xfs, jfs or reiserfs(recommended) as they dont suffer from this issue. -Dan
I can heartily recommend reiserfs on kernel 2.4 for Intel and Sparc. My spam filtering setup currently has 27K files in a quarantine dir, and it works just fine. In a year and a half over 50 machines I've had three corrupted reiserfs filesystems, none of them on production machines, at least one of which I can blame on a bad disk. I would not be surprised to learn they were all bad disks, because the disks are five+ years old. For the last one I moved the bad dir aside where it sat peacefully for a week, and when I fsck'ed it the more aggressive mode of fsck coredumped partway through and it became unaccessable. I then restored it from the tar I had made prior. Brian
> > >> ------------------------------------------------------------------------ >We were posed with the same dilemma, but it was due to the need to stick with RHEL supplied packages (ReiserFS does not come with RHEL) that we stayed with ext3. Our old production mail server, running our in-house flavour of Linux, was based on the 2.4 kernel with ReiserFS. We load tested Dovecot with maildir under RHEL3 (2.4 kernel) using ext3 and found it was unable to standup to our requirements. In part this was due to an inordinate imap-login / pop-login processes being created and hanging around under RHEL3. Using RHEL4 (2.6 kernel), we found we were able to handle the required load - this is the configuration we went live with. Processes ended cleanly too (result of the improved schedular and how it interacted with our IBM x445 and its NUMA architecture?) and the I/O issues seemed to have been resolved - ext3 was fine.>> Subject: >> Re: [Dovecot] linux 2.4 vs 2.6 kernel >> From: >> Marc Perkel <marc at perkel.com> >> Date: >> Mon, 18 Jul 2005 18:33:54 -0700 >> >> CC: >> dovecot at dovecot.org >> >> >> >> >> Curtis Maloney wrote: >> >>> Marc Perkel wrote: >>> >>>> Actually - yes. Same problem. But the solution is to use the Reiser >>>> Filesystem. It doesn't have the ext3 problem. >>> >>> >>> >>> Now, I don't want to start a religious war, but... >>> >>> Ext2 has the advantages that 1) it can fall back to ext2 in recovery >>> cases, and 2) because of that, it has all the well-tested ext2 >>> recovery tools available. >>> >>> People I know who've used Reiser say it's wonderfuly fast, but if it >>> corrupts, well... save your time, and go straight to restoring your >>> backups. >>> >>> Also, take a look at the tune2fs options. I understand -O dir_index >>> will set it to use a b-tree index for faster handling of large >>> directories. >>> >>> -- >>> Curtis Maloney >>> cmaloney at cardgate.net >> >> >> I've been using it for 5 years and it works great. It specifically >> eliminates the speed problems of Maildir where you have thousands of >> files in a single directory. And it has infinite inodes so you never >> run out of them. Reiser is ideal for email systems. >> >>------------------------------------------------------------------------ >> >>_______________________________________________ >>dovecot mailing list >>dovecot at dovecot.org >>http://dovecot.org/cgi-bin/mailman/listinfo/dovecot >>
On 2005-07-19 11:14:03 +1000, vmstech wrote:> hi > I read ( I think in dovecot wiki) that ext2 or ext3 fs on a 2.4 kernel > can get slow due to the number of files in a directory. Does anyone know > if kernel 2.6 has similar limitation? I'm not at that point now, but > before the box goes live, I'm wondering if I should resolve that. > GlennQuick answer: ext3 with dir_index is fine. this link has some nice speed comparision: http://lwn.net/Articles/10904/ hope this helps darix p.s.: my personal preference is XFS.
vmstech wrote:> hi > I read ( I think in dovecot wiki) that ext2 or ext3 fs on a 2.4 kernel > can get slow due to the number of files in a directory. Does anyone know > if kernel 2.6 has similar limitation? I'm not at that point now, but > before the box goes live, I'm wondering if I should resolve that. > Glenn >Having quickly scanned this thread and seen many stories both ways and horrors from using anything on a disk, I thought I'd present one thing that should weight heavy for everyone, no matter what filesystems and drives you use, have used, lost data on or saved the day with: Stick with what you already use, unless there is a really overwhelming reason not to. In my case I run a good few machines and only use ext3, and yes I know that I could squeeze out more speed by adopting reiserfs in places, or some other feature, but ask yourself this: admin-wise, what is the overhead in having to deal with one extra item to solve a very specific problem in one single spot? In my case it would mean to have to learn the works for a different filesystem than I already use. ext3 with dir_index solves the problem 90% for us, and everything remains the same admin-wise. If someone at the PHB-level wants that extra performance, explain it nicely in terms of cost for extra knowledge, or a simple: buy better iron. my two cents, Alexander PS: to at least have mentioned dovecot in my reply: it works a bit too well, I haven't had a problem with it yet :D