Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it possible to run matlab on a remote server and control it using the matlab GUI from a thinclient?

Akin to what can be done with emacs with slime: the core services can run on a performace grade remote computer while I can edit and run code from emacs gui on an netbook.

  • Me and my colleagues often need to do some demos using machine learning scripts running in matlab

  • This requires us to carry around heavy laptops.

Could we have the applications running on a remote server and access it using the same matlab gui without running the scripts locally?

Remote desktop or similar solutions are not acceptable: multiple users would like to use the same server.

This is why none of the answers here were helpful

like image 720
PoorLuzer Avatar asked Oct 09 '22 15:10

PoorLuzer


2 Answers

In my experience, the best way is with VNC. You can start a VNC server on the host machine, and then access this desktop remotely from anywhere with a VNC client. You can disconnect and reconnect at another time, and your desktop will still be there. Also, multiple users can all have different sessions going, or can access the same one. If you don't want each session to run a full blown desktop, you can configure it to be minimal. For security, it is recommended to use an SSH tunnel or similar.

The exact programs will vary based on your setup, but the things to google are bolded, above.

My setup is:

  • VNC server: vnc4server on a Ubuntu linux host.
  • VNC client: Chicken of the VNC for mac.
  • SSH tunnel: SSH Tunnel Manager for mac (although this can be done at the command line too).

Good luck!

EDIT: Here is a screenshot of a vncserver session I just started up on our cluster, with matlab running in it. I'm accessing it through the vnc client on my mac. Works great!

enter image description here

like image 180
John Colby Avatar answered Oct 13 '22 01:10

John Colby


SSH with X-window forwarding will do the trick. It will get you the MATLAB screen you know and love but will be running everything on the remote computer. To do this, in a terminal with SSH (I like MobaXterm, though you can use Putty) you ssh via

ssh server.location.here -X

This will get you the terminal on the computer (after typing in a password), and in the terminal just type

matlab

and a MATLAB screen will show up. Note that opengl will be disabled, so your plots might not plot as fast, though you can still use gpu algorithms (i.e. cuda. Note you may need to run the command "COMPUTE=:0" before opening matlab if gpuDevice turns up empty for MATLAB's cuda).

like image 23
Chris Rackauckas Avatar answered Oct 13 '22 00:10

Chris Rackauckas