Larry Martell
Larry Martell

Reputation: 3756

Only run condor jobs if less than RAM threshold is used

I have an execute host with 132 slots and condor will happily run 132 jobs there. But depending on the jobs those 132 can use all the RAM and cause swapping and eventually trashing. How can I set a config option that says, 'do not run jobs if the RAM used is more then nnGB'?

I have read https://htcondor-wiki.cs.wisc.edu/index.cgi/wiki?p=HowToLimitMemoryUsage but it does not say how to do this.

When I say RAM used I am taking about the number I see in the used column in free:

$ free -mh
               total        used        free      shared buff/cache   available
Mem:           125G         44G         18G         19M         63G         79G

Upvotes: 0

Views: 242

Answers (1)

Farrukh
Farrukh

Reputation: 91

When HTCondor does matchmaking, it takes the value of MEMORY into account. This value is adjustable.

For example, you can set the following on your worker node to reserve 2GB:

MEMORY = $(DETECTED_MEMORY) - 2048

Upvotes: 1

Related Questions