> The problem is that Linux doesn't know we got all the attribute > information with the dirread, and then goes and individually queries > each file in the directory with a stat -- this happens in a serial > fashion, so the high latency to sources just makes the problem worse.
I have had similar problems in the past and opted to cache dirread metadata for a second. This is short enough for most things to continue to work, but long enough for ls(1) to feel responsive. if you applications use the old unix trick of using a directory as an interprocess lock then your mileage may vary... -Steve