I've noticed on our VLAN interfaces that gmond's default network metric seem to be miscalculating network traffic.
anyone else seeing this? we don't use many VLANs. seems the Linux OS counters for the VLAN interface also add onto on the parent interface, and gmond reads both so traffic reported by gmond is ~2x greater than it really is. eg. eth4 (no IP set) with a eth4.99 VLAN, /proc/net/dev shows Inter-| Receive | Transmit face |bytes packets errs drop fifo frame compressed multicast|bytes packets errs drop fifo colls carrier compressed ... eth4:1453106293850 1688242724 0 0 0 0 0 11874 3090232715347 2518006182 0 0 0 0 0 0 eth4.99:1429470895714 1688242724 0 0 0 0 0 11874 2988353281655 912706240 0 0 0 0 0 0 maybe we have setup our interfaces oddly or something. I don't know why Tx Pkts is different between the 2 interfaces ... maybe an upstream MTU. aliased interfaces don't have the same problem as Linux doesn't list them in /proc/net/dev. our setup is ganglia 3.2.0, x86_64, centos5.6 userland, 2.6.32 vanilla kernels, ixgbe 10gige. the below patch fixes/hacks-around the problem by simply skipping all VLAN interfaces - anything with a '.' in the name. doesn't seem right somehow, but seems to work for me. cheers, robin -- Dr Robin Humble, HPC Systems Analyst, NCI National Facility --- ganglia-3.2.0.orig/libmetrics/linux/metrics.c 2010-05-11 00:39:54.000000000 +1000 +++ ganglia-3.2.0/libmetrics/linux/metrics.c 2011-08-29 16:19:55.000000000 +1000 @@ -181,8 +181,10 @@ void update_ifdata ( char *caller ) p = index(p, ':'); /* Ignore 'lo' and 'bond*' interfaces (but sanely) */ + /* Ignore VLAN interfaces (eg. eth4.99) as stats are already included in parent */ if (p && strncmp (src, "lo", 2) && - strncmp (src, "bond", 4)) + strncmp (src, "bond", 4) && + (index(src,'.') == NULL || index(src, '.') > p)) { p++; /* Check for data from the last read for this */ ------------------------------------------------------------------------------ EMC VNX: the world's simplest storage, starting under $10K The only unified storage solution that offers unified management Up to 160% more powerful than alternatives and 25% more efficient. Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev _______________________________________________ Ganglia-general mailing list Ganglia-general@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/ganglia-general