EDIT:
tl;dr: I created a new line on my .que file (and not append to existing PBS -l nodes=1:ppn=8 and it worked!
Hey guys -
Thanks a lot for your help.
I added server_dync_res
on my sched_config
:
server_dyn_res: “my_test_var !/path/to/my/bash”
and also updated the resourcedef
with:
my_test_var type=float flag=h
my_test_var is the output of a basic bash script which return the number of licenses available.
I have restarted PBS but it looks like I’m still missing something.
I tried to submit my job using qsub myJob.que -l my_test_var=500
No matter what value I specify for my_test_var, the job will always run.
I looked at the .que file and noticed I already have a -l parameter:
#!/bin/sh -f
#PBS -N myjob
#PBS -V -j oe -o myjob.qlog
#PBS -m ae
#PBS -q myqueue
#PBS -l nodes=1:ppn=8
cd $PBS_O_WORKDIR
echo "HELLO WORLD"
II tried to add
#PBS -l nodes=1:ppn=8:my_test_var=500
But this time I’m getting an error when submitting the job:
qsub: node(s) specification error
If I remove my_test_variable, then the job will start. So I tried to just change the order to be:
#PBS -l my_test_var=500:nodes=1:ppn=8
This time I’m getting
qsub: Illegal attribute or resource value Resource_List.my_test_var under resources:
So I went back to PBS doc and noticed I have to also specify this variable to sched_config
resources: "my_test_var,ncpus, etc etc ..."
Restarted PBS … but I’m setting getting the same problem.
I guess I need to specify my_test_var somewhere else on PBS config but I haven’t been able to figure out where.
Any pointers?