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

Re: [Condor-users] Feature Request: ability to set processor affinity for a slot



2009/1/8 Ian Chesal <ICHESAL@xxxxxxxxxx>:
[snip]
> I'd like to be able to tell Condor, preferrably on a per-job basis but
> even on a per-slot basis this would be great, to spawn the job command
> with a processor affinity bit mask so the command and any child threads
> from it are locked to a particular processor on a machine (or a
> particular set of processors).
>
> Right now I'm handling this by wrapping my *real* command in a higher
> level command that Condor calls and the wrapper calls my real command
> with a custom executable I've written that sets the processor affinity
> bit mask for the real command.
[snip]

I'm currently also investigating a similar problem to this. I've got a
USER_JOB_WRAPPER script that sets processor affinity based on the
value of the environment variable _CONDOR_SLOT. What I've not yet
managed to figure out is a way to make this integrate with the
RequiresWholeMachine mechanism from http://nmi.cs.wisc.edu/node/1482.

Basically putting
+RequiresWholeMachine = true
in a job submission causes the job to only run on slot1 and other
slots on the machine to be set to owner. Which brings me to my real
question: How can I cause the +RequiresWholeMachine in the job
submission to set an environment variable for the USER_JOB_WRAPPER
script?

I slightly optimistically tried using:
STARTER_JOB_ENVIRONMENT = WHOLE_MACHINE_JOB=$$([$(MY.RequiresWholeMachine)])
Which didn't work, as I suspected.

Any ideas?

Thanks,
Alan