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

Re: [HTCondor-users] Adding custom job classads on condor_starter nodes



The way to do this is to set.

    SUBMIT_ATTRS = JobMachineAttrs
    JobMachineAttrs = MACHINE_ID, etc

In your schedd's config.

There is no way to do set attributes into the job using configuration on the execute nodes. 

SYSTEM_JOB_MACHINE_ATTRS is intended for use by HTCondor developers, not for use by system configurators.   It exists so that HTCondor can have defaults for JobMachineAttrs without risking having
those defaults accidently deleted by a submit file or admin.


-tj

-----Original Message-----
From: HTCondor-users [mailto:htcondor-users-bounces@xxxxxxxxxxx] On Behalf Of Iain Bradford Steers
Sent: Monday, September 5, 2016 6:01 AM
To: HTCondor-Users Mail List <htcondor-users@xxxxxxxxxxx>
Subject: Re: [HTCondor-users] Adding custom job classads on condor_starter nodes

There's two ways of doing this. One is a feature called match expressions.

This happens from the job side. For example, using SUBMIT_ATTRS of the job router:

"$$(DATACENTRE:meyrin)"

Means if the machine ad has a datacentre attribute, copy it into the job ad. Else default to meyrin.

These will appear in the job ad as:

match_exp_datacentre = "meyrin"
match_datacentre = "meyrin"

Alternatively the nicer approach coming from the worker node side is SYSTEM_JOB_MACHINE_ATTRS.

This is a config option set on the worker node side.

"This macro specifies a space and/or comma separated list of machine attributes that should be recorded in the job ClassAd. The default attributes are Cpus and SlotWeight. When there are multiple run attempts, history of machine attributes from previous run attempts may be kept. The number of run attempts to store is specified by the configuration variable SYSTEM_JOB_MACHINE_ATTRS_HISTORY_LENGTH. A machine attribute named X will be inserted into the job ClassAd as an attribute named MachineAttrX0. The previous value of this attribute will be named MachineAttrX1, the previous to that will be named MachineAttrX2, and so on, up to the specified history length. A history of length 1 means that only MachineAttrX0 will be recorded. Additional attributes to record may be specified on a per-job basis by using the job_machine_attrs submit file command. The value recorded in the job ClassAd is the evaluation of the machine attribute in the context of the job ClassAd when the condor_sc!
 hedd daemon initiates the start up of the job. If the evaluation results in an Undefined or Error result, the value recorded in the job ClassAd will be Undefined or Error respectively."

Hopefully these should help you.

Cheers, Iain
________________________________________
From: HTCondor-users [htcondor-users-bounces@xxxxxxxxxxx] on behalf of Lukas Koschmieder [Lukas.Koschmieder@xxxxxxxxxxxxxxxxxxx]
Sent: 05 September 2016 12:54
To: HTCondor-Users Mail List
Subject: Re: [HTCondor-users] Adding custom job classads on     condor_starter  nodes

Hi Anthony,

the machine ID is just an example. I'd like to define multiple custom classads.

Regards,
Lukas
________________________________________
From: HTCondor-users [htcondor-users-bounces@xxxxxxxxxxx] on behalf of Anthony Tiradani [tiradani@xxxxxxxx]
Sent: 02 September 2016 15:54
To: HTCondor-Users Mail List
Subject: Re: [HTCondor-users] Adding custom job classads on condor_starter      nodes

Hi Lukas,

Do your running jobs have RemoteHost in their classad?  On my cluster, I see the slot number @ worker host name in RemoteHost.  Would that work for you?

Thanks,

Anthony Tiradani
+1 630 840 4479
tiradani@xxxxxxxx

On 09/02/2016 02:54 AM, Lukas Koschmieder wrote:
> Hi,
>
> Is it possible for condor_starter nodes to add custom classads to 
> their assigned jobs?
>
> For instance, I would like to tell my condor_starter nodes to add 
> their machine IDs to "their" job. These machine IDs should then appear 
> on the condor_schedd node (condor_q -xml).
>
> So basically, I'm looking for a condor_config option similar to:
>
> MACHINE_ID = "123456789"
> STARTER_JOB_ATTRS = $(STARTER_JOB_ATTRS), MACHINE_ID
>
> Cheers,
> Lukas
>
>
> _______________________________________________
> HTCondor-users mailing list
> To unsubscribe, send a message to htcondor-users-request@xxxxxxxxxxx 
> with a
> subject: Unsubscribe
> You can also unsubscribe by visiting
> https://lists.cs.wisc.edu/mailman/listinfo/htcondor-users
>
> The archives can be found at:
> https://lists.cs.wisc.edu/archive/htcondor-users/
>

_______________________________________________
HTCondor-users mailing list
To unsubscribe, send a message to htcondor-users-request@xxxxxxxxxxx with a
subject: Unsubscribe
You can also unsubscribe by visiting
https://lists.cs.wisc.edu/mailman/listinfo/htcondor-users

The archives can be found at:
https://lists.cs.wisc.edu/archive/htcondor-users/
_______________________________________________
HTCondor-users mailing list
To unsubscribe, send a message to htcondor-users-request@xxxxxxxxxxx with a
subject: Unsubscribe
You can also unsubscribe by visiting
https://lists.cs.wisc.edu/mailman/listinfo/htcondor-users

The archives can be found at:
https://lists.cs.wisc.edu/archive/htcondor-users/