[En-Nut-Discussion] There's a body in ARP's cellar...

Michael Jones Michael.e.Jones at web.de
Mon Aug 28 22:17:19 CEST 2006


Hi,

Ever had the problem that Nut/OS won't connect (outgoing) if you connect the
network after the power goes on?

I had fixed that by accident a year ago, but only now found out that I did
when I reverted back to the "head" version of arpcache.c and some customer
with slow booting layer 3 routers started reporting problems.


The problem is that NutArpCacheQuery(.) leaves a unresolved ARP entry in the
cache if the network fails. Following calls fail as it thinks that another
thread is currently processing it. After 9 Minutes ARP Ageing finally frees
the entry. 


My quick solution would be:

Arpcache.c line 500:

        /* Mark buffer released on transmit errors. */
        if (nb && NutArpOutput(dev, nb)) {
            nb = 0;
		entry->ae_flags |= ATF_REM;
		ArpCacheFlush(ifn);
            break;
        }

Yet I feel that there is more to it...

Have fun folks!

Cu,
Michael






More information about the En-Nut-Discussion mailing list