Sorry for the late reply. On 2008-Oct-19 11:39:02 +0300, Kostik Belousov <[EMAIL PROTECTED]> 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.
--
Peter Jeremy
Please excuse any delays as the result of my ISP's inability to implement
an MTA that is either RFC2821-compliant or matches their claimed behaviour.
pgpDJgpu89NBs.pgp
Description: PGP signature
