'ifconfig' shows incorrect number of bytes
On some of our switches, 'ifconfig' yields an incorrect number of bytes. Example:
wrs#ifconfig wri1; sleep 10; ifconfig wri1
wri1 Link encap:Ethernet HWaddr 64:FB:81:2F:FE:F2
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:1132857827 errors:0 dropped:74204937 overruns:0 frame:0
TX packets:34700825 errors:0 dropped:0 overruns:0 carrier:1
collisions:0 txqueuelen:1000
RX bytes:1319987352 (1.2 GiB) TX bytes:2581308252 (2.4 GiB)
wri1 Link encap:Ethernet HWaddr 64:FB:81:2F:FE:F2
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:1132878970 errors:0 dropped:74204987 overruns:0 frame:0
TX packets:34700848 errors:0 dropped:0 overruns:0 carrier:1
collisions:0 txqueuelen:1000
RX bytes:1319991108 (1.2 GiB) TX bytes:2581309952 (2.4 GiB)
Within 10 seconds, there are 21143 RX packets. This number makes sense, as our 'Data Master' is sending Ethernet frames with timing messages at a rate slightly above 2 kHz. Plus some extra frames for PTP, LLDP ...
The frames size with timing message is typically 102 bytes (without interframe gap). Thus, one would expect around 2.1E6 RX bytes.
However, the number of RX bytes within the same time is only 3756 bytes (only about 0.2 bytes per packet) which does not make sense to me.
It seems that such a behavior only shows up at WRS that see higher traffic rates like shown in the above example.