[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: ext4 and extremely slow filesystem traversal



On 13/03/2013 10:19, Vincent Caron wrote:
>> > Did you sort results from readdir() by inode number?  i.e., such as
>> > what the following LD_PRELOAD hack does?
>> > 
>> > https://git.kernel.org/cgit/fs/ext2/e2fsprogs.git/tree/contrib/spd_readdir.c?h=maint
>   I don't think I tried this specific hack, I'm having a go right now.
> Is is still useful if each directory only holds a few inodes ?

  Same slowness, I ran :

  filer:~# gcc -shared -fPIC -ldl -o spd_readdir.so spd_readdir.c
  filer:~# LD_PRELOAD=./spd_readdir.so find /srv/vol -type d |pv -bl

  I stopped the experiment at +54min with 845k directories found (which
gives roughly the same rate of 1M directories / hour, and I know there
are more that 2M of them).


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]