Huawei CE acquires eth-trunk interface and physical member interface pair through OID
Obtain the correspondence between the eth-trunk API and the physical member interface as follows:
Node name
Node meaning
Node OID
Node Typ
Belongs to the MIB file
HwTrunkIfID
This node identifies the Trunk interface number.
1.3.6.1.4.1.2011.5.25.41.1.3.3.1.2
MIB table node
HUAWEI-IF-EXT-MIB
HwTrunkValidEntry
The significant bit flag of the Trunk member port in Trunk.
If a member port has been added to the Trunk, valid (1) is returned.
1.3.6.1.4.1.2011.5.25.41.1.4.1.1.2
MIB table node
HUAWEI-IF-EXT-MIB
IfDescr
The node flag index the corresponding interface number information.
1.3.6.1.2.1.2.2.1.2
MIB table node
IF-MIB
Take CE5850 as an example:
1. Obtain the device trunk interface ID number by walk this hwTrunkIfID node, as follows: eth-trunk 11, interface ID number 1
[~ diagnose] display snmp-agent mib walk 1.3.6.1.4.1.2011.5.25.41.1.3.3.1.2
HwTrunkIfID.0 = INTEGER: 1
HwTrunkIfID.1 = INTEGER: 11
2. Obtain the member port index under the corresponding TRUNK by walk the hwTrunkValidEntry node + ID number of the trunk interface. For example, there are two ports corresponding to ID 1 and two ports with IFINDEX of 5 and 6.
[~ diagnose] display snmp-agent mib walk 1.3.6.1.4.1.2011.5.25.41.1.4.1.1.2.1
HwTrunkValidEntry.1.5 = INTEGER: valid (1)
HwTrunkValidEntry.1.6 = INTEGER: valid (1)
3. Obtain the interface names of the member ports under the TRUNK through the ifDescr node + interface index number. For example, there are two ports corresponding to ID 1 and two ports with IFINDEX of 5 and 6.
[~ diagnose] display snmp-agent mib get 1.3.6.1.2.2.2.2.1.2.5
IfDescr.5 = STRING: GE1/0/1
[~ diagnose] display snmp-agent mib get 1.3.6.1.2.2.2.1.2.6
IfDescr.6 = STRING: GE1/0/2