topology.conf(5)
β¨ NAME β¨
okay so bestie, you've opened topology.conf(5) β Slurm's Configuration File β and honestly? it's the network-topology glow-up file, topology.conf π
πΈ DESCRIPTION πΈ
topology.conf is an ASCII file that describes your cluster's network topology so Slurm can do optimized job resource allocation. no cap, that's the whole point.
This file always lives in the same directory as the slurm.conf. periodt.
β οΈ NOTE: this file gets completely ignored if topology.yaml(5) exists. like, it doesn't even get a second glance. π
- Parameter names are case insensitive (she does not care about your Caps Lock energy π«Ά).
- Any text following a
#is a comment through the end of that line. ice that whole line out. - Changes to the config file take effect when:
- you restart the Slurm daemons, or
- a daemon receives the
SIGHUPsignal, or - you run
scontrol reconfigure
β¦unless otherwise noted. iykyk.
wanna go deeper? the topology guide lives here and it's lowkey required reading: <https://slurm.schedmd.com/topology.html>
π³ topology/tree π³
This plugin requires you to use the select/cons_tres plugin. no substitutions, bestie.
The network topology configuration: each line defines a switch name and its children β and those children are either node names or switch names. Slurm's hostlist expression parser is doing the parsing, so your node and switch names do not need to be consecutive. for example, Nodes=tux[0-3,12,18-20] and Switches=s[0-2,4-8,12] will parse just fine, slay. β¨
You can also throw in an optional link speed if you're feeling fancy.
Now the rules, and listen up:
- All nodes in the network must be connected to at least one switch.
- The network must be fully connected to use
TopologyParam=RouteTree. - Jobs can only span nodes connected by the same switch fabric β even if there are idle nodes just vibing in other areas of the cluster. sorry babe, that's the topology β
Also!! if you've got an Infiniband switch, your topology.conf can be auto-generated with the slurmibtopology tool, found right here: <https://github.com/OleHolmNielsen/Slurm_tools/tree/master/slurmibtopology>
The overall configuration parameters available for topology/tree include:
SwitchNameβ the name of a switch. This name is internal to Slurm and arbitrary β call it whatever, she's not judging. But each switch needs a unique name. This field must be specified and cannot be longer than 64 characters. πSwitchesβ the child switches of the named switch. (so a switch can have switch babies π₯Ή)Nodesβ the child nodes of the named leaf switch. πLinkSpeedβ an optional value specifying the performance of this communication link. The units are arbitrary and honestly this info is currently not used. it may be used in the future to optimize resource allocations, so she's just sitting there, main character in waiting π
π§± topology/block π§±
The network topology configuration here: each line defines a block name and its children node names. Again, Slurm's hostlist expression parser is on the job, so node names need not be consecutive (e.g. Nodes=tux[0-3,12,18-20]). π
This plugin is obsessed (affectionate) with reducing fragmentation of the cluster. It lets jobs take advantage of lower-latency connections between smaller "blocks" of nodes β rather than just starting jobs as fast as possible on the first available resources. it's giving thoughtful.
Here's the tea on how it works: defined blocks of nodes are paired with other contiguous blocks, which creates a higher level block of nodes. Those larger blocks can then be paired with other blocks at the same level, building bigger and bigger blocks of contiguous nodes with optimized communication between them. π¦
The enforced block sizes are defined by BlockSizes.
The overall configuration parameters available for topology/block include:
BlockNameβ the name of a block. This name is internal to Slurm and arbitrary. Each block should have a unique name. This field must be specified. no skipping.Nodesβ the child nodes of the named block. π«ΆBlockSizesβ a list of the planning base block size, alongside any higher-level block sizes that would be enforced. Each block must have at least the planning base block size count of nodes. And heads up: successiveBlockSizesmust be a power of two larger than the prior values. math is math π’
π topology/ring π
This plugin models the cluster as one or more ordered rings of nodes. Jobs are allocated using contiguous segments of nodes in the ring β and yes, those segments may wrap at the end of the ring. it's a circle, bestie π
The network topology configuration: each line defines a ring name and its child node names. Slurm's hostlist expression parser is doing the work again, so node names need not be consecutive (e.g. Nodes=tux[0-3,12,18-20]). the order of the nodes in the list defines the ring position, starting at 0. β¨
The overall configuration parameters available for topology/ring include:
RingNameβ the name of a ring. This name is internal to Slurm and arbitrary. Each ring should have a unique name. This field must be specified.Nodesβ an ordered list of child nodes in the ring. A maximum of 16 nodes can be specified per ring. 16. that's the limit. don't try it π
π© topology/torus3d π©
The torus3d plugin can only be configured via topology.yaml(5). It is not supported in topology.conf. π
See topology.yaml(5) for configuration details β that's where the torus lives now.
π EXAMPLE π
the tree vibe π³:
##################################################################
# Slurm's network topology configuration file for use with the
# topology/tree plugin
##################################################################
SwitchName=s0 Nodes=dev[0-5]
SwitchName=s1 Nodes=dev[6-11]
SwitchName=s2 Nodes=dev[12-17]
SwitchName=s3 Switches=s[0-2]
the block vibe π§±:
##################################################################
# Slurm's network topology configuration file for use with the
# topology/block plugin
##################################################################
BlockName=block1 Nodes=node[1-32]
BlockName=block2 Nodes=node[33-64]
BlockName=block3 Nodes=node[65-96]
BlockName=block4 Nodes=node[97-128]
BlockSizes=30,120
the ring vibe π:
##################################################################
# Slurm's network topology configuration file for use with the
# topology/ring plugin
##################################################################
RingName=ring0 Nodes=node[01-08]
RingName=ring1 Nodes=node[09-16]
βοΈ COPYING βοΈ
Copyright (C) 2009 Lawrence Livermore National Security. Produced at Lawrence Livermore National Laboratory (cf, DISCLAIMER). Copyright (C) 2010-2023 SchedMD LLC.
This file is part of Slurm, a resource management program. For details, see <https://slurm.schedmd.com/>.
Slurm is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
Slurm is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
π SEE ALSO π
and that's the whole page bestie!! π this one's from Slurm 26.05, filed under Slurm Configuration File β the topology.conf(5) era, and she ate. go configure your switches, you gorgeous nerd πβ¨π¦
π¦ where this page comes from
- arch rolling: slurm-llnl 26.05.5.1-1 Β· GPL-2.0-or-later
- epel 10: slurm 26.05.5-1.el10_3 Β· GPL-2.0-or-later AND BSD-2-Clause AND BSD-1-Clause
- nixpkgs unstable: slurm 26-05-5-1
- ubuntu stonking: slurm-client 26.05.4-1ubuntu1 Β· GPL-2.0-or-later WITH OpenSSL exception
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms