On Thu, Dec 16, 2010 at 05:05:13PM -0500, Wietse Venema wrote:
> Scott Lambert:
> > > OK, before less-informed people start to spread urban legends, I did
> > > all the measurements with the default nsswitch.conf file (see below)
> > > which contains the exact same entries that were making your system
> > > crawl.
> > >
> > > So, while Postfix is now performing better for you, I am less
> > > convinced that everything is kosher, unless someone can explain to why
> > > the default nsswitch.conf was no good for your particular system (or
> > > why it was burning up 98% CPU in kernel mode).
> > 
> > This is not postfix specific.  Just in case anyone was inferring
> > that.
> > 
> > It has to do with the number of entries in the password file.  I
> > do not remember the details for why, but with thousands of users
> > in the password file anything that maps usernames to uids gets slow
> > with passwd and group set to compat.  The first time I saw the
> > problem was with ls -l in /home on a machine with thousands of
> > users.  It took minutes.   ls -ln completed as quickly as the pty
> > could display the output.
> 
> Thanks for the backgrouns.
> 
> Could you please file a bug report. Originally, 4.4BSD uses a hashed
> password file, so there is no excuse why lookups from file should
> be slow, especially with the default nsswitch file which is what
> everyone ends up using.
> 
>       Wietse

Apparantly, I exaggerated the slowness of the ls -l.  I finally
found my thread from 2007 when I first found and asked about this.

http://unix.derkeiler.com/Mailing-Lists/FreeBSD/stable/2007-04/msg00193.html

I'll go ahead and file a PR.  There don't seem to be too many people
complaining about this.

-- 
Scott Lambert                    KC5MLE                       Unix SysAdmin
lamb...@lambertfam.org

Reply via email to