SNMP::...Bayhub(3pm)

πŸ’– NAME πŸ’–

SNMP::Info::Layer1::Bayhub β€” the SNMP interface to Bay/Nortel/Avaya Hubs, bestie. This is page SNMP::...Bayhub(3pm) from the User Contributed Perl Documentation, and it's here to help you talk to your hub. πŸŽ€


✨ AUTHOR ✨

Eric Miller. That's the icon, that's the legend, that's who wrote this. πŸ‘‘


πŸ¦‹ SYNOPSIS πŸ¦‹

Okay so, first thing β€” let SNMP::Info figure out the correct subclass for you, you don't have to do it yourself:

#Let SNMP::Info determine the correct subclass for you.

my $bayhub = new SNMP::Info(
                      AutoSpecify => 1,
                      Debug       => 1,
                      DestHost    => 'myswitch',
                      Community   => 'public',
                      Version     => 2
                    )

or die "Can't connect to DestHost.\n";

my $class = $bayhub->class();
print "SNMP::Info determined this device to fall under subclass : $class\n";

(No, the missing semicolon is not a typo we made, and no, we are not "fixing" it. It's giving exactly-what-the-manpage-says energy. πŸ’…)


🌸 DESCRIPTION 🌸

So basically, this module gives you an abstraction over all the configuration info you can pull off a Bay hub device via SNMP. And as a lil bonus it also gives you device MAC ➑️ port mapping through the proprietary MIB. Slay. ✨

🫢 Inherited Classes

  • SNMP::Info::Layer2
  • SNMP::Info::NortelStack
  • SNMP::Info::SONMP

🫢 Required MIBs

  • S5-ETHERNET-COMMON-MIB
  • S5-COMMON-STATS-MIB

🫢 Inherited MIBs

Like, these ones come from the parents, okay?

  • See "Required MIBs" in SNMP::Info::Layer2 for its MIB requirements.
  • See "Required MIBs" in SNMP::Info::NortelStack for its MIB requirements.
  • See "Required MIBs" in SNMP::Info::SONMP for its MIB requirements.

πŸ’œ GLOBALS πŸ’œ

These are methods that return a scalar value from SNMP. Scalar, not table. Important distinction, iykyk.

  • $bayhub->vendor() β€” returns 'avaya'
  • $bayhub->os() β€” returns 'bay_hub'
  • $bayhub->model() β€” cross references $bayhub->id() to the SYNOPTICS-MIB and returns the results. It also removes either Baystack Hub, 5000, or 5005 depending on the model.

🌈 Overrides

  • $bayhub->layers() β€” returns 00000011. The class emulates Layer 2 functionality through proprietary MIBs. Periodt.
  • $bayhub->index_factor() β€” required by SNMP::Info::SONMP. It's a number representing the number of ports reserved per slot within the device MIB. Returns 256.
  • $bayhub->slot_offset() β€” also required by SNMP::Info::SONMP. It's the offset in case slot numbering does not start at 0. Returns 0.

🌈 Globals imported from SNMP::Info::Layer2

See "GLOBALS" in SNMP::Info::Layer2 for details.

🌈 Global Methods imported from SNMP::Info::NortelStack

See "GLOBALS" in SNMP::Info::NortelStack for details.

🌈 Global Methods imported from SNMP::Info::SONMP

See "GLOBALS" in SNMP::Info::SONMP for details.


πŸ”₯ TABLE METHODS πŸ”₯

These are methods that return tables of information in the form of a reference to a hash. Table szn fr fr.

πŸ‘‘ Overrides

  • $bayhub->i_index() β€” returns a reference to a map of IIDs to Interface index. Now here's the tea: since hubs do not support "ifIndex", the interface index gets created using the formula (board * 256 + port).
  • $bayhub->interfaces() β€” returns a reference to a map of IIDs to physical ports.
  • $bayhub->i_duplex() β€” returns half, because hubs do not support full duplex. Not us being dramatic, that's just the hardware.
  • $bayhub->i_duplex_admin() β€” returns half, same deal: hubs do not support full duplex.
  • $bayhub->i_speed() β€” returns interface speed.
  • $bayhub->i_up() β€” returns ("s5EnPortLinkStatus") for each port, and translates on/off to up/down. So cute, it's bilingual. πŸ’–
  • $bayhub->i_up_admin() β€” returns ("s5EnPortPartStatus") for each port.
  • $bayhub->set_i_up_admin(state, ifIndex) β€” sets the port state. You must supply both the state and the port "ifIndex".

State choices are 'up' or 'down'.

Example:

my %if_map = reverse %{$bayhub->interfaces()};
$bayhub->set_i_up_admin('down', $if_map{'1.1'})
    or die "Couldn't change port state. ",$bayhub->error(1);
  • $bayhub->bp_index() β€” simulates the bridge MIB by returning a reference to a hash containing the index for both the keys and the values.
  • $bayhub->fw_port() β€” returns a reference to a map of IIDs of the "S5-COMMON-STATS-MIB::s5CmSNodeTable" to the Interface index.
  • $bayhub->fw_mac() β€” ("s5CmSNodeMacAddr")

🧚 Pseudo ENTITY-MIB Information 🧚

Lowkey important heads up: these devices do not support ENTITY-MIB. So instead, these methods emulate Physical Table methods using S5-CHASSIS-MIB. See "TABLE METHODS" in SNMP::Info::NortelStack for details.

  • $bayhub->e_index() β€” returns ns_e_index().
  • $bayhub->e_class() β€” returns ns_e_class().
  • $bayhub->e_descr() β€” returns ns_e_descr().
  • $bayhub->e_name() β€” returns ns_e_name().
  • $bayhub->e_fwver() β€” returns ns_e_fwver().
  • $bayhub->e_hwver() β€” returns ns_e_hwver().
  • $bayhub->e_parent() β€” returns ns_e_parent().
  • $bayhub->e_pos() β€” returns ns_e_pos().
  • $bayhub->e_serial() β€” returns ns_e_serial().
  • $bayhub->e_swver() β€” returns ns_e_swver().
  • $bayhub->e_type() β€” returns ns_e_type().
  • $bayhub->e_vendor() β€” returns ns_e_vendor().

🧚 Table Methods imported from SNMP::Info::Layer2

See "TABLE METHODS" in SNMP::Info::Layer2 for details.

🧚 Table Methods imported from SNMP::Info::NortelStack

See "TABLE METHODS" in SNMP::Info::NortelStack for details.

🧚 Table Methods imported from SNMP::Info::SONMP

See "TABLE METHODS" in SNMP::Info::SONMP for details.


And that's the whole page, bestie, you ate it. πŸ’…βœ¨ This lil masterpiece is living in perl v5.40.1, dated 2026-02-28, and it's gonna carry you through every Bay hub in your life. Go read it again if you need to, no shame in it, we've all been there. πŸ«ΆπŸ’–πŸ¦‹

πŸ“¦ where this page comes from