System hanging during dump

Kostik Belousov kostikbel at gmail.com
Sun Nov 2 02:54:25 PST 2008


On Sun, Nov 02, 2008 at 07:37:05PM +1100, Peter Jeremy wrote:
> Sorry for the late reply.
> 
> On 2008-Oct-19 11:39:02 +0300, Kostik Belousov <kostikbel at gmail.com> wrote:
> >> I have built myself a looping 'ps -axl' which should let me gather more
> >> information if it does re-appear.  (In the process, I've found that ps
> >> leaks memory, though that's not a problem until you wrap it in a loop).
> >
> >What memory ? Kernel one ? How did you noted this ? Could you add
> >vmstat -z and vmstat -m to the loop and watch what allocation grows ?
> 
> ps(1) malloc's memory and doesn't free it.  This isn't an issue in
> normal operation because it's a once-through program.  I hacked ps to
> turn the guts of main() into a while(1){} loop and this showed the
> process was growing.  There were a couple of superfluous strdup()
> calls that could be removed but I don't think it's worth making it
> exhaustively clean up after itself (my hacking included hard-wiring
> the options so I'm not sure my cleanup code is complete in the general
> case).  As a low priority, I'll create a PR covering the strdup's.

Thank you for clarification. Please, Cc: me with a PR, I will look at it.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 195 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-stable/attachments/20081102/6c257b75/attachment.pgp


More information about the freebsd-stable mailing list