4

Please help me understand ifconfig stats, in particular over what time period are they? From the example below the combined receiving bytes for both interfaces is 7.7 GiB. Is that since midnight? since the last reboot? since ...?

Also eth1 is showing ~500k dropped packets, about 15% of the total received in the same line. This looks bad to me, is it?

[~] # ifconfig
bond0     Link encap:Ethernet  HWaddr 00:08:9B:D3:02:6A
          inet addr:123.123.123.123  Bcast:192.168.255.255  Mask:255.255.255.0
          inet6 addr: fe80::208:9bff:fed3:26a/64 Scope:Link
          UP BROADCAST RUNNING MASTER MULTICAST  MTU:1500  Metric:1
          RX packets:30550094 errors:0 dropped:498787 overruns:0 frame:0
          TX packets:32564187 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:8321227191 (7.7 GiB)  TX bytes:16056647508 (14.9 GiB)

eth0      Link encap:Ethernet  HWaddr 00:08:9B:D3:02:6A
          UP BROADCAST RUNNING SLAVE MULTICAST  MTU:1500  Metric:1
          RX packets:27193387 errors:0 dropped:0 overruns:0 frame:0
          TX packets:18205770 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:7754199970 (7.2 GiB)  TX bytes:9436506547 (8.7 GiB)
          Interrupt:16 Memory:fbc00000-fbc20000

eth1      Link encap:Ethernet  HWaddr 00:08:9B:D3:02:6B
          UP BROADCAST RUNNING SLAVE MULTICAST  MTU:1500  Metric:1
          RX packets:3356710 errors:0 dropped:498455 overruns:0 frame:0
          TX packets:14358417 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:567027413 (540.7 MiB)  TX bytes:6620140961 (6.1 GiB)
          Interrupt:20 Memory:fbd00000-fbd20000
...snip...    
  • For receiving bytes its since you have Booted your Computer. Try Rebooting and that counter will reset. As for 500k dropped packets eth1 you have bonded your connection so you may need to monitor your network Logs and see why. – Tasos Jun 10 '14 at 18:16
1

If you don't reset(modprobe or ethtool can help to reset the counter) the counter, the num you see from ifconfig will increase over time. So, generally speaking, the stats you get probably comes from your last reboot.

The dropped section, usually indicates these meanings, you can check them one by one:

  1. If the traffic is high, say, for a 1Gigabit nic, your have see the average bandwidth have reached 400Mbit or even more, you must need to tune some parameter of your /proc system, like netdev_max_backlog, tcp_max_syn_backlog etc. The default settings are not suitable for a busy server.
  2. Your ring buffer size is too small, and you need to increase them.
  3. Your interrupts is not fully distributed , and you need to affinity your interrupts.
  4. You have a bad cable, or the speed changed from the default 1G to 100Mbit/s, you may need to replace a new cable and monitor for some time to ensure its cable's problem.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.