Bug 119490 - top(1) hangs for long periods with NIS -- even using -u
Summary: top(1) hangs for long periods with NIS -- even using -u
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: bin (show other bugs)
Version: Unspecified
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-01-09 13:30 UTC by David Frascone
Modified: 2011-02-15 01:00 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David Frascone 2008-01-09 13:30:02 UTC
Top does a getpwent loop, which takes forever on NIS boxes with huge password databases.

I have a fix, but I'm filing this bug, so that my diff can be tested / checked in.  The -u option is supposed to avoid problems like this, but it was not being checked everywhere.

Fix: 

Will submit diff when cvsup is finished building
How-To-Repeat: top or top -u on a box with a big YP password file
Comment 1 dfilter service freebsd_committer freebsd_triage 2008-01-09 18:06:31 UTC
obrien      2008-01-09 18:06:24 UTC

  FreeBSD src repository

  Modified files:
    usr.bin/top          machine.c 
    contrib/top          top.c 
  Log:
  Improve -u (limit uid lookups) behavior.
  
  Submitted by:   David Frascone <dave@frascone.com>
  PR:             119490
  
  Revision  Changes    Path
  1.24      +1 -1      src/contrib/top/top.c
  1.84      +8 -2      src/usr.bin/top/machine.c
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 2 Gavin Atkinson freebsd_committer freebsd_triage 2008-02-28 12:04:27 UTC
State Changed
From-To: open->patched

Fixed in -HEAD (after 7.x was branched), needs MFCing to RELENG_6/7
Comment 3 Gavin Atkinson freebsd_committer freebsd_triage 2008-06-06 18:40:55 UTC
This is fixed in HEAD and RELENG_7, but not yet merged to RELENG_6.
Comment 4 Alexander Best freebsd_committer freebsd_triage 2011-02-15 00:59:39 UTC
State Changed
From-To: patched->closed

Fixed in all branches.