MATLAB: Is it possible to use mixed client-cluster OS with PBSPro with Parallel Computing toolbox 3.3 (R2008a)

linuxmixedparallelParallel Computing Toolboxpsbprowindows

I would like to know if it is possible to use mixed client-cluster OS with PBSPro with Parallel Computing Toolbox 3.3 (R2008a).

Best Answer

Due to difficulties in setting up uniform permissions for PBS Pro clusters involving Windows client machines and UNIX cluster machines, the Parallel Computing Toolbox does not support this configuration. In cases where PBS Pro is set up so that Windows machines can submit directly to a UNIX cluster, the attached files allow submission from the Windows client machines. In this case, it is necessary to have a shared filesystem between the Windows submission machines and the UNIX cluster machines. Also, the “getDebugLog” function of the scheduler object will have reduced functionality because there may be difficulties in delivering the output files from the cluster back to the client machine.
Here are the steps:
1. Find the $MATLABROOT directory where $MATLABROOT is the MATLAB root directory on your machine, as returned by typing
matlabroot
at the MATLAB Command Prompt.
2. Quit MATLAB.
3. Copy the matlabroot\toolbox\distcomp directory for backup and save it as matlabroot\toolbox\distcomp_nopatch where matlabroot has the value of the directory found in step 1.
4. Unzip the archive to extract the files to matlabroot\toolbox\distcomp directory. The following files should be overwritten by the archive:
@distcomp\@pbsscheduler\pSetClusterOsType.m
bin\util\pbs\execute.sh
bin\util\pbs\header.sh
bin\util\pbs\job-array-prologue.sh
bin\util\pbs\nonshared-copyin.sh
bin\util\pbs\nonshared-copyout.sh
bin\util\pbs\pbsParallelWrapper.sh
bin\util\pbs\rcp.sh
5. Restart MATLAB
6. After restarting MATLAB, issue the following command at the MATLAB Command Prompt to test the mixed cluster:
sched = findResource('scheduler','type','pbspro')
DataLocation = struct('pc', 'XXX', ...
'unix','YYY); % where XXX is the Window path to the DataLocation directory for the client and YYY is the Unix or Linux path to the DataLocation directory for the cluster.
set(sched, 'DataLocation', DataLocation);
set(sched, 'HasSharedFileSystem', true);
set(sched, 'ClusterMatlabRoot', 'ML'); %where ML is MATLAB root for cluster
set(sched, 'ClusterOSType', 'unix');
job = createJob(sched);
createTask(job, 'rand', 1, {5})
submit(job)
waitForState(job);
getAllOutputArguments(job)