LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Running ‘top’ with ‘Irix mode’ off in batch mode (https://www.linuxquestions.org/questions/linux-software-2/running-%91top%92-with-%91irix-mode%92-off-in-batch-mode-754014/)

alexz1011 09-09-2009 07:33 PM

Running ‘top’ with ‘Irix mode’ off in batch mode
 
Hi there, a first poster here.

Can anyone tell me how I can tweak the following top command so that it always runs in Irix/Solaris mode in a batch mode operation?

Code:

top -d 3 -n 2 -b -p <PID>
I need 'top' to output a process' CPU usage that had already been divided by the total number of CPUs, and as far as I know, that can be achieved with the 'I' toggle (Irix mode), but it only seems to be available in interactive operation (not in batch operation).

So I was wondering if this is indeed the case, or does anyone know any workaround for what I intended to achieve?

Thanks!

PS. OS: RedHat Enterprise Linux 5.

blackhole54 10-02-2009 03:29 PM

Have you tried specifying Irix mode in the personal configuration file? (Run top interactively, toggle to Irix mode and save configuration.)


All times are GMT -5. The time now is 07:15 PM.