Answer the question
In order to leave comments, you need to log in
How to redirect output to a file?
There is a program that works as interactive (tty, or pty). In fact, it works like a base top.
prog > up.info
As a result, the file is filled with data
data414
data654
data342
data342
Answer the question
In order to leave comments, you need to log in
For top I would do this
topfile.sh
while true; do
top -b -n 1 > top.log
sleep 2
done
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question