I have a program (c++) that outputs data to the terminal. I run it on a machine that I SSH to. I need to be able to:
- Run the program after I close my session
- Acess the data that has been output so far, while the program continues to output data.
Right now, I have been doing this:
nohup ./freqnew <testparams.txt &> testrun3.out&
It's almost what I want. It puts the data from the program into the file testrun3.out, and will run in the background after I close my terminal window. However, until the program is finished, the .out file is completely empty.
When I start doing long runs, they could take weeks, but I need to periodically access the data to make sure it's plausible.
Any ideas?