ethextractlink(8)

πŸ“¦ version 12.1.0.1, in centos-stream 9, fedora 43, fedora 44, opensuse-leap 16.0

okay bestie, pull up a chair, we're reading the ethextractlink(8) page together and honestly? it's giving useful. this one lives in the EFSFFCLIRG man page set, and by the end you're gonna be making link reports like it's nothing. πŸ¦‹


✨ NAME ✨

ethextractlink

So basically: this girlie produces a CSV file listing all the links in the fabric β€” or just some of them, if you wanna be picky (and you should, we love a filter). πŸ’…

Here's the tea: ethextractlink is a front end to the ethreport tool. So it's not doing the heavy lifting itself, it's just the cute, focused face of ethreport. The output from this tool can be imported into a spreadsheet or parsed by other scripts β€” so like, spreadsheet girlies, script girlies, everyone eats. πŸ“

And lowkey the best part: this script can be used as a sample for creating custom per link reports. So if you wanna build your own version, this is your blueprint, your blueprint era, your template moment. ✨


🌸 Syntax 🌸

ethextractlink [ethreport  options]

that's it. that's the whole vibe. you pass it ethreport options and it goes. πŸŽ€


πŸ‘‘ Options πŸ‘‘

--help

  • --help β€” Produces full help text. that's it, that's the whole job, and she does it flawlessly. no cap. πŸ’–

ethreport options

okay so these next ones get passed to ethreport. This subset is considered typical and useful for this command β€” like, the greatest hits, the ones you'll actually reach for. 🎡

🫢 heads up bestie: By design, the tool ignores the -o/--output report option. Not a bug, not a glitch, she's just built different. That's intentional. Don't fight it.
  • -X, --infile _snapshot_input_ β€” Generates a report using the data in the _snapshot_input_ file. And listen, _snapshot_input_ must have been generated during a previous -o snapshot run, okay? No random files, she will not be fooled. Also: '-' may be used as the _snapshot_input_ to specify stdin. yes bestie, the classic dash move. πŸ”₯
  • -T, --topology _topology_input_ β€” Uses _topology_input_ file to augment and verify fabric information. When used, various reports can be augmented with information not available electronically β€” so like, the stuff the fabric won't tell you itself, this file will. '-' may be used to specify stdin. dash gang rise up. πŸ’€
  • -E, --eth _config_file_ β€” Specifies the Ethernet management configuration file. Default is the /etc/eth-tools/mgt_config.xml file. so if you don't say anything, that's where she's looking. πŸ“
  • -p _plane_ β€” Name of the enabled plane defined in Mgt config file. Default is the first enabled plane. she picks the first one for you if you don't specify β€” convenient, we love a girl who makes decisions. 🌈
  • -F, --focus _point_ β€” Specifies the focus area for report. Used to limit scope of report. Refer to Point Syntax for details. ⭐

πŸ¦‹ Point Syntax πŸ¦‹

okay so this is the section everyone scrolls past and then desperately scrolls back to. the point syntax. it's literally just "how do i tell her which thing i mean." here's every single form, no skips, no cuts, because you deserve the full picture. πŸ’œ

  • ifid:value β€” _value_ is numeric ifid.
  • ifid:value:node β€” _value_ is numeric ifid, selects node with given ifid.
  • ifid:value:port:value2 β€” _value_ is numeric ifid of node, _value2_ is port number.
  • ifid:value:portid:value2 β€” _value_ is numeric ifid of node, _value2_ is port id.
  • mgmtifaddr:value β€” _value_ is numeric port mgmtifaddr.
  • ifaddr:value β€” _value_ is numeric node ifaddr.
  • ifaddr:value1:port:value2 β€” _value1_ is numeric node ifaddr, _value2_ is port number.
  • ifaddr:value1:portid:value2 β€” _value1_ is numeric node ifaddr, _value2_ is port id.
  • chassisid:value β€” _value_ is numeric chassisid.
  • chassisid:value1:port:value2 β€” _value1_ is numeric chassisid, _value2_ is port number.
  • chassisid:value1:portid:value2 β€” _value1_ is numeric chassisid, _value2_ is port id.
  • node:value β€” _value_ is node description (node name).
  • node:value1:port:value2 β€” _value1_ is node description (node name), _value2_ is port number.
  • node:value1:portid:value2 β€” _value1_ is node description (node name), _value2_ is port id.
  • nodepat:value β€” _value_ is glob pattern for node description (node name).
  • nodepat:value1:port:value2 β€” _value1_ is the glob pattern for the node description (node name), _value2_ is port number.
  • nodepat:value1:portid:value2 β€” _value1_ is the glob pattern for the node description (node name), _value2_ is port id.
  • nodedetpat:value β€” _value_ is glob pattern for node details.
  • nodedetpat:value1:port:value2 β€” _value1_ is the glob pattern for the node details, _value2_ is port number.
  • nodedetpat:value1:portid:value2 β€” _value1_ is the glob pattern for the node details, _value2_ is port id.
  • nodetype:value β€” _value_ is node type (SW or NIC).
  • nodetype:value1:port:value2 β€” _value1_ is node type (SW or NIC), _value2_ is port number.
  • nodetype:value1:portid:value2 β€” _value1_ is node type (SW or NIC), _value2_ is port id.
  • rate:value β€” _value_ is string for rate (25g, 50g, 75g, 100g), omits switch mgmt port 0.
  • portstate:value β€” _value_ is a string for state (up, down, testing, unknown, dormant, notactive).
  • portphysstate:value β€” _value_ is a string for PHYs state (other, unknown, operational, standby, shutdown, reset).
  • mtucap:value β€” _value_ is MTU size (maximum size 65535), omits switch mgmt port 0.
  • linkdetpat:value β€” _value_ is glob pattern for link details.
  • portdetpat:value β€” _value_ is glob pattern for port details.
  • nodepatfile:FILENAME β€” Specifies the name of file with the list of nodepats or node descriptions.
  • nodepairpatfile:FILENAME β€” Specifies the name of file with the list of node pairs, separated by a colon.
  • ldr β€” Specifies the ports with a non-zero link down reason or neighbor link down reason.
  • ldr:value β€” Specifies the ports with a link down reason or neighbor link down reason equal to _value_.

πŸ”₯ Examples πŸ”₯

bestie. the examples. the moment you've been waiting for. copy these, run these, slay. πŸ‘‘

# List all the links in the fabric:

ethextractlink

# List all the links to a switch named "coresw1":

ethextractlink -F "node:coresw1"

# List all the links to end-nodes:

ethextractlink -F "nodetype:NIC"

🌟 real talk: those three commands right there? that's the whole vibe of this tool. filter by node, filter by type, or just let her show you everything. go forth and CSV. πŸ’–

and that's the page, bestie! you made it all the way through the point syntax, which honestly means you're built different. πŸ’…

sign-off time πŸŽ€ β€” this was the ethextractlink(8) page from Copyright(C) 2020-2024 Intel Corporation. yes, that's the official copyright line and we're keeping it, no edits, no cap. mwah, go make some beautiful link reports. βœ¨πŸ¦‹πŸ’œ

πŸ“¦ where this page comes from