Re: [libvirt] about open vswitch supporting?

2012-09-04 Thread yue wang
it seems the  'generic ethernet connection' network doesn't have the
'virtualport ' element, so there is no way to associate it with an
interface's uuid.
are there any workaround?

On Mon, Sep 3, 2012 at 6:41 PM, yue wang heuye.w...@gmail.com wrote:

 Hi:

 i used to use linux bridge and specify interfaces by 'Generic ethernet 
 connection'
 mode,after reading this page:
 http://libvirt.org/formatdomain.html#elementsNICS
 i am not sure if i need to change to another mode(eg:'virtual network') to
 specify interfaces when switching linux bridge to open vswitch?
 any suggestions?


 thanks!
 heuye

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] about open vswitch supporting?

2012-09-04 Thread Laine Stump
On 09/04/2012 02:20 AM, yue wang wrote:
 it seems the  'generic ethernet connection' network doesn't have the
 'virtualport ' element, so there is no way to associate it with an
 interface's uuid.
 are there any workaround?

See the other reply I just sent (I thought I'd typed it up yesterday,
but forgot to hit send). You shouldn't be using the generic ethernet
connection type for either standard linux bridges or Open vSwitch
bridges (unless you are using Open vSwitch *and* your libvirt is older
than 0.9.11, and in that case there is no type='openvswitch' for
virtualport anyway).

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] about open vswitch supporting?

2012-09-04 Thread Laine Stump
On 09/03/2012 06:41 AM, yue wang wrote:


 Hi:


 i used to use linux bridge and specify interfaces
 by 'Generic ethernet connection' mode,after
 reading this page:


 http://libvirt.org/formatdomain.html#elementsNICS


Actually, for a standard linux bridge, you should be using interface
type='bridge' rather than interface type='ethernet' (generic
ethernet connection):

  http://www.libvirt.org/formatdomain.html#elementsNICSBridge

type='ethernet' should only be used if there is some special setup that
can't be taken care of by the standard types; type='ethernet' requires
special permissions that aren't normally required, and taints the
guest - it's considered to be unsupported.



 i am not sure if i need to change to another
 mode(eg:'virtual network') to specify interfaces
 when switching linux bridge to open vswitch?

   any suggestions?


As long as your libvirt version is new enough (0.9.11 or newer), you can
continue to use interface type='bridge' (as you should have previously
been), and add a virtualport type='openvswitch' element to the
interface definition. For example, if you were previously using a linux
bridge at br0, you would have have used:

   interface type='bridge'
 source bridge='br0'/
 ...
   /interface

and if you switch to using an Open vSwitch bridge named ovsbr0, you
would change that to:

   interface type='bridge'
 source bridge='ovsbr0'/
 virtualport type='openvswitch'/
 ...
   /interface

(you will notice that after you've edited you interface definition like
this, libvirt will automatically add a parameters interfaceid=[some
uuid string]/ to the virtualport element. This is so that the
guest's interface can be known by a stable id that won't change as the
guest is stopped/restarted/migrated.)


If your libvirt is older than 0.9.11,you will need to either use the
Open vSwitch compatibility library to make your Open vSwitch bridge
appear to be a standard Linux host bridge, *or* you wil need to use
interface type='ethernet' along with an ifup script. I would
*strongly* recommend that you upgrade to 0.9.11+ if at all possible.

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list