[Leaplist] directory "size", does it matter?

Ingo Claro miclaro at netred.cl
Wed Jan 21 13:53:54 EST 2009


Steve Litt wrote:
> On Wednesday 21 January 2009 09:42:32 am Ingo Claro wrote:
>   
>> Hello all:
>> I've got a basic question:
>> I know that a directory is just another file and it stores information
>> regarding it's contents, so how does this directory size affect
>> performance? 
>>     
>
> Many filesystems, such as ext2 and ext3, use sequential search to locate a 
> filename. That means on a directory with 40 files, it must on average look at 
> 20 filenames, which is quick. If the directory has 40,000 files, it must on 
> average look at 20,000 filenames, which is pig slow. Every write, every 
> delete, and every move requires a file to be located.
ok, I know, but this is the size of the directory, not what's inside. It 
has no files, the directory has that size after creating and deleting a 
lot of files inside.


ingo.

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.



More information about the Leaplist mailing list