linux - How to save output of "watch" to file -
I want to run one command every 60 seconds and save the output in a logfile. I know that I
clock -n 60 & lt; Mycommand & gt;
But if I want to save it to the file then I will also print for the console?
View is designed to run in the console window.
If you are not having any 60 hour problem, you can try without it:
code> while & lt ; Some condition & gt; & Lt; Mycommand & gt; 2 & gt; And 1. Tee -a / path / to / logfile sleep 60 doneThis saves output in a log file and shows it on the console as well.
Comments
Post a Comment