ls performance

utzoo!decvax!ucbvax!unix-wizards utzoo!decvax!ucbvax!unix-wizards
Tue Sep 22 20:53:12 AEST 1981


>From ihnss!karn at Berkeley Tue Sep 22 15:34:20 1981
One thing I've found about ls -l is that it REALLY slows to a crawl
when the files belong to a number of different userids.  This is
because a linear search of /etc/passwd (and/or /etc/group)
is done for each file to map the internal userid back to an ascii
owner name.  The last userid searched for is kept in case the next
file is owned by the same user, so the search is done only once if
all the files are owned by the same user.  But try it on a large
public directory containing commands belonging to a number of users,
and you'll see what I mean.

Phil



More information about the Comp.unix.wizards mailing list