- Use one of the support packages / add-ins for the different cluster types we integrate with, installed on your local machine. This assumes that your cluster admins have means of supporting this, and a bunch of other things. Most importantly it moves the network connection out of the "job" of updating display -- only the submit/status/data comes back over the wire. As I mentioned earlier, this assumes a number of things about your environment, setup, etc. So it may not be workable for you.
- Instead of running an interactive job from the console, submit jobs using the batch command. This will submit a job to the cluster whose results you can retrieve later. If you lose connection to the cluster you can reconnect/restart and then find the job and check the results.
Using remote matlab on a cluster: Lost connection but job keeps calculating. How to reopen matlab gui?
3 views (last 30 days)
Just lost connection while a script on matlab was running remotely on a linux cluster. I was running it from the remote matlab GUI just like I would do locally. Suddently I lost connection and that window closed, but reconnecting again to the cluster I can see the script keeps running with "top" command. Is there any way to reopen the matlab GUI just where I left it and keep seeing progress on the console?
Jason Ross on 4 Jun 2020
The short answer: you can't get it back. It sounds like it's using X forwarding to send the GUI from the remote machine to your local machine.
As Bjorn Gustavsson says, if you are on a connection that has a high chance of dropping out or being ended somehow, you need to keep the display at the remote end if you want to keep this workflow. For Linux that means VNC (or something very much like it) if you want the GUI, or something like screen (or tmux) if you just want it in the terminal session.
Other approaches that may work: