Skip to content

Commit

Permalink
doc: improve run host ranking docs
Browse files Browse the repository at this point in the history
  • Loading branch information
oliver-sanders committed Jan 20, 2025
1 parent 2cf06ed commit 9d3aeeb
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions cylc/flow/cfgspec/globalcfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -843,6 +843,11 @@ def default_for(
Conf('ranking', VDR.V_STRING, desc=f'''
Rank and filter run hosts based on system information.
By default, when a workflow is started, Cylc will pick a host
for it to run on at random from :cylc:conf:`[..]available`.
If no hosts are specified in :cylc:conf:`[..]available` it
will start the scheduler locally.
Ranking can be used to provide load balancing to ensure no
single run host is overloaded. It also provides thresholds
beyond which Cylc will not attempt to start new schedulers on
Expand All @@ -867,6 +872,11 @@ def default_for(
# rank hosts by 15min average of server load
getloadavg()[2]
# rank hosts by the amount of available RAM (multiply by -1
# to make it choose the host with the most available memory
# rather than the least)
-1 * virtual_memory().available
# rank hosts by the number of cores
# (multiple by -1 because the lowest value is chosen)
-1 * cpu_count()
Expand Down

0 comments on commit 9d3aeeb

Please sign in to comment.