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

Re: [HTCondor-users] correction: How to change machine availability for job execution?

From: Lee Gramling <leegramling@xxxxxxxxx>
Date: 02/01/2016 10:37 AM

> I am just learning HTcondor and about to setup a job queue with several
> linux machines. I have been reading the user manual and it appears that
> for machines that can execute a job you put parameters into the
> condor_config for that machine.

> If I have several machines that can run jobs but want to be able to make a
> machine unavailable perhaps thru a desktop gui and then make it available
> again later, do I just change the condor_config file locally?

A configuration best practices document would be helpful, I think. For my site, I find that leaving condor_config essentially untouched from the RPM distribution and doing everything in the config.d directory is the best approach.

I number the files in rough categories by 100's, e.g. 000-099 is initialization stuff like the pool name, adminsitrators, etc., 100's are for start _expression_ items, 200 is for machine characteristics, 300 is for job characteristics like submit_exprs, 400 is for hooks, and so on.

You also will be well served to make the identical configuration capable of being used on any system, by using the conditional expressions for the config or defining machine classads based on attributes like the hostname, IP address, or what have you, and then incorporate that into your start _expression_. For example, IsDesktop may depend on the hostname starting with "ws" (for "workstation") using the regexp() ClassAd function, and then your start _expression_ would use that and the time of day to determine whether to accept jobs:

START = $(START) && ifThenElse(! isUndefined(IsDesktop) && IsDesktop =!= False, <time-based _expression_>, True)

... or something along those lines.

        -Michael Pelletier.