Re: filesystem performance with lots of small files

From: David Malone <dwmalone_at_maths.tcd.ie>
Date: Fri, 26 Aug 2005 09:12:45 +0100
On Thu, Aug 25, 2005 at 11:25:23PM +0200, Marian Hettwer wrote:
> I didn't changed anything from the defaults... it looks like that:
> mhettwer_at_submaster-test$ sysctl vfs.ufs.dirhash_maxmem
> vfs.ufs.dirhash_maxmem: 2097152
> mhettwer_at_submaster-test$ sysctl vfs.ufs.dirhash_mem
> vfs.ufs.dirhash_mem: 368622
> 
> By the way, the copy job of my small files finished, so here we go with 
> some small facts :)
> mhettwer_at_submaster-test$ sudo time find /usr/tmp/ | wc -l
>       133.81 real         2.01 user         3.95 sys
>  2904696

(Sorry - I missed the start of this thread.)

With dirhash it is how many files/directories you have in one
directory that is important. Subdirectories don't count. One way
to get a rough estimate of how big you should make vfs.ufs.dirhash_maxmem
is do to "ls -ld /usr/tmp" and see how many bytes the directory
takes. The number of bytes shown is probably a reasonable estimate
of what you should set vfs.ufs.dirhash_maxmem to.

	David.
Received on Fri Aug 26 2005 - 08:15:22 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:42 UTC