Hello, I have a question for the xenners using 1st method of having VMs using VLAN interfaces with XEN. [http://wiki.xensource.com/xenwiki/XenNetworking] I''ve setup my /etc/network/interfaces file with bridge enteries like in the example: iface xen-br293 inet manual up vconfig add eth0 293 up /etc/xen/scripts/network start netdev=eth0.293 bridge=xen-br293 antispoof=no up /sbin/ifconfig eth0.293 up down /etc/xen/scripts/network stop netdev=eth0.293 bridge=xen-br293 antispoof=no down vconfig rem eth0.293 However now I was wondering was the correct settings for the "network-script" and "vif-script" in the xend-config.sxp file. Do I need to create blank scripts, or it there a dummy one I should use instead of (network-script ''network-bridge'') and(vif-script vif-bridge) respectively? I was prepared to specify the exact bridge name in each of my DomU configuration files, so the automatic networking scripts are not required. Lastly James Bulpin added: "I then add an init.d script to bring the interface up between xend and xendomains starting." Could one provide an example of what they did here. My understanding of that is to create a shell script like up-xen-bridges with multiple ifconfig lines like: #!/bin/bash # # up-xen-bridges Script to start the Xen bridges. # # Author: Mike Viau <viaum@sheridanc.on.ca> # # chkconfig: 2345 98 01 # description: Starts the Xen bridges. ### BEGIN INIT INFO # Provides: up-xen-bridges # Required-Start: $xend # Should-Start: # Required-Stop: $xend # Should-Stop: # Default-Start: 3 4 5 # Default-Stop: 0 1 2 6 # Default-Enabled: yes # Short-Description: Start up-xen-bridges # Description: Starts the Xen bridges. ### END INIT INFO case "$1" in start) ifconfig xen-br293 up ifconfig xen-br294 up ifconfig xen-br295 up ;; stop) ifconfig xen-br293 down ifconfig xen-br294 down ifconfig xen-br295 down ;; restart|reload|force-reload) /etc/init.d/up-xen-bridges stop /etc/init.d/up-xen-bridges start ;; *) # do not advertise unreasonable commands that there is no reason # to use with this device echo $"Usage: $0 {start|stop|restart|reload|force-reload}" exit 1 esac exit $? And then copy this file to /etc/init.d/up-xen-bridges. What were the commands you used for updating your System-V style init script links. usage: update-rc.d [-n] [-f] <basename> remove update-rc.d [-n] <basename> defaults [NN | SS KK] update-rc.d [-n] <basename> start|stop NN runlvl [runlvl] [...] . -n: not really -f: force Thanks for looking! -M _________________________________________________________________ Stay in touch. http://go.microsoft.com/?linkid=9712959 _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Fajar A. Nugraha
2010-Mar-09 05:13 UTC
Re: [Xen-users] xend-config.sxp setting question & vlans
On Mon, Mar 8, 2010 at 11:49 PM, Mike Viau <viaum@sheridanc.on.ca> wrote:> Hello, > > I have a question for the xenners using 1st method of having VMs using VLAN > interfaces with XEN. [http://wiki.xensource.com/xenwiki/XenNetworking] > > I''ve setup my /etc/network/interfaces file with bridge enteries like in the > example: > > iface xen-br293 inet manual > up vconfig add eth0 293 > up /etc/xen/scripts/network start netdev=eth0.293 bridge=xen-br293 > antispoof=noWhy? IMHO you should use only one, not both. So either: - have xen''s networking script create the bridges, or - create the bridges manually, and comment-out xen''s networking script on xend-config.sxp. This is what I prefer to use on complex setup. -- Fajar _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
> Date: Tue, 9 Mar 2010 12:13:08 +0700 > Subject: Re: [Xen-users] xend-config.sxp setting question & vlans > From: fajar@fajar.net > To: viaum@sheridanc.on.ca > CC: xen-users@lists.xensource.com > > On Mon, Mar 8, 2010 at 11:49 PM, Mike Viau <viaum@sheridanc.on.ca> wrote: > > Hello, > > > > I have a question for the xenners using 1st method of having VMs using VLAN > > interfaces with XEN. [http://wiki.xensource.com/xenwiki/XenNetworking] > > > > I''ve setup my /etc/network/interfaces file with bridge enteries like in the > > example: > > > > iface xen-br293 inet manual > > up vconfig add eth0 293 > > up /etc/xen/scripts/network start netdev=eth0.293 bridge=xen-br293 > > antispoof=no > > Why? > > IMHO you should use only one, not both. So either: > - have xen''s networking script create the bridges, or > - create the bridges manually, and comment-out xen''s networking script > on xend-config.sxp. This is what I prefer to use on complex setup. >I am comfortable with creating the bridges manually and commenting-out xen''s networking script on xend-config.sxp as Pasi pointed out in another thread. Could someone provide a working example of debian /etc/network/interface file where a vlan is bridged for use with xen DomUs? To be honest, I don''t think the 1st method of having VMs using VLAN interfaces with XEN works with with my Debain Lenny (and possibly other) setup. I was just trying to follow the wiki as it was written. However I quickly discovered that the above iface xen-br293 inet manual entry does not work, because when one tries to bring up xen-br293 one gets: xen-br293: ERROR while getting interface flags: No such device I believe this may be do to the fact that the xen-br# devices are not known by the udev system and thus the iface entries are just ignored. Regardless I think the wiki should demonstrate how to use xen''s networking script create the bridges, or how to create the bridges manually (in /etc/network/interface or other method(s)) while comment-out xen''s networking script on xend-config.sxp like Fajar suggested.> -- > Fajar > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-users_________________________________________________________________ Take your contacts everywhere http://go.microsoft.com/?linkid=9712959 _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Guy Roussin
2010-Mar-09 15:20 UTC
Re: [Xen-users] xend-config.sxp setting question & vlans
Hi,> > I am comfortable with creating the bridges manually and commenting-out > xen''s networking script on xend-config.sxp as Pasi pointed out in > another thread. > > Could someone provide a working example of debian > /etc/network/interface file where a vlan is bridged for use with xen > DomUs?(debian lenny) eth0 => admin eth1 => 3 vlans/bridges # The loopback network interface auto lo iface lo inet loopback # The primary network interface auto eth0 iface eth0 inet static address 192.168.6.108 network 192.168.6.0 netmask 255.255.255.0 broadcast 192.168.6.255 gateway 192.168.6.101 auto eth1.1 iface eth1.1 inet manual auto br01 iface br01 inet manual network 172.16.0.0 netmask 255.255.0.0 broadcast 172.16.255.255 bridge-ports eth1.1 auto eth1.7 iface eth1.7 inet manual auto br07 iface br07 inet manual network 192.168.7.0 netmask 255.255.255.0 broadcast 192.168.7.255 bridge-ports eth1.7 # The primary network interface auto eth1.10 iface eth1.10 inet manual auto br10 iface br10 inet manual network x.x.x.128 netmask 255.255.255.128 broadcast x.x.x.127 bridge-ports eth1.10 -- Guy _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Pasi Kärkkäinen
2010-Mar-09 18:43 UTC
Re: [Xen-users] xend-config.sxp setting question & vlans
On Tue, Mar 09, 2010 at 10:07:36AM -0500, Mike Viau wrote:> > Date: Tue, 9 Mar 2010 12:13:08 +0700 > > Subject: Re: [Xen-users] xend-config.sxp setting question & vlans > > From: fajar@fajar.net > > To: viaum@sheridanc.on.ca > > CC: xen-users@lists.xensource.com > > > > On Mon, Mar 8, 2010 at 11:49 PM, Mike Viau <viaum@sheridanc.on.ca> > wrote: > > > Hello, > > > > > > I have a question for the xenners using 1st method of having VMs using > VLAN > > > interfaces with XEN. [http://wiki.xensource.com/xenwiki/XenNetworking] > > > > > > I''ve setup my /etc/network/interfaces file with bridge enteries like > in the > > > example: > > > > > > iface xen-br293 inet manual > > > up vconfig add eth0 293 > > > up /etc/xen/scripts/network start netdev=eth0.293 bridge=xen-br293 > > > antispoof=no > > > > Why? > > > > IMHO you should use only one, not both. So either: > > - have xen''s networking script create the bridges, or > > - create the bridges manually, and comment-out xen''s networking script > > on xend-config.sxp. This is what I prefer to use on complex setup. > > > > I am comfortable with creating the bridges manually and commenting-out > xen''s networking script on xend-config.sxp as Pasi pointed out in another > thread. > > Could someone provide a working example of debian /etc/network/interface > file where a vlan is bridged for use with xen DomUs? > > To be honest, I don''t think the 1st method of having VMs using VLAN > interfaces with XEN works with with my Debain Lenny (and possibly other) > setup. I was just trying to follow the wiki as it was written. > > However I quickly discovered that the above iface xen-br293 inet manual > entry does not work, because when one tries to bring up xen-br293 one > gets: > > xen-br293: ERROR while getting interface flags: No such device > > I believe this may be do to the fact that the xen-br# devices are not > known by the udev system and thus the iface entries are just ignored. > Regardless I think the wiki should demonstrate how to use xen''s networking > script create the bridges, or how to create the bridges manually (in > /etc/network/interface or other method(s)) while comment-out xen''s > networking script on xend-config.sxp like Fajar suggested. >Creating the bridges using distro network scripts is obviously distro specific task. I can''t remember how to do that in debian /etc/network/interfaces. In rhel/centos/fedora I do them like this: /etc/sysconfig/network-scripts/ifcfg-brvlanXY DEVICE=brvlanXY BOOTPROTO=none ONBOOT=yes TYPE=Bridge and then it''s just a matter of ''ifup brvlanXY''. In the /etc/xen/<guest> configuration file remember to specify "bridge=brvlanXY" for the vif. Someone feel free to edit the wiki :) -- Pasi> > -- > > Fajar > > > > _______________________________________________ > > Xen-users mailing list > > Xen-users@lists.xensource.com > > http://lists.xensource.com/xen-users > > -------------------------------------------------------------------------- > > Stay in touch. [1]Get Messenger on your phone now. > > References > > Visible links > 1. http://go.microsoft.com/?linkid=9712959> _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-users_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
> Date: Tue, 9 Mar 2010 20:43:32 +0200 > From: pasik@iki.fi > To: viaum@sheridanc.on.ca > Subject: Re: [Xen-users] xend-config.sxp setting question & vlans > CC: fajar@fajar.net; xen-users@lists.xensource.com > > On Tue, Mar 09, 2010 at 10:07:36AM -0500, Mike Viau wrote: > > > Date: Tue, 9 Mar 2010 12:13:08 +0700 > > > Subject: Re: [Xen-users] xend-config.sxp setting question & vlans > > > From: fajar@fajar.net > > > To: viaum@sheridanc.on.ca > > > CC: xen-users@lists.xensource.com > > > > > > On Mon, Mar 8, 2010 at 11:49 PM, Mike Viau <viaum@sheridanc.on.ca> > > wrote: > > > > Hello, > > > > > > > > I have a question for the xenners using 1st method of having VMs using > > VLAN > > > > interfaces with XEN. [http://wiki.xensource.com/xenwiki/XenNetworking] > > > > > > > > I''ve setup my /etc/network/interfaces file with bridge enteries like > > in the > > > > example: > > > > > > > > iface xen-br293 inet manual > > > > up vconfig add eth0 293 > > > > up /etc/xen/scripts/network start netdev=eth0.293 bridge=xen-br293 > > > > antispoof=no > > > > > > Why? > > > > > > IMHO you should use only one, not both. So either: > > > - have xen''s networking script create the bridges, or > > > - create the bridges manually, and comment-out xen''s networking script > > > on xend-config.sxp. This is what I prefer to use on complex setup. > > > > > > > I am comfortable with creating the bridges manually and commenting-out > > xen''s networking script on xend-config.sxp as Pasi pointed out in another > > thread. > > > > Could someone provide a working example of debian /etc/network/interface > > file where a vlan is bridged for use with xen DomUs? > > > > To be honest, I don''t think the 1st method of having VMs using VLAN > > interfaces with XEN works with with my Debain Lenny (and possibly other) > > setup. I was just trying to follow the wiki as it was written. > > > > However I quickly discovered that the above iface xen-br293 inet manual > > entry does not work, because when one tries to bring up xen-br293 one > > gets: > > > > xen-br293: ERROR while getting interface flags: No such device > > > > I believe this may be do to the fact that the xen-br# devices are not > > known by the udev system and thus the iface entries are just ignored. > > Regardless I think the wiki should demonstrate how to use xen''s networking > > script create the bridges, or how to create the bridges manually (in > > /etc/network/interface or other method(s)) while comment-out xen''s > > networking script on xend-config.sxp like Fajar suggested. > > > > Creating the bridges using distro network scripts is obviously distro specific task. > I can''t remember how to do that in debian /etc/network/interfaces. > > In rhel/centos/fedora I do them like this: > > /etc/sysconfig/network-scripts/ifcfg-brvlanXY > DEVICE=brvlanXY > BOOTPROTO=none > ONBOOT=yes > TYPE=Bridge > > and then it''s just a matter of ''ifup brvlanXY''. > > In the /etc/xen/<guest> configuration file remember > to specify "bridge=brvlanXY" for the vif. > > Someone feel free to edit the wiki :) > > -- PasiOn Tue, March 9th - Guy Roussin wrote: (debian lenny) eth0 => admin eth1 => 3 vlans/bridges # The loopback network interface auto lo iface lo inet loopback # The primary network interface auto eth0 iface eth0 inet static address 192.168.6.108 network 192.168.6.0 netmask 255.255.255.0 broadcast 192.168.6.255 gateway 192.168.6.101 auto eth1.1 iface eth1.1 inet manual auto br01 iface br01 inet manual network 172.16.0.0 netmask 255.255.0.0 broadcast 172.16.255.255 bridge-ports eth1.1 auto eth1.7 iface eth1.7 inet manual auto br07 iface br07 inet manual network 192.168.7.0 netmask 255.255.255.0 broadcast 192.168.7.255 bridge-ports eth1.7 # The primary network interface auto eth1.10 iface eth1.10 inet manual auto br10 iface br10 inet manual network x.x.x.128 netmask 255.255.255.128 broadcast x.x.x.127 bridge-ports eth1.10 -- Guy This configuration works as apposed to the 1st method for vlans on the wiki! Thanks.> > > > -- > > > Fajar > > > > > > _______________________________________________ > > > Xen-users mailing list > > > Xen-users@lists.xensource.com > > > http://lists.xensource.com/xen-users > > > > -------------------------------------------------------------------------- > > > > Stay in touch. [1]Get Messenger on your phone now. > > > > References > > > > Visible links > > 1. http://go.microsoft.com/?linkid=9712959 > > > _______________________________________________ > > Xen-users mailing list > > Xen-users@lists.xensource.com > > http://lists.xensource.com/xen-users > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-users_________________________________________________________________ Check your Hotmail from your phone. http://go.microsoft.com/?linkid=9712957 _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users