Monday, April 29, 2024
1
rated 0 times [  1] [ 0]  / answers: 1 / hits: 381  / 2 Years ago, fri, october 28, 2022, 1:23:09

I have an Perl script that runs all night, through a terminal window (Win10 putty.exe) on my Ubuntu server. As with many home networks, I occasionally lose my internet connection, which kills my connection and the script.


Running another Perl script through cron (which checks if my script is running), I am able to restart the Perl script.


However it is running without a window.


Is there a method that when I putty into Ubuntu, I can open a terminal window that shows the output from my Perl script which is now running?


Thank you.


More From » command-line

 Answers
4

You can redirect the output from the cron script to a file >> /path/filename.log


Or start the script with screen: screen -Sdm perl /path/to/script.pl


[#2090] Friday, October 28, 2022, 2 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
motivengry

Total Points: 459
Total Questions: 112
Total Answers: 108

Location: Bonaire
Member since Sat, May 1, 2021
3 Years ago
motivengry questions
Tue, Oct 4, 22, 10:02, 2 Years ago
Wed, May 31, 23, 14:33, 12 Months ago
Tue, Jan 25, 22, 17:08, 2 Years ago
;