Commit a9e840f3 authored by Andrew McNab's avatar Andrew McNab
Browse files

Rely on HTCondor job wrapper for exporting $JOBFEATURES

parent 263f6ffe
...@@ -68,7 +68,9 @@ be run as part of the HTCondor user job wrapper. If a job wrapper is not ...@@ -68,7 +68,9 @@ be run as part of the HTCondor user job wrapper. If a job wrapper is not
already defined, then this can simply be done by setting already defined, then this can simply be done by setting
USER_JOB_WRAPPER=/usr/sbin/mjf-job-wrapper in the HTCondor configuration. USER_JOB_WRAPPER=/usr/sbin/mjf-job-wrapper in the HTCondor configuration.
If a job wrapper is already being used, then it must be modified to run If a job wrapper is already being used, then it must be modified to run
/usr/sbin/make-jobfeatures in the way mjf-job-wrapper does. /usr/sbin/make-jobfeatures in the way mjf-job-wrapper does,
including exporting $JOBFEATURES and $MACHINEFEATURES to the job itself
and removing the $JOBFEATURES directory when the job finishes.
$JOBFEATURES/hs06_job is calculated from $MACHINEFEATURES/hs06 with a pro-rata $JOBFEATURES/hs06_job is calculated from $MACHINEFEATURES/hs06 with a pro-rata
share for the job in question, based on $JOBFEATURES/allocated_cpu which is share for the job in question, based on $JOBFEATURES/allocated_cpu which is
......
...@@ -43,10 +43,10 @@ ...@@ -43,10 +43,10 @@
# the htcondor-jobfeatures Python script to create $JOBFEATURES # the htcondor-jobfeatures Python script to create $JOBFEATURES
# #
# This script outputs the value of $JOBFEATURES. This variable # This script outputs the value of $JOBFEATURES.
# should be coming from /etc/profile/mjf.[c]sh too!
export JOBFEATURES=`/usr/sbin/make-jobfeatures` export JOBFEATURES=`/usr/sbin/make-jobfeatures`
# This variable should be coming from /etc/profile/mjf.[c]sh too!
if [ -d /etc/machinefeatures ] ; then if [ -d /etc/machinefeatures ] ; then
export MACHINEFEATURES=/etc/machinefeatures export MACHINEFEATURES=/etc/machinefeatures
fi fi
......
mjf_tmp_dir=/tmp
if ( -r /etc/sysconfig/mjf ) then
source /var/sysconfig/mjf
endif
if ( -r /var/run/mjf ) then
source /var/run/mjf
endif
if ( -d /etc/machinefeatures ) then if ( -d /etc/machinefeatures ) then
setenv MACHINEFEATURES /etc/machinefeatures setenv MACHINEFEATURES /etc/machinefeatures
endif endif
mjf_tmp_dir=/tmp
if [ -r /etc/sysconfig/mjf ] ; then
. /etc/sysconfig/mjf
fi
if [ -r /var/run/mjf ] ; then
. /etc/sysconfig/mjf
fi
if [ -d /etc/machinefeatures ] ; then if [ -d /etc/machinefeatures ] ; then
export MACHINEFEATURES=/etc/machinefeatures export MACHINEFEATURES=/etc/machinefeatures
fi fi
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment