How can I see the output console after running a nohup command?

MTT picture MTT · Feb 5, 2015 · Viewed 51.6k times · Source

I have a code running on a Linux server. Since it takes hours to run, I have to use nohup to make sure my code is still running in case I loose my connection to the server. Again since I have to wait hours to see the results, I defined a counter to print out the progress of my code (%). If I loose my connection to the server or close the terminal, the only way that I can see the code is still running is using top. Is there any way that I can see again the output console (message showing the progress)?

Answer

yfpb picture yfpb · Nov 17, 2016

You can see the output in real time by running below from another terminal.

tail -f nohup.out