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

[HTCondor-users] CPU Affinity in condor v8.9.1



In Condor (v8.9.1) how do I assign CPU affinity to jobs on the compute
nodes with 24 cores? Let's say I want to limit condor to using 20 cores:
0-19, for users jobs. It should be noted: the cluster is using
partitionable slots.

Bigger picture: I wish to limit condors resources because the compute
nodes run alongside the ceph-osd daemons which I want to 'reserve' a
certain amount of RAM and CPU.

1. I could setup cgroups in systemd to have the condor.service use only
CPUs 0-19. This is obviously outside of condor's config, but presumably
when condor spawns new processes, these will be limited by systemd/cgroups.

2. I see condor has ENCORE+CPU_AFFINITY and SLOT<N>_CPU_AFFINITY macros,
but with the warning "This configuration variable is replaced by
ASSIGN_CPU_AFFINITY".

Naively looking at the documentation, setting SLOT1_CPU_AFFINITY to 0-9
and  SLOT2_CPU_AFFINITY to 10-19 would do what I want.

3. I'm not sure what ASSIGN_CPU_AFFINITY will do, but it seems to assign
cpu affinity based on 'request_cpus'. How would one go about limiting
the jobs to specific cores? (I'm obviously missing something, because in
my mind the user can request whatever cpus they want.)

If someone has some suggestions as to how to assign CPU affinity, it
would be appreciated.

Sincerely,
Shawn
-- 
Associate Scientist
Center for Gravitation, Cosmology, and Astrophysics
University of Wisconsin-Milwaukee
office: +1 414 229 4960
kwangs@xxxxxxx