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

Re: [HTCondor-users] Per-slot environment variables



Hi Vlad,

Another option is to advertise the desired value in a ClassAd attribute of the slot ad.  The job can be submitted with a command that substitutes this value into the job's environment.  Example:

config file:
SLOT1_CUDA_VISIBLE_DEVICES=0
SLOT2_CUDA_VISIBLE_DEVICES=1
STARTD_EXPRS = $(STARTD_EXPRS) CUDA_VISIBLE_DEVICES

submit file:
environment = "CUDA_VISIBLE_DEVICES=$$(CUDA_VISIBLE_DEVICES)"

That said, it would be nice if STARTER_JOB_ENVIRONMENT could be customized on a per-slot basis.  I'm not aware of a way to do that directly.

--Dan

On 7/5/13 11:13 AM, Brian Bockelman wrote:
You'll probably also want to look at the USER_JOB_WRAPPER (see http://research.cs.wisc.edu/htcondor/manual/v7.6/3_3Configuration.html).  That's going to be easier to configure for some folks.

Brian

On Jul 5, 2013, at 11:07 AM, Tim St Clair <tstclair@xxxxxxxxxx> wrote:

Vlad - 

Condor has so many knobs/bells/whistles, but I think JobHooks - 'Prepare Job' may do what you are looking for.
http://research.cs.wisc.edu/htcondor/manual/v8.0/4_4Hooks.html#43192

Cheers,
Tim



----- Original Message -----
From: "Vladimir Brik" <vladimir.brik@xxxxxxxxxxxxxxxx>
To: htcondor-users@xxxxxxxxxxx
Sent: Friday, July 5, 2013 10:27:29 AM
Subject: [HTCondor-users] Per-slot environment variables

Hello,

Is it possible to define default job environment that will be inherited
by jobs on per-slot basis?

For example, I'd like to automatically set the CUDA_VISIBLE_DEVICES
environmental variable to 0 for slot1, 1 for slot2, etc., , without
having users specify it in the submit file.

I tried STARTER_JOB_ENVIRONMENT, but it looks like it can't be used on
per-slot basis.


Thanks,

Vlad
_______________________________________________
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/