Apologies if the following questions seem simple, but I'm new to HTCondor and I'm having trouble getting my head around some ideas/problems. In particular, I want to implement a policy on an execute node such that two types of jobs may run:
Job type "A" have an extra classad field inserted via the submit file, let's say:
+IsSpecialJob = True
All other jobs (call them type "B") don't have this extra field. I now want the following policy:
- If a slot is currently running a type A job then it must be left untouched, whatever comes along.
- If a slot is currently running a type B job then any waiting type A job (and only a type A job) can preempt it, as long as the type B job has been allowed to run for a minimum of X seconds.
I'm using dynamic slots under Linux with HTCondor 7.8.8, and the following policy on the execute host fails:
X = 60
KILL = $(ActivityTimer) > $(MaxVacateTime)
WANT_SUSPEND = FALSE
WANT_VACATE = TRUE
MaxJobRetirementTime = $(X)
PREEMPT =((Activity == "Busy") && (State == "Claimed") && ($(ActivityTimer) > 60) && (TARGET.IsSpecialJob != TRUE))
RANK = TARGET.IsSpecialJob == TRUE
One problem is that the RANK _expression_ seems invoke immediate preemption, such that MaxJobRetirementTime is not observed.
Any help gratefully appreciated.