首页 > 解决方案 > Number of ARP entries for GC to clear?

问题描述

In Linux Kernel source code, ARP cache is clear by garbage collector () as this post described.

But in net/core/neighbour.c in kernel source code has this condition: (in neigh_periodic_work() function)

if (atomic_read(&tbl->entries) < tbl->gc_thresh1)
        goto out;
...
<doing clear ARP cache here>
...

out: 

So does the GC clear ARP cache only when number of ARP entries is greater than gc_thresh? What if I have only 2 or 3 entries, does these entries never be cleared ?

标签: cachingnetworkinglinux-kernelarp

解决方案


推荐阅读