[ixpmanager] Issue in MAC address discovery with the script for Arista Switch

Nick Hilliard nick at foobar.org
Thu Apr 29 22:44:29 IST 2021


Hi Ahmed,

Ahmed Al-Saruri wrote on 09/04/2021 12:10:
> Hello Nick,
> 
> Yes, I am sure that the MAC address  is consistently present on the 
> switch when the device is polled.
> 
> Attached are the logs from update-l2database.pl when I run it manually.
> 
> Also here is the information from the interface with no flaps or mac 
> changes during this time period.
> 
> columba.del#sh mac address-table int eth3
>            Mac Address Table
> ------------------------------------------------------------------
> 
> Vlan    Mac Address       Type        Ports      Moves   Last Move
> ----    -----------       ----        -----      -----   ---------
> 3210    f4b7.8ddd.02e6    DYNAMIC     Et3        1       2 days, 
> 22:18:46 ago
> Total Mac Addresses for this criterion: 1
> 
> Do you have any suggestions on how to investigate this further?

The only script which deletes anything from the macaddress table is 
update-l2database.pl, which works by using the following sequence of SQL 
commands:

START TRANSACTION
DELETE FROM macaddress
INSERT INTO macaddress (...) VALUES (...)
[...]
INSERT INTO macaddress (...) VALUES (...)
COMMIT

So the only way for a mac address to disappear from this table is if 
update-l2database.pl is executed, and doesn't read the mac address from 
the switch, and then commits what it finds to the database.

This could happen if the MAC address temporarily disappeared from the 
switch, or if the SNMP agent on the switch didn't return the value, or 
if there was an SNMP read error or timeout.

Can I suggest logging the output of update-l2database.pl with --debug to 
a file every time it executes and seeing if the mac address is seen 
every time the command is run?

Also maybe restart the snmp agent on the arista? Is it returning 
immediately, or are you seeing queries taking a long time?

Nick


More information about the ixpmanager mailing list