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

Re: [libvirt] Notes on configuring Open vSwitch, Linux bridge and Libvirt



On 07/12/2013 06:32 PM, Daniel P. Berrange wrote:
> On Fri, Jul 12, 2013 at 05:51:14PM +0530, Kashyap Chamarthy wrote:
>> Heya Laine,
>>
>> Here's some quick notes to associate libvirt guests to Open vSwitch.
>>
>> Configure Open vSwitch
>> ----------------------
>>
>> Now that a regular Linux bridge is configured, let's try to configure an
>> OVS brdige and get IP addresses from that space:
>>
>> Create an Open vSwitch bridge device called 'ovsbr', and display the
>> current state of OpenvSwitch database contents:
>>
>>     $ ovs-vsctl add-br ovsbr
>>     $ ovs-vsctl show
>>
>>
>> Add a virtual ethernet interface called 'veth0' with
>>
>>     $ ip link add name veth0 \
>>       type veth peer name veth1
>>
>> Add 'veth0' ethernet device to the Linux bridge 'br0', and enumerate all
>> bridge devices:
>>
>>     $ brctl addif br0 veth0
>>     $ brctl show
> 
> I don't really see why you are linking ovs to a traditional software
> bridge. 

I had no specific reason on mind. The only test machine I had free was already having a
Linux bridge. I thought I'd try on it anyway.


Meanwhile, from this networking notes page,


http://docs.openstack.org/trunk/openstack-network/admin/content/under_the_hood_openvswitch.html

it appears that OpenStack uses Linux bridge in conjunction with an OVS bridge:

    There are four distinct type of virtual networking devices: TAP
    devices, veth pairs, Linux bridges, and Open vSwitch bridgesFor an
    ethernet frame to travel from eth0 of virtual machine vm01, to the
    physical network, it must pass through nine devices inside of the
    host: TAP vnet0, Linux bridge qbrXXX, veth pair (qcbXXX, qvoXXX),
    Open vSwitch bridge br-int, veth pair (int-br-eth1, phy-br-eth1),
    and, finally, the physical network interface card eth1.


And further, it notes the distinction between how a Linux bridge and OVS in this context:

    A Linux bridge behaves like a hub: you can connect multiple (physical
    or virtual) network interfaces devices to a Linux bridge. Any ethernet
    frames that come in from one interface attached to the bridge is
    transmitted to all of the other devices.

    An Open vSwitch bridge behaves like a virtual switch: network interface
    devices connect to Open vSwitch bridge's ports, and the ports can be
    configured much like a physical switch's ports, including VLAN
    configurations.


> You now have the overheads of both bridging & ovs code in
> your data path. Surely it is better to connect ovs with your physical
> NIC, taking traditional bridges out of the loop completely.

That's my next test :)


-- 
/kashyap


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