#!/bin/sh # # Cancel job running in Condor # progname=$(basename "$0") echo "----- starting $progname -----" 1>&2 joboption_lrms="condor" lrms_options="condor_requirements condor_rank condor_bin_path condor_config" queue_options="condor_requirements" # ARC1 passes first the config file. if [ "$1" = "--config" ]; then shift; ARC_CONFIG=$1; shift; fi GRAMI_FILE=$1 # define paths and config parser basedir=`dirname $0` basedir=`cd $basedir > /dev/null && pwd` || exit $? . "${basedir}/lrms_common.sh" # load common cancel functions . "${pkgdatadir}/cancel_common.sh" || exit $? # run common init # * parse grami # * parse config # * load LRMS-specific env common_init # run condor_rm echo "$progname: canceling job $joboption_jobid with condor_rm..." 1>&2 $CONDOR_BIN_PATH/condor_rm ${joboption_jobid%.`hostname -f`} 1>&2 echo "----- exiting $progname -----" 1>&2 exit 0