<div dir="ltr">Hello Nick,<div><br></div><div>Thank you for your elaborated response.</div><div><br></div><div>I have the <a href="http://update-l2database.pl/" rel="noreferrer" target="_blank">update-l2database.pl</a> script run once every hour for all switches without specifying a vlan and this was working fine for Huawei switches.</div><div><br></div><div>However, I have noticed that this was causing the issue for the Arista switch and once the vlanid was added in the script the MAC addresses were discovered without issues.</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Apr 30, 2021 at 12:44 AM Nick Hilliard <<a href="mailto:nick@foobar.org">nick@foobar.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><br>
Hi Ahmed,<br>
<br>
Ahmed Al-Saruri wrote on 09/04/2021 12:10:<br>
> Hello Nick,<br>
> <br>
> Yes, I am sure that the MAC address is consistently present on the <br>
> switch when the device is polled.<br>
> <br>
> Attached are the logs from <a href="http://update-l2database.pl" rel="noreferrer" target="_blank">update-l2database.pl</a> when I run it manually.<br>
> <br>
> Also here is the information from the interface with no flaps or mac <br>
> changes during this time period.<br>
> <br>
> columba.del#sh mac address-table int eth3<br>
> Mac Address Table<br>
> ------------------------------------------------------------------<br>
> <br>
> Vlan Mac Address Type Ports Moves Last Move<br>
> ---- ----------- ---- ----- ----- ---------<br>
> 3210 f4b7.8ddd.02e6 DYNAMIC Et3 1 2 days, <br>
> 22:18:46 ago<br>
> Total Mac Addresses for this criterion: 1<br>
> <br>
> Do you have any suggestions on how to investigate this further?<br>
<br>
The only script which deletes anything from the macaddress table is <br>
<a href="http://update-l2database.pl" rel="noreferrer" target="_blank">update-l2database.pl</a>, which works by using the following sequence of SQL <br>
commands:<br>
<br>
START TRANSACTION<br>
DELETE FROM macaddress<br>
INSERT INTO macaddress (...) VALUES (...)<br>
[...]<br>
INSERT INTO macaddress (...) VALUES (...)<br>
COMMIT<br>
<br>
So the only way for a mac address to disappear from this table is if <br>
<a href="http://update-l2database.pl" rel="noreferrer" target="_blank">update-l2database.pl</a> is executed, and doesn't read the mac address from <br>
the switch, and then commits what it finds to the database.<br>
<br>
This could happen if the MAC address temporarily disappeared from the <br>
switch, or if the SNMP agent on the switch didn't return the value, or <br>
if there was an SNMP read error or timeout.<br>
<br>
Can I suggest logging the output of <a href="http://update-l2database.pl" rel="noreferrer" target="_blank">update-l2database.pl</a> with --debug to <br>
a file every time it executes and seeing if the mac address is seen <br>
every time the command is run?<br>
<br>
Also maybe restart the snmp agent on the arista? Is it returning <br>
immediately, or are you seeing queries taking a long time?<br>
<br>
Nick<br>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><p dir="auto" style="margin:0px 0px 16px;font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Oxygen-Sans,Ubuntu,Cantarell,"Helvetica Neue",Arial,sans-serif;font-size:14px;line-height:20px;padding:0px;border:0px;outline:0px;vertical-align:baseline;background-image:initial;background-position:initial;background-repeat:initial;color:rgb(85,85,85)">Warm Regards,<br>Ahmed Alsaruri</p></div></div></div></div>