[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [HTCondor-users] Queries regarding htcondor policies



Hi Vikrant,

  1. The use of multiple POLICY configurations should be possible. In the case of multiple PREEMPT policies, all the policies should be OR'ed together automatically and not overwritten. You can check this by running condor_config_val -v PREEMPT
  2. Jobs that trigger the preemption case should just be preempted immediately (i.e. killed and put back to the idle state in the AP job queue). Looking at the two scenarios provided, the hold policy (2) is generating an HTCondor provided hold reason, but the preempt policy (1) is putting the job on hold with a message I do not see in the HTCondor source so I am inclined to think that may be a custom hold reason in your configuration.
Note: You can see what configuration is being set up by the HTCondor predefined configuration templates by running condor_config_val use policy:<policy>

Hope this helps,
Cole Bollig

From: HTCondor-users <htcondor-users-bounces@xxxxxxxxxxx> on behalf of Vikrant Aggarwal <ervikrant06@xxxxxxxxx>
Sent: Sunday, October 15, 2023 1:33 PM
To: HTCondor-Users Mail List <htcondor-users@xxxxxxxxxxx>
Subject: [HTCondor-users] Queries regarding htcondor policies
 
Hello Experts,

using policy examples from [1] on version 9.0.17 

- How to use multiple policies? If I put the policies in the following manner it's ignoring the runtime limit policy, maybe memory policy overwriting it?  

use POLICY : Preempt_if_Runtime_Exceeds(30)
MEMORY_EXCEEDED = (isDefined(MemoryUsage) && MemoryUsage > RequestMemory)
use POLICY : PREEMPT_IF(MEMORY_EXCEEDED)

- What's the difference between Hold_if_Runtime_Exceeds and Preempt_if_Runtime_Exceeds,

In my test both are putting the job on hold, I was expecting the job to be killed in the latter case. Only difference is the Holdreason message. 

Scenario 1: 

use POLICY : Hold_if_Runtime_Exceeds(30)

Message:

Error from slot1_1@xxxxxxxx: Job exceeded pool time limit

Scenario 2:

use POLICY : Hold_if_Runtime_Exceeds(30)

Message: It includes time 30 seconds

Error from slot1_4@xxxxxxxx: runtime exceeded maximum (30 seconds)




Thanks & Regards,
Vikrant Aggarwal