Re: Question: Reading the Output of Top

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I doubt that there is an answer to your first question. You could probably write a script to do it.

As for your second question, I run top thusly, 'top -bn1 | more'. This runs top in batch mode and has it retrieve the data just once. Piping the output to more keeps the data from scrolling off the top. What you get is a snapshot of the data at the moment you run the top command.

PS: You can also set the refresh rate for top to something high enough for you to listen to the output.



On 05/06/2016 01:59 AM, Parham Doustdar wrote:
Hi all,

What do you do when you want to read content of a command like |top|? There are two issues with it:

1. There is no way of knowing the title of a column without first
   navigating to the headers. I want to be able to go to the
   next/previous column, know the title of a column, etc.
2. The output keeps changing. For example, while I’m reading one line,
   its CPU usage might drop and cause it to be reordered in the list.

How do you get through these issues?

Thanks!

​
_______________________________________________
Speakup mailing list
Speakup@xxxxxxxxxxxxxxxxx
http://linux-speakup.org/cgi-bin/mailman/listinfo/speakup

--
--
John G. Heim; jheim@xxxxxxxxxxxxx; sip://jheim@xxxxxxxxxxxxxxxx

_______________________________________________
Speakup mailing list
Speakup@xxxxxxxxxxxxxxxxx
http://linux-speakup.org/cgi-bin/mailman/listinfo/speakup




[Index of Archives]     [Linux for the Blind]     [Fedora Discussioin]     [Linux Kernel]     [Yosemite News]     [Big List of Linux Books]
  Powered by Linux