mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
ios-fdb-table-fix -- Fixed misnamed dictionary keys for dot1dTpFdbPort data (#13559)
This commit is contained in:
@@ -24,11 +24,11 @@ foreach ($vtpdomains as $vtpdomain_id => $vtpdomain) {
|
||||
$portid_dict = [];
|
||||
$dot1dBasePortIfIndex = SnmpQuery::context($vlan_raw, "vlan-$vlan_raw")->walk('BRIDGE-MIB::dot1dBasePortIfIndex')->table(1);
|
||||
foreach ($dot1dBasePortIfIndex as $portLocal => $data) {
|
||||
$port = get_port_by_index_cache($device['device_id'], $data['dot1dBasePortIfIndex']);
|
||||
$port = get_port_by_index_cache($device['device_id'], $data['BRIDGE-MIB::dot1dBasePortIfIndex']);
|
||||
$portid_dict[$portLocal] = $port['port_id'];
|
||||
}
|
||||
|
||||
foreach ((array) $fdbPort_table['dot1dTpFdbPort'] as $mac => $dot1dBasePort) {
|
||||
foreach ((array) $fdbPort_table['BRIDGE-MIB::dot1dTpFdbPort'] as $mac => $dot1dBasePort) {
|
||||
$mac_address = implode(array_map('zeropad', explode(':', $mac)));
|
||||
if (strlen($mac_address) != 12) {
|
||||
d_echo("MAC address padding failed for $mac\n");
|
||||
|
Reference in New Issue
Block a user