Maui Scheduler

13.3.1 PBS RM Extensions

RM extensions within PBS are utilized by using the '-W' flag. To enable this flag, some versions of PBS must be rebuilt.(NOTE: TORQUE and recent OSCAR distributions come with the flag enabled by default. Most other versions do not.)
The required steps are documented below.

> qterm -t quick #shutdown PBS server (cd to the directory from which you executed the PBS 'configure' at install time) make distclean ./configure <WITH OPTIONS>

create addparam script
(chmod +x addparam)

addparam x S
Note In Maui 3.2.x, only the 'x' parameter needs to be added.

make

(backup current $PBS_HOMEDIR directory contents, NOTE: $PBS_HOMEDIR defaults to /usr/spool/PBS)

> make install

(restore old $PBS_HOMEDIR directory contents)

> pbs_server # restart PBS server

A job's QOS level can then be specified using qsub's '-W' flag, i.e., qsub -W x=iQOS:hi -l nodes=4 ...

(addparam script follows)
------
#!/bin/sh
#script: addparam
#usage: addparam $Parameter [S|L]

NewParameter=$1
ParameterType=x$2

if [ ! -d src/include ]; then
echo "error: `basename $0` src/include doesn't exist, run configure" 1>&2
exit 1
fi

# run make in this directory to pull over the template files
cd src/include
if make
then

if grep -q "\"$NewParameter\"" site_*.h 2>/dev/null; then
echo "parameter $NewParameter previously added"
exit 0
fi
fi

chmod +w site_job_attr_enum.h
echo "
JOB_SITE_ATR_$1,
" >> site_job_attr_enum.h

chmod +w site_job_attr_def.h

if [ $ParameterType = "xS" ]
then
echo "
{ \"$NewParameter\",
decode_str,
encode_str,
set_str,
comp_str,
free_str,
NULL_FUNC,
READ_WRITE,
ATR_TYPE_STR,
PARENT_TYPE_JOB
},
" >> site_job_attr_def.h
else
echo "
{ \"$NewParameter\",
decode_l,
encode_l,
set_l,
comp_l,
free_null,
NULL_FUNC,
READ_WRITE,
ATR_TYPE_LONG,
PARENT_TYPE_JOB
},
" >> site_job_attr_def.h
fi
exit 0