2^31 packet counter bug?
Simon Andrew Boggis
Sun Dec 12 19:49:57 1999
> 2 billion packets and you're off the air...?
> The evil evidence:
> eth0 Link encap:Ethernet HWaddr 00:90:27:50:A8:DE
> inet addr:172.16.0.20 Bcast:172.16.255.255 Mask:255.255.0.0
> UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
> RX packets:15 errors:288850 dropped:0 overruns:0 frame:0
> TX packets:2147483647 errors:1 dropped:0 overruns:0 carrier:0
> collisions:0 txqueuelen:100
> Interrupt:10 Base address:0xd000
> Check out the TX packets number! That's 2^31-1.
> This is absolutely dreadful. Is this 'feature' a
> property of the eepro100
> driver, or something in the kernel itself?
> Either way, it's a killer. Gotta get to the bottom of it.
> Standard 2.2.12/2.2.13 kernels, with included eepro100 code.
Hmmm, I have a couple of eepro100-based linux routers - the one thats been up
the longest is working fine (167 days, kernel 2.2.9) but the counters are
jammed - for example, `ifconfig eth0' gives:
eth0 Link encap:Ethernet HWaddr 00:90:27:2A:55:48
inet addr:18.104.22.168 Bcast:22.214.171.124 Mask:255.255.255.0
IPX/Ethernet 802.2 addr:8A255800:0090272A5548
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:2147483647 errors:41 dropped:0 overruns:1 frame:0
TX packets:2147483647 errors:13 dropped:0 overruns:715 carrier:0
Interrupt:15 Base address:0xa000
BUT /proc/net/dev reports something more believable:
hammer:/# cat net/dev
Inter-| Receive | Transmit
face |bytes packets errs drop fifo frame compressed multicast|bytes packets errs drop fifo colls carrier compressed
eth0:2754574912 2177325200 41 0 1 0 0 0 2384782514 3474415357 13 0 715 0 0 0
Thats RX packets: 2177325200
and TX packets: 3474415357
compared to : 2147483647 from ifconfig eth0
So to me, it looks like neither the kernel (or the eepro100.c part thereof)
have a problem, rather that ifconfig isn't reporting the values correctly -
which shouldn't have any impact on machine stability.
Could your network hang be a coincidence?
Simon A. Boggis Systems Programmer
Department of Computer Science,
Queen Mary and Westfield College London, E1 4NS, UK. Telephone 0171 975 5234