Matlab functions to interface with computer cluster (PU or HU)
Using server_interface.m, you can:
- submit *.slurm files.
- check status of submitted jobs.
- cancel jobs.
- clear output directory (in server/cluster).
- pull files from server/cluster.
- push matlab startup file.
To use this function
- Copy and edit user_defined_directoriestoedit.m (see that file for details), and save as user_defined_directories.m.
- to edit matlab startup in the cluster copy and edit matlabpathtoedit.m and save as matlabpath_spock.m
For examples see: pu_cluster_interface_demo.m or hu_cluster_interface_demo.m
This code in windows requires openssh, installing using scoop Run the following command from your terminal
powershell
iex (new-object net.webclient).downloadstring('https://get.scoop.sh')
set-executionpolicy unrestricted -s cu
scoop openssh
After installing ssh, you need to modify 'ssh_config'. This file is usually at *\scoop\apps\openssh\5.4p1-1\etc\ssh\ssh_config.
Setup passwordless SSH key, see info at Cluster wiki PU or Cluster wiki HU
In ssh_config add/edit the following lines
Host *
IdentityFile 'add path of id_rsa file'
Host 'add short name for host, example 'spock''
User 'add username'
HostName 'add host name'
Port 22
ForwardX11 yes
ForwardX11Trusted yes
IdentityFile 'add path of id_rsa file'