You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
function slurm-job-add-timelimit() {
timelimit="$1"
jobids=("${@:2}")
for job in "${jobids[@]}"; do
echo "$job"
scontrol show job $job | grep TimeLimit | awk '{print " Before: " $2}'
scontrol update jobid=$job TimeLimit+="$timelimit"
scontrol show job $job | grep TimeLimit | awk '{print " After: " $2}'
done
}
function slurm-job-check-timelimit() {
jobids=("${@:1}")
for job in "${jobids[@]}"; do
echo "$job"
scontrol show job $job | grep TimeLimit | awk '{print " Time Limit: " $2}'
done
}
The following code could be useful in niche usecases, but it can also force a job to terminate if the input timelimit is shorter than the currently elapsed time.
function slurm-job-set-timelimit() {
timelimit="$1"
jobids=("${@:2}")
for job in "${jobids[@]}"; do
echo "$job"
scontrol show job $job | grep TimeLimit | awk '{print " Before: " $2}'
scontrol update jobid=$job TimeLimit="$timelimit"
scontrol show job $job | grep TimeLimit | awk '{print " After: " $2}'
done
}
The text was updated successfully, but these errors were encountered:
The following code could be useful in niche usecases, but it can also force a job to terminate if the input timelimit is shorter than the currently elapsed time.
The text was updated successfully, but these errors were encountered: