| SNMP::Info::Layer2::HP4000(3pm) | User Contributed Perl Documentation | SNMP::Info::Layer2::HP4000(3pm) |
SNMP::Info::Layer2::HP4000 - SNMP Interface to older HP ProCurve Switches (1600, 2400, 2424M, 4000 and 8000)
Max Baker
# Let SNMP::Info determine the correct subclass for you.
my $hp = new SNMP::Info(
AutoSpecify => 1,
Debug => 1,
DestHost => 'myswitch',
Community => 'public',
Version => 2
)
or die "Can't connect to DestHost.\n";
my $class = $hp->class();
print "SNMP::Info determined this device to fall under subclass : $class\n";
Provides abstraction to the configuration information obtainable from a HP ProCurve Switch via SNMP.
Note: Some HP Switches will connect via SNMP version 1, but a lot of config data will not be available. Make sure you try and connect with Version 2 first, and then fail back to version 1.
The last five MIBs listed are from HP and can be found at <http://www.hp.com/rnd/software> or <http://www.hp.com/rnd/software/MIBs.htm>
Version 0.4 - Removed ENTITY-MIB e_*() methods to separate sub-class - SNMP::Info::Entity
These are methods that return scalar value from SNMP
%MODEL_MAP = (
'J4093A' => '2424M',
'J4110A' => '8000M',
'J4120A' => '1600M',
'J4121A' => '4000M',
'J4122A' => '2400M',
'J4122B' => '2424M',
);
See documentation in "GLOBALS" in SNMP::Info::Layer2 for details.
See documentation in "GLOBALS" in SNMP::Info::MAU for details.
These are methods that return tables of information in the form of a reference to a hash.
Example:
my $interfaces = $hp->interfaces();
my $vlans = $hp->i_vlan_membership();
foreach my $iid (sort keys %$interfaces) {
my $port = $interfaces->{$iid};
my $vlan = join(',', sort(@{$vlans->{$iid}}));
print "Port: $port VLAN: $vlan\n";
}
Returns ("ifIndex") for both key and value for 1600, 2424, 4000, and 8000 models since they seem to have problems with BRIDGE-MIB
See documentation in "TABLE METHODS" in SNMP::Info::Layer2 for details.
See documentation in "TABLE METHODS" in SNMP::Info::MAU for details.
These are methods that provide SNMP set functionality for overridden methods or provide a simpler interface to complex set operations. See "SETTING DATA VIA SNMP" in SNMP::Info for general information on set operations.
| 2023-09-30 | perl v5.36.0 |