I’ll second that – we have a cluster with 4 generations of nodes. We assign a processor type feature to each node and require the users to ask for at least one of those features in their jobs via job_submit.lua – see the code below. For a job that can run on any processor type, you can use this:
#SBATCH --constraint=[wes|san|has|bro]
See the constraint section of “man sbatch” for more details but this will constrain the job to any processor type but all nodes of one type. It really works great from a utilization standpoint – jobs will run on the first processor type that is free.
local feature_count = 0
if job_desc ~= nil and job_desc.features ~= nil then
if string.match(job_desc.features, "wes") then feature_count=feature_count+1 end
if string.match(job_desc.features, "san") then feature_count=feature_count+1 end
if string.match(job_desc.features, "has") then feature_count=feature_count+1 end
if string.match(job_desc.features, "bro") then feature_count=feature_count+1 end
end
if feature_count > 0 then
slurm.log_info("Found %s valid cpu features",feature_count)
else
slurm.log_user("Invalid features - aerolab policy requires specifying one or more of wes,san,has,bro.")
slurm.log_error("Found %s cpu features from %s",feature_count,submit_uid)
-- See slurm/slurm_errno.h and src/common/slurm_errno.c
-- for the list of error codes and messages.
return 2002
end
Of course, the user can leave off the square brackets and get any mix of processor types. We have some codes that run fine across different processor types so we allow this. Our group is small enough that we can easily educate and police the users to do the right thing. But you could add more logic to job_submit.lua to require the brackets if you wanted to.
Darby
Thank you all for your answers, I will research some more along these lines!
Any other opinion is welcome
Regards,
Antonio
-- Marcus Wagner, Dipl.-Inf. IT Center Abteilung: Systeme und Betrieb RWTH Aachen University Seffenter Weg 23 52074 Aachen Tel: +49 241 80-24383 Fax: +49 241 80-624383 wag...@itc.rwth-aachen.de www.itc.rwth-aachen.de