WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-users

RE: [Xen-users] how to specify vif device name?

To: "Rudi Ahlers" <rudiahlers@xxxxxxxxx>, "Jan Marquardt" <jm@xxxxxxxxxxx>
Subject: RE: [Xen-users] how to specify vif device name?
From: "James Harper" <james.harper@xxxxxxxxxxxxxxxx>
Date: Wed, 13 Aug 2008 22:29:54 +1000
Cc: xen-users@xxxxxxxxxxxxxxxxxxx
Delivery-date: Wed, 13 Aug 2008 05:30:32 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <695200da0808130513h3072b106vd9f261cb0ea44ed4@xxxxxxxxxxxxxx>
List-help: <mailto:xen-users-request@lists.xensource.com?subject=help>
List-id: Xen user discussion <xen-users.lists.xensource.com>
List-post: <mailto:xen-users@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=unsubscribe>
References: <695200da0808130424s425d0c5fnede97633a46a0ee@xxxxxxxxxxxxxx><48A2CDA7.7070008@xxxxxxxxxxx> <695200da0808130513h3072b106vd9f261cb0ea44ed4@xxxxxxxxxxxxxx>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: Acj9PjccJFm/qtYfSdKhj7nUdrYR/AAAGMgw
Thread-topic: [Xen-users] how to specify vif device name?
> Hi Jan
> 
> The domain ID changes from time to time, depending on which order the
> domains were started / restarted
> So, this is not very reliable, especially for cacti stats - which uses
the
> device name for traffic graphs

That's going to be tricky. If netfront could publish something into the
/sys entry for the device, eg domain_name=Pluto, then udev could take
care of the device renaming, but netfront doesn't do that and I'm not
even sure if that level of device driver has visibility to the /sys
entries. And it would probably break the /etc/xen/scripts/* code.

There are two approaches you could take:

1. Add some code to the appropriate script in /etc/xen/scripts to rename
the device when the domain is created via the 'ip link set vifX.0 name
pluto0' command. This might be tricky as the interface name (as vifX.0)
is used in many places in those scripts and renaming it will confuse
them.

2. Make cacti smarter about how it determines the interface name. I'm
not familiar with cacti but under mrtg, if you are on the local machine
(eg not using SNMP), you could just write a script to return the
required results.

Depending on how flexible cacti is, I'd take the latter approach.

James 


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