Skip to content

Commit

Permalink
The SNMP OID for IFName '1.3.6.1.2.1.31.1.1.1.1'returns the interface…
Browse files Browse the repository at this point in the history
… alias. It should return the interface name as 'EthernetXXX'.

What I did:
Change ifName in ifXTable from "EthX(PortY)" to "EthernetXXX".

Why I did it:
Requests that ifName in ifXTable is interface name same as ones showed in "show interfaces status".

How I verified it:
Use snmpwalk command "snmpwalk -v 2c -c public <device_ip> 1.3.6.1.2.1.31.1.1.1.1" to get ifName and front ports' name should be EthernetXXX.
  • Loading branch information
chaoskao committed May 31, 2024
1 parent f652948 commit fed14f8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/sonic_ax_impl/mibs/ietf/rfc2863.py
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ def interface_name(self, sub_id):
elif oid in self.vlan_oid_name_map:
result = self.vlan_oid_name_map[oid]
else:
result = self.if_alias_map[self.oid_name_map[oid]]
result = self.oid_name_map[oid]

return result

Expand Down

0 comments on commit fed14f8

Please sign in to comment.