Peter D. Gray wrote:
On Mon, Oct 22, 2007 at 06:26:56PM -0700, Blake Golliher wrote:
I'd argue that this is general file system issue, not so much a wafl issue. I don't think wafl is particularly slow at this workload
The problem itself is a general filesystem issue I agree.
However, my understanding is that wafl stores the metadata with the file, I assume as the first block. UFS stores the metadata in inodes, and they are not stored with the file, but the system tries to keep inodes "close" to the file. Inodes reside together with other inodes so a single read can pick up a lot of inodes.
A quote from http://www.csse.monash.edu.au/~carlo/SYSTEMS/Network-Appliance-0697.htm:
Additional features have been added to the WAFL design to enhance performance. The most important of these is a clever hashing mechanism to speed up searches for files in large directories. This facility, termed a directory hash, is in effect a directory level name cache which is designed to cache every single file in the directory, rather than a recently accessed subset as is the case in more conventional name caching models. Netapps published data suggest this provides a five-fold performance increase for a 30,000 file directory search.
The effect is, if you know the name of the file the access is very fast.