mersenneforum.org  

Go Back   mersenneforum.org > Extra Stuff > Linux

Reply
 
Thread Tools
Old 2015-09-28, 14:40   #23
Mark Rose
 
Mark Rose's Avatar
 
"/X\(‘-‘)/X\"
Jan 2013

22×733 Posts
Default

I run mprime through screen. screen has the -L switch to log output (in the current working directory where you launch screen). I run screen like this:

screen -LdmS mprime /path/to/mprime.exe -d

This has the added benefit that I can detach, reattach, or share the screen session across multiple terminals. The -d switch tells screen to start detached, the -m switch tells it to terminate the screen when the following command exits, and the -S screen gives the screen session a name (useful when using multiple screen sessions).

I put the screen command in my crontab like so:

@reboot sleep 30; cd /path/to/mprime/dir && screen -LdmS mprime ./mprime.exe -d

Last fiddled with by Mark Rose on 2015-09-28 at 14:40
Mark Rose is offline   Reply With Quote
Old 2015-09-28, 18:23   #24
blip
 
blip's Avatar
 
Jan 2014

2·73 Posts
Default

I use a script /etc/init.d/mprime which fires up mprime and logs to /var/log/mprime.log.
It then restarts automatically on reboot. I connect to my (headless) systems using mosh:
Code:
mosh mprime@hostname byobu
(there is also a user called mprime on my systems) This runs byobu with lots of "screens" (tmux).

Last fiddled with by Batalov on 2015-09-28 at 18:51 Reason: fixed link
blip is offline   Reply With Quote
Reply

Thread Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
Windows concurrent output to the screen and a file. petrw1 Homework Help 14 2018-04-26 22:45
Additional File Output for Visualization Project conere10 Software 7 2011-10-15 23:05
prp output file jasong Sierpinski/Riesel Base 5 1 2005-03-13 05:41
Iterations between results file output? edorajh Software 8 2003-11-20 02:28
Small windows programs to create and delete the stop.txt file for console ver NFSNET dsouza123 Programming 0 2003-09-28 20:40

All times are UTC. The time now is 08:31.


Sat Jul 17 08:31:45 UTC 2021 up 50 days, 6:19, 1 user, load averages: 1.72, 1.65, 1.56

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2021, Jelsoft Enterprises Ltd.

This forum has received and complied with 0 (zero) government requests for information.

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation.
A copy of the license is included in the FAQ.