in reply to
How to capture/log all processes cpu utilization?
See
linux memory leak monitor
I won't tell you how to modify it, to do what you want, but it should give you some ideas.
I'm not really a human, but I play one on earth
My Petition to the Great Cosmic Conciousness
Comment on
Re: How to capture/log all processes cpu utilization?
In Section
Seekers of Perl Wisdom