Alta Help Center

Alta Switch CLI Diagnostics

Matt Baer
Matt Baer
  • Updated

Alta switches include a diagnostic utility called “diag.” This utility, accessed via SSH or debug terminal, can be used to configure and monitor low-level functionality of the Switch Fabric.

Important Note

Misconfiguration can lead to loss of connectivity, potentially requiring a reboot of the switch back to UI-based configuration.

Using the utility

The diag utility has a shell of its own. In other words, if you execute “diag” alone, you can then enter all of the commands as outlined in this guide. If you would like to run a command directly from the Linux shell, without entering the diag shell, you can enter your diag command like so:

diag "l2-table dump mac-ucast port 8 all"

This will run the l2-table command, and return back to the Linux shell immediately.

Command Persistence

If you would like your manual diag configuration to persist, add the commands to the /cfg/post-cfg.sh file (using the vi editor). Please ensure that your quotes are normal quotes, and not slanted/unicode quotes.

Example post-cfg.sh file:

#!/bin/sh
diag "port set auto-nego port 0 ability 1000f"

Once you are done with your file, always make sure that it is executable:

chmod +x /cfg/post-cfg.sh

The command(s) will then run after every configuration, including after a reboot. If the configuration renders the switch unreachable, you may need to factory reset the switch by holding the reset button down for 5 seconds. As long as the switch has not been deleted in the Alta management platform, it will pick up its most recent UI-based configuration after you click "Set up" on it, even after the factory reset.

Sample Commands

The diag utility has hundreds of potentially useful commands, so we will only focus on some of the most useful here.

Show learned MAC addresses on a specific port:

l2-table dump mac-ucast port 8 all

Show per-port statistics

mib dump counter port 0

Alta Switch Diag Port Mappings

Diag references ports using raw, physical port numbers. For example, on the S12, to dump all learned MAC addresses on Port 2 (according to User Interface), use the command:

l2-table dump mac-ucast port 8 all

S8-POE

UI Port number plus 7

UIDiagUIDiagUIDiagUIDiag
18310512714
29411613815

S16-POE

Generally UI Port number minus 1, except as outlined in red

UIDiagUIDiagUIDiagUIDiag
106511101615
21761211SFP124
32871312SFP226
43981413  
541081514  

S24-POE

Generally UI Port number minus 1, except as outlined in red

UIDiagUIDiagUIDiagUIDiag
108715142221
219816152322
3210917162423
4311101817SFP124
5412111918SFP225
6513122019  
7614132120  

S48-APOE

Generally UI Port number minus 1, except as outlined in red

UIDiagUIDiagUIDiagUIDiag
10131227264148
21141328274249
32151429284350
43161530294451
54171631304542
55181732314643
66191833324746
77201934334847
7821203536SFP152
8922213637SFP253
91023223740SFP354
101124233841SFP455
111225243944  
121326254045  

S12

UIDiagUIDiagUIDiag
10532952
286401053
3167481154
4248501255

IGMP Daemon

Alta Switches include an IGMP multicast daemon named "igmpd." When IGMP Snooping is enabled on a specific VLAN, IGMPv2, IGMPv3, and MLD frames will configure hardware multicast forwarding based on the configurations within the subscriptions and fast-leave frames.

To view the current software state of the subscriptions:

cat /var/run/igmpd-state.json | jq

The hardware state of the subscriptions varies based on the chipset generation, and as such is not documented here. However, raw commands used, and subscription updates in real-time can be gleaned from the debug output of the daemon:

/var/run/igmpd.sh stop
igmpd -d

IGMP Querier

When IGMP Snooping is enabled on a VLAN, Alta Switches will automatically enable an IGMP querier for each VLAN. There is no election process, as each Alta switch will use a random backoff each time they hear another switch send a query. Once a specific switch has started broadcasting IGMP queries, that switch will likely continue to broadcast queries indefinitely, since other switches' back-offs will be much longer once a single switch has been heard.

In order to be considered an IGMP Query, the Group number must be 0 and the Destination IP address must be 224.0.0.1 (for IPv4). 

Related to

Was this article helpful?

0 out of 0 found this helpful

Have more questions? Submit a request

Comments

0 comments

Please sign in to leave a comment.