Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 28 Dec 2007 13:38:51 -0800
From:      Alfred Perlstein <alfred@freebsd.org>
To:        Alexandre Biancalana <biancalana@gmail.com>
Cc:        freebsd-performance@freebsd.org
Subject:   Re: Bad performance when accessing a lot of small files
Message-ID:  <20071228213851.GE76698@elvis.mu.org>
In-Reply-To: <8e10486b0712251647uddf80f9sa6cacb42dfa94ff5@mail.gmail.com>
References:  <8e10486b0712191109n3d21b02cyf5183ee0cd01d8ce@mail.gmail.com> <20071221201625.GZ16982@elvis.mu.org> <8e10486b0712211249v4c5571ddud21b277f686992b2@mail.gmail.com> <20071221212808.GE16982@elvis.mu.org> <8e10486b0712211555n3efe8729qff14387be128cf10@mail.gmail.com> <20071222002535.GL16982@elvis.mu.org> <8e10486b0712251647uddf80f9sa6cacb42dfa94ff5@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
* Alexandre Biancalana <biancalana@gmail.com> [071225 16:45] wrote:
> On 12/21/07, Alfred Perlstein <alfred@freebsd.org> wrote:
> 
> > Have you tried the 'noatime' mount option?  That should help.
> 
> Yeah, the zfs set atime=off was already done....
> 
> >
> > Can you provide a histogram of the count of files per directory?
> 
> Excuse-me, but I don't understand....

Distribution of files per directory, example:

1000 files in 9 dirs
1001 files in 12 dirs

find /path_to_root/ -type f | sed 's/\/[^/]*$//' | uniq -c | \
  awk '{print $1}' | sort -n | uniq -c

That will print out the number of files per dir.

   2 98
   3 102
   1 103
   2 105

Or something like that.



-- 
- Alfred Perlstein



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20071228213851.GE76698>