NAME
SNMP::Info::Layer3::Onyx - SNMP Interface to Mellanox/NVIDIA Switches running Onyx
AUTHOR
Hannes Eberhardt
SYNOPSIS
# Let SNMP::Info determine the correct subclass for you.
my $dev = new SNMP::Info(
AutoSpecify => 1,
Debug => 1,
DestHost => 'myswitch',
Community => 'public',
Version => 2
)
or die "Can't connect to DestHost.\n";
my $class = $dev->class();
print "SNMP::Info determined this device to fall under subclass : $class\n";
DESCRIPTION
Provides abstraction to the configuration information obtainable from a Mellanox / NVIDIA switch running Onyx via SNMP. It is chosen for devices whose sysDescr starts with Onyx, and whose sysObjectID is under .1.3.6.1.4.1.33049.1.1.1.
Onyx returns MAC chassis IDs as ASCII text. The inherited LLDP methods accept these as well as binary MAC addresses and select LLDP-MIB or LLDP-V2-MIB as provided by the device.
Inherited Classes
Required MIBs
None beyond those of the inherited classes.
Inherited MIBs
See "Required MIBs" in SNMP::Info::Layer3 and "Required MIBs" in SNMP::Info::PortAccessEntity for their MIB requirements.
GLOBALS
These methods return scalar values from SNMP.
- $dev->vendor()
-
Returns 'mellanox'.
- $dev->os()
-
Returns 'onyx'.
- $dev->os_ver()
-
Returns the OS version from
sysDescr, such as "3.10.4100" from "Onyx,MSN2410,SWv3.10.4100". - $dev->model()
-
Returns the model from
sysDescr, such as "MSN2410", or the inherited model whensysDescrdoes not name one. - $dev->mac()
-
Returns the bridge MAC address.
(
dot1dBaseBridgeAddress)
Overrides
- $dev->layers()
-
Returns the inherited layers with layers 2 and 3 added, or
00000110whensysServicesis unavailable. Onyx servessysServices72 (layers 4 and 7), which omits its bridge and IP capabilities. The layer 3 bit allows callers to collect ARP and IPv6 neighbor data even when IP forwarding is disabled.
Global Methods imported from SNMP::Info::Layer3
See "GLOBALS" in SNMP::Info::Layer3 for details.
Global Methods imported from SNMP::Info::PortAccessEntity
See "GLOBALS" in SNMP::Info::PortAccessEntity for details.
TABLE METHODS
Overrides
- $dev->lldp_if()
-
Returns reference to hash. Key: iid, Value: local ifIndex. Onyx's
lldpRemLocalPortNumis a bridge port number, mapped throughbp_index(). A port with no bridge port row is matched by itslldpLocPortIdtoifName; a neighbor matching neither is left out. For LLDP-V2-MIB, uses the inherited mapping, whose local port number is already an ifIndex. - $dev->c_ip()
-
Returns reference to hash. Key: iid, Value: remote IPv4 address from
lldp_ip(), or 0.0.0.0 for a neighbor that advertises no management address, so it can still be found by itsc_id(). Honors the optional topology protocol list; the placeholder is added only when LLDP is selected.
Table Methods imported from SNMP::Info::Layer3
See "TABLE METHODS" in SNMP::Info::Layer3 for details, including the standard ARP and IPv6 neighbor tables.
Table Methods imported from SNMP::Info::PortAccessEntity
See "TABLE METHODS" in SNMP::Info::PortAccessEntity for details.