vendstat(8)

πŸ’« vendstat(8) πŸ’«

okay bestie, welcome to vendstat(8), brought to you by the good people over at Open IB Diagnostics β€” the manual page you're reading right now was born on 2017-08-21, and yes we're getting to that. sit down, grab a boba, and let's talk vendor MADs. πŸ§‹βœ¨


🌸 NAME 🌸

vendstat β€” query InfiniBand vendor specific functions

like, literally in the name. it's giving "I ask the hardware questions the spec forgot to write down." πŸ’…


✨ SYNOPSIS ✨

vendstat [options] <lid|guid>

that's it. that's the whole vibe. options go in, plus a lid or a guid, and the chat begins. 🫢


πŸ¦‹ DESCRIPTION πŸ¦‹

okay so here's the tea β˜•: vendstat uses vendor specific MADs to access vendor specific functionality that goes beyond the IB spec. it's the backstage pass of InfiniBand tooling, no cap.

and currently (emphasis on currently, this is a living situation) there is support for Mellanox InfiniSwitch-III (IS3) and InfiniSwitch-IV (IS4). those two. that's the guest list. πŸ‘‘


πŸ’… OPTIONS πŸ’…

the fun ones πŸŽ€

  • -N β€” show IS3 or IS4 general information. the "hey bestie, tell me about yourself" flag.
  • -w β€” show IS3 port xmit wait counters. the counters that are all about waiting. relatable, honestly. 😭
  • -i β€” show IS4 counter group info.
  • -c <num,num> β€” configure IS4 counter groups.

and now the -c lore, because there's layers to this one πŸ‘‡

Configure IS4 counter groups 0 and 1. Such configuration is not persistent across IS4 reboot β€” so like, this is a temporary fit, not a personality change. ⚠️ First number is for counter group 0 and second is for counter group 1.

Group 0 counter config values:

  • 0 - PortXmitDataSL0-7
  • 1 - PortXmitDataSL8-15
  • 2 - PortRcvDataSL0-7

Group 1 counter config values:

  • 1 - PortXmitDataSL8-15
  • 2 - PortRcvDataSL0-7
  • 8 - PortRcvDataSL8-15
  • -R, --Read <addr,mask> β€” Read configuration space record at addr
  • -W, --Write <addr,val,mask> β€” Write configuration space record at addr

writing config space? highkey powerful. be normal about it. 😌


🧭 Addressing Flags

  • -G, --Guid β€” The address specified is a Port GUID
  • -L, --Lid β€” The address specified is a LID
  • -s, --sm_port <smlid> β€” use 'smlid' as the target lid for SA queries.

πŸšͺ Port Selection flags

  • -C, --Ca <ca_name> β€” use the specified ca_name.
  • -P, --Port <ca_port> β€” use the specified ca_port.
  • -Y, --pkey-idx <idx> β€” P_Key table index (0-65535, default 0) used for the outgoing SA/GMP MADs. SMP (SMI directed-route/LID-routed) MADs always use P_Key index 0. no exceptions, periodt.

🏠 Local port Selection

Multiple port/Multiple CA support: when no IB device or port is specified (see the "local umad parameters" below), the libibumad library selects the port to use by the following criteria:

  1. the first port that is ACTIVE.
  2. if not found, the first port that is UP (physical link up).

If a port and/or CA name is specified, the libibumad library attempts to fulfill the user request, and will fail if it is not possible. no vibe-check passes, sorry. πŸ˜…

For example:

ibaddr                 # use the first port (criteria #1 above)
ibaddr -C mthca1       # pick the best port from "mthca1" only.
ibaddr -P 2            # use the second (active/up) port from the first available IB device.
ibaddr -C mthca0 -P 2  # use the specified port only.

πŸ› Debugging flags

  • -d β€” raise the IB debugging level. May be used several times (-ddd or -d -d -d).
  • -e β€” show send and receive errors (timeouts and others). ooh, the receipts. πŸ”₯
  • -h, --help β€” show the usage message
  • -v, --verbose β€” increase the application verbosity level. May be used several times (-vv or -v -v -v)
  • -V, --version β€” show the version info.

βš™οΈ Configuration flags

  • -t, --timeout <timeout_ms> β€” override the default timeout for the solicited mads.
  • --config, -z <config_file> β€” Specify alternate config file. Default: /etc/infiniband-diags/ibdiag.conf

πŸ“ FILES πŸ“

CONFIG FILE

/etc/infiniband-diags/ibdiag.conf

A global config file is provided to set some of the common options for all tools. See supplied config file for details.


🌈 EXAMPLES 🌈

this is the part where it all clicks, bestie:

vendstat -N 6           # read IS3 or IS4 general information
vendstat -w 6           # read IS3 port xmit wait counters
vendstat -i 6 12        # read IS4 port 12 counter group info
vendstat -c 0,1 6 12    # configure IS4 port 12 counter groups for PortXmitDataSL
vendstat -c 2,8 6 12    # configure IS4 port 12 counter groups for PortRcvDataSL

look at those. chef's kiss. 🀌


πŸ‘‘ AUTHOR πŸ‘‘

Hal Rosenstock β€” < <hal.rosenstock@gmail.com> >

the icon who wrote this. we stan. 🫢


and that's the whole page, babe. vendstat(8) from Open IB Diagnostics, dated 2017-08-21, page number 8, and now you know vendor MADs better than half the internet. go configure some counter groups. not persistently though β€” it won't survive a reboot, remember?? πŸ’–βœ¨πŸŽ€πŸ¦‹πŸŒΈπŸ’…

πŸ“¦ where this page comes from
  • arch rolling: rdma-core 65.0-1 Β· GPL-2.0-or-later OR LicenseRef-OpenIB.org-BSD-MIT AND GPL-2.0-or-later OR LicenseRef-OpenIB.org-BSD-FreeBSD AND GPL-2.0-or-later OR LicenseRef-Intel-BSD-3-Clause AND GPL-2.0-or-later OR LicenseRef-PathScale-BSD-Patent-License AND CC0-1.0 AND MIT AND BSD-2-Clause AND CPL-1.0 OR BSD-2-Clause OR GPL-2.0-or-later
  • ubuntu stonking: infiniband-diags 64.0-1ubuntu1 Β· BSD-MIT OR GPL-2.0-only
  • πŸ’– girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms