#816 skip duplicate bssid on ports on wireless discovery
This commit is contained in:
8
Changes
8
Changes
@@ -1,10 +1,16 @@
|
||||
2.049005 - 2021-09-xx
|
||||
|
||||
[BUG FIXES]
|
||||
|
||||
* #816 skip duplicate bssid on ports on wireless discovery
|
||||
|
||||
2.049005 - 2021-09-09
|
||||
|
||||
[ENHANCEMENTS]
|
||||
|
||||
* #811 change duplicate job status from 'error' to 'info'
|
||||
|
||||
[BUG FIXES
|
||||
[BUG FIXES]
|
||||
|
||||
* #809 fix crash in Node search due to regexp translation perl to SQL
|
||||
|
||||
|
||||
@@ -29,7 +29,7 @@ register_worker({ phase => 'main', driver => 'snmp' }, sub {
|
||||
my $power = $snmp->dot11_cur_tx_pwr_mw;
|
||||
|
||||
# build device ssid list suitable for DBIC
|
||||
my @ssids;
|
||||
my (%ssidseen, @ssids);
|
||||
foreach my $entry (keys %$ssidlist) {
|
||||
(my $iid = $entry) =~ s/\.\d+$//;
|
||||
my $port = $interfaces->{$iid};
|
||||
@@ -46,6 +46,15 @@ register_worker({ phase => 'main', driver => 'snmp' }, sub {
|
||||
next;
|
||||
}
|
||||
|
||||
next unless $ssidmac->{$entry};
|
||||
|
||||
if (exists $ssidseen{$port}{ $ssidmac->{$entry} }) {
|
||||
debug sprintf ' [%s] wireless - duplicate bssid %s on port %s',
|
||||
$device->ip, $ssidmac->{$entry}, $port;
|
||||
next;
|
||||
}
|
||||
++$ssidseen{$port}{ $ssidmac->{$entry} };
|
||||
|
||||
push @ssids, {
|
||||
port => $port,
|
||||
ssid => $ssidlist->{$entry},
|
||||
|
||||
Reference in New Issue
Block a user