[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-users] Traffic Counting / port analysis using Xen 3.0.2?


  • To: Xen-users <xen-users@xxxxxxxxxxxxxxxxxxx>
  • From: "Robert Hulme" <rob@xxxxxxxxxxxx>
  • Date: Thu, 1 Jun 2006 14:24:49 +0100
  • Delivery-date: Thu, 01 Jun 2006 06:27:21 -0700
  • Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:sender:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references:x-google-sender-auth; b=huB4ISlf4jD24iwm6rfhudpDv5LydITw7wziUm6+QFII7Ldr4ugLLw5Z7nOjWAd/lskxx4iXk+SqT4k8Jd+LXZWkcfyNTilZgwu1ETvD+lpjodKgmXodQmic7fLk/AVawwZzJ16MI2vvJubum9rj2F9qFzRIdYx9TkbBx3m8/0Y=
  • List-id: Xen user discussion <xen-users.lists.xensource.com>

Can/must this be done in the Xen0-domain? Is there an more "elegant" way
(security wise) to fire up an own virtual machine handling this and acting
as a bridge itself?
I'm not sure I 100% understand what you're trying to do (you refer to
domains that you don't control?)...

I would suggest two possibilities:

1. Get raw bytes count from the interface from dom0
cat /sys/class/net/vif#{id}.0/statistics/tx_bytes
cat /sys/class/net/vif#{id}.0/statistics/rx_bytes

Where id is the id for the running domain from xm list.

2. Use iptables
You can do quite complex traffic monitoring using iptables. See:
http://www.netfilter.org/ ...

-Rob

--
------------------------------------------------------
"98.5% of DNA is considered to be junk DNA with no known purpose.
Maybe it's XML tags." -- Anon

"Debugging is twice as hard as writing the code in the first place.
Therefore, if you write the code as cleverly as possible, you are, by
definition, not smart enough to debug it." - Kernighan

http://www.robhulme.com/
http://robhu.livejournal.com/

_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.