xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Maykel Moya <mmoya@mmoya.org>
To: xen-devel <xen-devel@lists.xensource.com>
Subject: Different network traffic measures (dom0 vs. domU)
Date: Wed, 25 Jan 2012 10:13:34 +0100	[thread overview]
Message-ID: <4F1FC7BE.7090402@mmoya.org> (raw)

Hi,

I'm using Xen 4.0.1 with Linux 2.6.32-5-xen-amd64 (standard packages on
a Debian Squeeze system).

>From Xen Networking:

"Think of them (vif<id#>.0 @dom0 and eth0 @domU) as two ethernet
interfaces connected by an internal crossover ethernet cable."

My understanding of this internal crossover thing is that networking
statistics should be the same no matter if you measure it in the dom0
(vifN.N interface) or in the domU (eth0 interface). RX/TX values should
be the same, just inverted.

Nevertheless I'm getting ~20% larger values when traffic is measured in
dom0.

Just after starting the domU I ran this on the dom0:
.
root@dev1:~# while true; do date; cat
/sys/class/net/vif35.0/statistics/{r,t}x_bytes; sleep 1; done
...
Thu Jan 19 13:18:00 EST 2012
4826
466049
Thu Jan 19 13:18:01 EST 2012
4826
466580
Thu Jan 19 13:18:02 EST 2012
4826
467427
Thu Jan 19 13:18:03 EST 2012
4826
467910
Thu Jan 19 13:18:04 EST 2012
4826
468769
Thu Jan 19 13:18:05 EST 2012
4826
469764

and in the domU

root@node2050:~# while true; do date; cat
/sys/class/net/eth0/statistics/{r,t}x_bytes; sleep 1; done
 ...
Thu Jan 19 13:18:00 EST 2012
395229
5792
Thu Jan 19 13:18:01 EST 2012
395961
5792
Thu Jan 19 13:18:02 EST 2012
396617
5792
Thu Jan 19 13:18:03 EST 2012
397304
5792
Thu Jan 19 13:18:04 EST 2012
397735
5792
Thu Jan 19 13:18:05 EST 2012
398620
5792

I didn't found any relevant in Google. Posted a question in serverfault
(http://j.mp/zzDPuV), and there is no an answer yet. Asked in xen-users
and got no answer.

Do anybody have a clue about why the values are (that) different?  Seems
to me a Xen bug but I might be missing something.

Regards,
maykel

                 reply	other threads:[~2012-01-25  9:13 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4F1FC7BE.7090402@mmoya.org \
    --to=mmoya@mmoya.org \
    --cc=xen-devel@lists.xensource.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).