DragonFly BSD
DragonFly bugs List (threaded) for 2005-02
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

Re: (lightbulb goes off) Re: sockstat not working

From: "Erik P. Skaalerud" <erik@xxxxxxxxxxxx>
Date: Thu, 03 Feb 2005 07:36:10 +0100

Matthew Dillon wrote:

   Ah ha!  I think I'm on to something here.  It looks like sysctl is being
   asked to report the buffer size but then the second call which fills the
   buffer is returning ENOMEM, meaning that the supplied buffer is not
   large enough, meaning that sysctl is not calculating the correct buffer

   I think what is going on is that the sysctl code in kern_descrip.c is
   not counting threaded processes (which share their descriptor tables)

   Since your system has a lot of threaded processes, and my system doesn't,
   you are hitting the bug and I am not.

   Please try the enclosed patch.  I have committed this to HEAD as well
   and will slip the stable tag on it once I get confirmation that it
   fixes the problem.

Matthew Dillon <dillon@xxxxxxxxxxxxx>

Index: kern_descrip.c
RCS file: /cvs/src/sys/kern/kern_descrip.c,v
retrieving revision 1.38
diff -u -r1.38 kern_descrip.c
--- kern_descrip.c 14 Jan 2005 19:28:10 -0000 1.38
+++ kern_descrip.c 2 Feb 2005 20:33:47 -0000


Looks like this did the trick Matt, I think it safely can be slipped to Stable.

- Erik

[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]