2
$\begingroup$

New here so apologies if this has been asked and answered before.

I have these Mathematica programs that run for a couple of weeks.

We have a Linux server that has Mathematica on it. I tried connecting to this server via Putty etc. but the connection keeps dropping.

I have a vague memory from years ago (it may have been a Unix based system) of a one line command that would load a Mathematica notebook, read in the contents and run it, and then output the results to a specified Mathematica notebook.

Can anyone tell me if something similar is possible with Linux?

Thanks,

Jimmy

$\endgroup$
15
  • $\begingroup$ I would suggest to use so called vnc servers, when computing on remote Mathematica. In particular, I use TigerVNC (tigervnc.org). Of course to make connection secure, I would suggest to make secure tunnel over ssh. (I could share my setting if your decide to try this way). $\endgroup$
    – Acus
    Commented Oct 31, 2022 at 15:14
  • $\begingroup$ Thanks, I do use a vnc connection and some showed me how to connect remotely to the server. The problem is (probably down to the way my University has configured the network) that the connection keeps dropping. What I would like to be able to do is log in and make the connection, set the program running, log out/break the connection (with the program continuing to run on the server) and then have the output accessible if I log on to the server at some later. I don't know how to do that, or even if it is possible. $\endgroup$ Commented Nov 1, 2022 at 17:30
  • $\begingroup$ Then you could try to run program using program named "screen". It allows to disconnect and reconnect to the program, which was started inside screen. Also vnc allows to reconnect after connection was interrupted. Seems that I cannot understand your problem $\endgroup$
    – Acus
    Commented Nov 2, 2022 at 12:03
  • $\begingroup$ I will try to see if I can get screen working. The way I was using vnc, once the connection got broken, the Mathematica notebook stopped running. $\endgroup$ Commented Nov 4, 2022 at 1:53
  • $\begingroup$ Using vnc server/client approach you in fact run mathematica on remote machine, which presents screen to your local computer. Therefore you can disconnect and reconnect to the remote computer without affecting computations. It means that broken connection cannot affect computation. I think you are using different approach, not vnc . Or you put different meaning to what I call vnc. I myself use vnc for long computations. I often start job at work, then turn off work computer. When at home connect to remote vnc screen from different computer and everything works perfectly. $\endgroup$
    – Acus
    Commented Nov 4, 2022 at 6:11

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.