DCB-BUFFER(8)
๐ DCB-BUFFER ๐
okay bestie, so this is dcb-buffer from the Linux manual, section 8 โ and it's literally the port buffer settings page for the DCB (Data Center Bridging) subsystem. she's niche, she's powerful, she knows exactly what she's doing. let's get into it ๐ซถ
โจ NAME โจ
dcb-buffer โ show / manipulate port buffer settings of the DCB (Data Center Bridging) subsystem. yes, the whole thing. showing AND manipulating. she does both ๐
๐ธ SYNOPSIS ๐ธ
dcb [ OPTIONS ] buffer { COMMAND | help }
dcb buffer show dev DEV [ prio-buffer ] [ buffer-size ] [ total-size ]
dcb buffer set dev DEV [ prio-buffer PRIO-MAP ] [ buffer-size SIZE-MAP ]
PRIO-MAP := [ PRIO-MAP ] PRIO-MAPPING
PRIO-MAPPING := { PRIO | all }:BUFFER
SIZE-MAP := [ SIZE-MAP ] SIZE-MAPPING
SIZE-MAPPING := { BUFFER | all }:SIZE
PRIO := { 0 .. 7 }
BUFFER := { 0 .. 7 }
SIZE := { INTEGER | INTEGERK | INTEGERM | ... }
likeโฆ look at those little recursive map definitions. PRIO-MAP := [ PRIO-MAP ] PRIO-MAPPING? she's building herself. iconic behaviour honestly ๐
๐ฆ DESCRIPTION ๐ฆ
so dcb buffer is the tool you use to configure which port buffers your traffic gets assigned to, based on traffic priority โ and also how big those buffers are. two jobs, one little command, she's booked and busy.
and because she's generous, she can also do the reverse: peek at the current configuration to see what's set, plus the total device memory that the port buffers are taking up. vibe check on your buffers, basically โจ
๐ PARAMETERS ๐
okay important note first, bestie, don't skip this:
for the read-write parameters, everything below describes only the write direction โ like, how you'd use them with the set command. when you're using the show command, you just drop the parameter name in as a plain keyword with no extra arguments. that's it. no map, no nothing. it tells the tool "show me this one value please".
and when you give no parameters at all, the tool shows you the complete buffer configuration. the whole fit. ๐
total-sizeโ a read-only property that shows the total device memory taken up by port buffers. heads up though: this might be more than a plain sum of the individual buffer sizes, because there might be some hidden or internal buffers lurking in there doing their own thing ๐prio-bufferPRIO-MAPโ this map uses the array parameter syntax (go readdcb(8)for the deets, iykyk). keys are priorities, values are buffer indices. for each priority, it sets the buffer that traffic with that priority gets directed to. so like, priority โ buffer, one for one ๐ซbuffer-sizeSIZE-MAPโ also array parameter syntax, alsodcb(8), same energy. keys are buffer indices, values are the sizes of that buffer in bytes. the sizes can use the notation documented in the PARAMETERS section oftc(8). and ngl, real talk: the size you ask for can get rounded or capped by the driver to satisfy the requirements of the device. so you request a vibe, the driver decides the final number ๐ญ
๐ฅ EXAMPLE & USAGE ๐ฅ
Configure the priomap in a one-to-one fashion:
# dcb buffer set dev eth0 prio-buffer 0:0 1:1 2:2 3:3 4:4 5:5 6:6 7:7
Set sizes of all buffers to 10KB, except for buffer 6, which will have the size 1MB:
# dcb buffer set dev eth0 buffer-size all:10K 6:1M
the all: then the override? that's the move. set the baseline, then single out buffer 6 for the glow-up ๐
Show what was set:
# dcb buffer show dev eth0
prio-buffer 0:0 1:1 2:2 3:3 4:4 5:5 6:6 7:7
buffer-size 0:10Kb 1:10Kb 2:10Kb 3:10Kb 4:10Kb 5:10Kb 6:1Mb 7:10Kb
total-size 1222Kb
look at her. look at the output. every priority mapped, every buffer sized, and the total-size right there at the end being the little summary queen she is ๐
โญ EXIT STATUS โญ
- exit status is
0if the command was successful ๐ซถ - or a positive integer upon failure ๐
๐ SEE ALSO ๐
(yeah, just the one. she's self-referential like that. dcb(8) is the mothership, this page is one of her children ๐ธ)
๐ REPORTING BUGS ๐
found a bug? don't suffer in silence, bestie. report any bugs to the Network Developers mailing list <netdev@vger.kernel.org> โ that's where the development and maintenance is primarily done.
and good news: you do not have to be subscribed to the list to send a message there. so there's genuinely zero excuse. send the mail ๐
๐ง AUTHOR ๐ง
Petr Machata <me@pmachata.org>
and that's the whole page!! this one came from iproute2, dated 12 November 2020 โ so go forth, set your priomaps, size your buffers, and remember: if the driver rounds your size, that's not you failing, that's the device being the main character. periodt ๐ โจ๐ฆ
๐ฆ where this page comes from
- alpine 3.24: iproute2-doc 7.0.0-r0 ยท GPL-2.0-or-later
- arch rolling: iproute2 7.2.0-1
- arch rolling: iproute2 7.3.0-1 ยท GPL-2.0-or-later
- centos-stream 10: iproute 7.0.0-2.el10 ยท GPL-2.0-or-later AND NIST-PD
- nixos 26.05: iproute2 7.0.0
- nixpkgs unstable: iproute2 7.2.0
- ubuntu stonking: iproute2 7.2.0-1ubuntu1 ยท GPL-2.0-only
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms