1SNMP::Info::Layer2::HP4U0s0e0r(3C)ontributed Perl DocumeSnNtMaPt:i:oInnfo::Layer2::HP4000(3)
2
3
4

NAME

6       SNMP::Info::Layer2::HP4000 - SNMP Interface to older HP ProCurve
7       Switches (1600, 2400, 2424M, 4000 and 8000)
8

AUTHOR

10       Max Baker
11

SYNOPSIS

13        # Let SNMP::Info determine the correct subclass for you.
14        my $hp = new SNMP::Info(
15                                 AutoSpecify => 1,
16                                 Debug       => 1,
17                                 DestHost    => 'myswitch',
18                                 Community   => 'public',
19                                 Version     => 2
20                               )
21           or die "Can't connect to DestHost.\n";
22
23        my $class      = $hp->class();
24        print "SNMP::Info determined this device to fall under subclass : $class\n";
25

DESCRIPTION

27       Provides abstraction to the configuration information obtainable from a
28       HP ProCurve Switch via SNMP.
29
30       Note:  Some HP Switches will connect via SNMP version 1, but a lot of
31       config data will not be available.  Make sure you try and connect with
32       Version 2 first, and then fail back to version 1.
33
34   Inherited Classes
35       SNMP::Info::Layer2
36       SNMP::Info::MAU
37
38   Required MIBs
39       RFC1271-MIB
40           Included in V2 mibs from Cisco
41
42       HP-ICF-OID
43       HP-VLAN
44           (this MIB new with SNMP::Info 0.8)
45
46       STATISTICS-MIB
47       NETSWITCH-MIB
48       CONFIG-MIB
49
50       The last five MIBs listed are from HP and can be found at
51       <http://www.hp.com/rnd/software> or
52       <http://www.hp.com/rnd/software/MIBs.htm>
53

Change Log

55       Version 0.4 - Removed ENTITY-MIB e_*() methods to separate sub-class -
56       SNMP::Info::Entity
57

GLOBALS

59       These are methods that return scalar value from SNMP
60
61       $hp->cpu()
62           Returns CPU Utilization in percentage.
63
64       $hp->log()
65           Returns all the log entries from the switch's log that are not Link
66           up or down messages.
67
68       $hp->mem_free()
69           Returns bytes of free memory
70
71       $hp->mem_total()
72           Return bytes of total memory
73
74       $hp->mem_used()
75           Returns bytes of used memory
76
77       $hp->model()
78           Returns the model number of the HP Switch.  Will translate between
79           the HP Part number and the common model number with this map :
80
81            %MODEL_MAP = (
82                           'J4093A' => '2424M',
83                           'J4110A' => '8000M',
84                           'J4120A' => '1600M',
85                           'J4121A' => '4000M',
86                           'J4122A' => '2400M',
87                           'J4122B' => '2424M',
88                           );
89
90       $hp->os()
91           Returns hp
92
93       $hp->os_bin()
94           "hpSwitchRomVersion.0"
95
96       $hp->os_ver()
97           Tries to use os_version() and if that fails will try and cull the
98           version from the description field.
99
100       $hp->os_version()
101           "hpSwitchOsVersion.0"
102
103       $hp->serial()
104           Returns serial number if available through SNMP
105
106       $hp->slots()
107           Returns number of entries in $hp->e_name that have 'slot' in them.
108
109       $hp->vendor()
110           hp
111
112       $hp->fan()
113           Returns fan status
114
115       $hp->ps1_status()
116           Power supply 1 status
117
118       $hp->ps2_status()
119           Power supply 2 status
120
121   Globals imported from SNMP::Info::Layer2
122       See documentation in "GLOBALS" in SNMP::Info::Layer2 for details.
123
124   Globals imported from SNMP::Info::MAU
125       See documentation in "GLOBALS" in SNMP::Info::MAU for details.
126

TABLE METHODS

128       These are methods that return tables of information in the form of a
129       reference to a hash.
130
131   Overrides
132       $hp->interfaces()
133           Uses $hp->i_description()
134
135       $hp->i_duplex()
136           Returns reference to map of IIDs to current link duplex.
137
138       $hp->i_duplex_admin()
139           Returns reference to hash of IIDs to admin duplex setting.
140
141       $hp->vendor_i_type()
142           Returns reference to hash of IIDs to HP specific port type
143           ("hpSwitchPortType").
144
145       $hp->i_name()
146           Crosses i_name() with $hp->e_name() using $hp->e_port() and
147           i_alias()
148
149       $hp->i_vlan()
150           Returns a mapping between "ifIndex" and the PVID (default VLAN) or
151           untagged port when using HP-VLAN.
152
153       $hp->i_vlan_membership()
154           Returns reference to hash of arrays: key = "ifIndex", value = array
155           of VLAN IDs.  These are the VLANs which are members of the egress
156           list for the port.  It is the union of tagged, untagged, and auto
157           ports.
158
159             Example:
160             my $interfaces = $hp->interfaces();
161             my $vlans      = $hp->i_vlan_membership();
162
163             foreach my $iid (sort keys %$interfaces) {
164               my $port = $interfaces->{$iid};
165               my $vlan = join(',', sort(@{$vlans->{$iid}}));
166               print "Port: $port VLAN: $vlan\n";
167             }
168
169       $hp->i_vlan_membership_untagged()
170           Returns reference to hash of arrays: key = "ifIndex", value = array
171           of VLAN IDs.  These are the VLANs which are members of the untagged
172           egress list for the port.
173
174       $hp->v_index()
175           Returns VLAN IDs
176
177       $hp->v_name()
178           Returns VLAN names
179
180       $hp->bp_index()
181           Returns reference to hash of bridge port table entries map back to
182           interface identifier (iid)
183
184           Returns ("ifIndex") for both key and value for 1600, 2424, 4000,
185           and 8000 models since they seem to have problems with BRIDGE-MIB
186
187   Table Methods imported from SNMP::Info::Layer2
188       See documentation in "TABLE METHODS" in SNMP::Info::Layer2 for details.
189
190   Table Methods imported from SNMP::Info::MAU
191       See documentation in "TABLE METHODS" in SNMP::Info::MAU for details.
192

SET METHODS

194       These are methods that provide SNMP set functionality for overridden
195       methods or provide a simpler interface to complex set operations.  See
196       "SETTING DATA VIA SNMP" in SNMP::Info for general information on set
197       operations.
198
199       set_i_vlan()
200       set_i_vlan_tagged()
201
202
203
204perl v5.30.1                      2020-01-30     SNMP::Info::Layer2::HP4000(3)
Impressum