Re: How do I get percentage CPU usage of processes for a specified time interval?



On Feb 16, 3:35 am, "Adrian Davis" <adr...@xxxxxxxxxxxx> wrote:
How do I get percentage CPU usage of processes for a specified time
interval?

I'm wish to write a script, part of which displays the top 10
processes by percentage processor usage over a 30 second interval. I
know "topas" can show this, but I need to be able to process the
information in a script. The output from "ps" doesn't seem to give the
neccessary resolution...

Can anybody give me some pointers as to how this can be done?

Many Thanks,
=Adrian=

You can run "tprof -x sleep 30" and then use awk/grep to filter infor
from the generated sleep.prof file.
HTH

.



Relevant Pages

  • Processor Usage report?
    ... Is there a XP Home _command line_ utility to give processor usage? ... I want it in a script, to tell if a process is thrashing (if the usage falls, ...
    (microsoft.public.windowsxp.help_and_support)
  • Re: How do I get percentage CPU usage of processes for a specified time interval?
    ... Adrian Davis wrote: ... I'm wish to write a script, part of which displays the top 10 ... processes by percentage processor usage over a 30 second interval. ... that can be analyzed in that fashion (e.g. nmon Analyzer). ...
    (comp.unix.aix)
  • Re: Nat & startup
    ... > Do you know how to add any other thing to the startup? ... > Thanks again, Adrian ... You need to create a script in init.d, then run update-rc.d to add it to ... >>loaded each time iptables is started. ...
    (Debian-User)
  • Re: topas output to file
    ... I'm trying to run topas in a script and to write the output to a file. ... The problem is that in the file appear many strange simbol, ... I need to have the CPU busy/idle and all the process with the ...
    (comp.unix.aix)
  • Re: Re: Remote install fonts
    ... Hey adrian, im having issues of the same nature. ... script to complete all this or some batch process? ... >add a Reg_SZ value in the registry for the new font. ... >> the font is not available for users logging on the workstations. ...
    (microsoft.public.windowsxp.configuration_manage)