- MATLAB and Parallel Computing Toolbox only span across a single node. Calling parpool (or parfor, which will start a parallel pool) using the default local profile will not run across 2 nodes.
- If your nodes have 48 cores and you want to use all 48 cores, you'll want to specify the parallel pool size (i.e. parpool(48)). Otherwise, it will default to the min(12,48) and start a pool of 12 workers.
- If you want to span across several nodes, you'll need to install and use MATLAB Parallel Server, in which case you can simply request a single core, since MATLAB will generate a Slurm job for you requesting, for example, 96 cores. With that said, looking at your license, it doesn't appear that you have MATLAB Parallel Server.
- You can replace "-nodesktop -nosplash -r" with just -batch. If you keep the flags you have, either call exit in test.m or with -r (i.e. -r "test, exit")
- Regarding the license error, I would suggest reaching out to Technical Support (support@mathworks.com). They can help resolve how best to regenerate your license file based on a proper host ID/mac address.
An license error occured when submitting a sbatch routine in slurm
6 views (last 30 days)
Show older comments
Ning Liu
on 26 Nov 2020
Answered: Aiswarya Subramanian
on 2 Dec 2020
Hi, I am a new for slurm. I want to ask for 2 nodes (per nodes with 48 workers) to run my parfor code test.m, however a license error occured, such as:
MATLAB is selecting SOFTWARE OPENGL rendering.
License checkout failed.
License Manager Error -9
The hostid of your computer ("20001107fe80 80615f04fae5 80615f04fae6") does not match the hostid of the license file (20000307fe80).
To run on this computer, you must run the Activation client to reactivate your license.
Troubleshoot this issue by visiting:
https://www.mathworks.com/support/lme/R2020b/9
Diagnostic Information:
Feature: MATLAB
License path: /public/home/hpc175001007/.matlab/R2020b_licenses/license_ln01_8174359_R2020b.lic:/public/home/hpc175001007/MATLAB/R2020b/licenses/license.dat:/public/home/hpc175001007/MATLAB/R2020b/licenses
Licensing error: -9,57.
my test.m is
clear
clc
%parpool(48);
n=10000000;
t1 = clock;
a = zeros(n,1);
parfor i=1:n
a(i) = i;
end
t2 = clock;
ti = etime(t2,t1);
save par_timei ti
and my sbatch routine is
#!/bin/bash
#SBATCH -o Lammps.%j.out
#SBATCH -J matlabJOB
#SBATCH -p cpuQ
#SBATCH --nodes=2
#SBATCH --ntasks-per-node=48
cd /public/home/hpc175001007/workpath/code/
matlab -nodesktop -nosplash -r test
Anyone can help me with this?
0 Comments
Accepted Answer
Raymond Norris
on 2 Dec 2020
A few comments
0 Comments
More Answers (1)
Aiswarya Subramanian
on 2 Dec 2020
Hello!
The best way to resolve a License Manager Error -9 is by reactivating MATLAB with the activation client. Kindly refer to the following link to do this:
-Aiswarya
0 Comments
See Also
Categories
Find more on Cluster Configuration in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!