On Wed, 2005-06-29 at 14:52 -0700, Andrew Morgan wrote: > In the interest of completeness, under 2.6 linux kernels you can format an > ext3 partition using the dir_index option. This enables a hash tree index > for directories that supposedly improves lookups with very large > directories. Here is the command I use to build my mail spool filesystem: > > mkfs -t ext3 -j -m 1 -O dir_index /dev/sdb1 > > I have not used other filesystems such as Reiser or XFS, so I cannot offer
Later 2.4 kernels have hashed directory support also; in fact, I've just enabled it on my main Cyrus server, which is running CentOS 3.5 and kernel 2.4.21-27.0.2.ELsmp. (My e2fsprogs man pages had not been updated to reflect the new options also.) You don't have to recreate your filesystem or unmount them for that matter--you can enable it with: tune2fs -O dir_index /dev/foo You can also optimize your directories (which is probably a good idea if you're enabling it on an existing filesystem) with e2fsck: e2fsck -f -D /dev/foo (you'll need the -f if the filesystem is clean) Wil -- Wil Cooley [EMAIL PROTECTED] Naked Ape Consulting http://nakedape.cc * * * * Linux, UNIX, Networking and Security Solutions * * * *
signature.asc
Description: This is a digitally signed message part