[ovs-discuss] ovs del-port does not clean up ethX.Y vlan interfaces

Madhur Sethi madhur at attivonetworks.com
Wed Oct 8 07:38:31 UTC 2014


Hi Ben,



Without the Vlan splinters,  we are not able to receive vlan tagged packets in 3.10.

The interface sends out vlan packets alright but the replies are not picked up by the interface.

Below are the setup details, we tried on another machine:



[root at XXX  ~]# rpm -qa | grep openvswitch

openvswitch-2.0.1-1.x86_64



[root at XXX ~]# rpm -qa | grep kvm

qemu-kvm-0.12.1.2-2.415.el6_5.10.x86_64



[root at XXX ~]# modinfo kvm_intel

filename:       /lib/modules/3.10.51-1.el6.elrepo.x86_64/kernel/arch/x86/kvm/kvm-intel.ko

license:        GPL

author:         Qumranet

srcversion:     D1C0A8B692E68C9FAFD837D

alias:          x86cpu:vendor:*:family:*:model:*:feature:*0085*

depends:        kvm

intree:         Y

vermagic:       3.10.51-1.el6.elrepo.x86_64 SMP mod_unload modversions

parm:           vpid:bool

parm:           flexpriority:bool

parm:           ept:bool

parm:           unrestricted_guest:bool

parm:           eptad:bool

parm:           emulate_invalid_guest_state:bool

parm:           vmm_exclusive:bool

parm:           fasteoi:bool

parm:           enable_apicv:bool

parm:           enable_shadow_vmcs:bool

parm:           nested:bool

parm:           ple_gap:int

parm:           ple_window:int





openVSwitch config:

[root at XXX ~]# ovs-vsctl show

3c55434d-c453-49e9-884d-e4fd6d614606

Bridge OVS-VlanBridge

        Port OVS-VlanBridge

                    Interface OVS-VlanBridge

                        type: internal

        Port "vnet366"

                    tag: 5

                    Interface "vnet366"

         Port "eth1"

                    trunks: [5]

                    Interface "eth1"



The Vlan is intended to be stripped on the OVS-VlanBridge, as we don't want to trunk it to the VM.

The vnet366 is configured as an access port on the openVSwitch and corresponds to eth1 on the VM. On the VM the configuration is :



[root at YYY  ~]# cat /etc/sysconfig/network-scripts/ifcfg-eth1

DEVICE=eth1

TYPE=Ethernet

BOOTPROTO=static

ONBOOT=yes

IPADDR=2.2.2.2

NETMASK=255.255.255.0



The physical Ethernet Port eth1 has the following configuration on the host :

DEVICE=eth1

TYPE=Ethernet

ONBOOT=yes

BOOTPROTO=none



[root at XXX ~]# ethtool -i eth1

driver: igb

version: 5.0.3-k

firmware-version: 1.80, 0x00000000

bus-info: 0000:05:00.1

supports-statistics: yes

supports-test: yes

supports-eeprom-access: yes

supports-register-dump: yes

supports-priv-flags: no



[root at XXX ~]# tcpdump -i eth1 -ne arp

tcpdump: WARNING: eth1: no IPv4 address assigned

tcpdump: verbose output suppressed, use -v or -vv for full protocol decode listening on eth1, link-type EN10MB (Ethernet), capture size 65535 bytes

16:30:13.035965 52:54:00:3c:77:f5 > Broadcast, ethertype 802.1Q (0x8100), length 46: vlan 5, p 0, ethertype ARP, Request who-has 2.2.2.2 tell 2.2.2.3, length 28

16:30:14.038195 52:54:00:3c:77:f5 > Broadcast, ethertype 802.1Q (0x8100), length 46: vlan 5, p 0, ethertype ARP, Request who-has 2.2.2.2 tell 2.2.2.3, length 28





The OVS successfully configures the VLAN and arp requests going out of eth1 to the network are tagged with VLAN 5. However it does not pick up the arp responses coming back from the other side.



Regards.

Madhur



-----Original Message-----

From: Ben Pfaff [mailto:blp at nicira.com]

Sent: 08 October 2014 02:14

To: Madhur Sethi

Cc: 'discuss at openvswitch.org'

Subject: Re: [ovs-discuss] ovs del-port does not clean up ethX.Y vlan interfaces



If you're using Linux 3.10, you don't need VLAN splinters.  The problems that VLAN splinters work around were fixed in Linux 3.3.



On Tue, Sep 30, 2014 at 03:59:26PM +0000, Madhur Sethi wrote:

> Hi Ben,

>

>

>

> There seems to be another problem here with the VLAN Splinters.

>

>

>

> ovs-vsctl add port eth2 trunks 105

>

> ovs-vsctl add port eth2 trunks 104

>

> [root at XXX-BServer01 backend_ui_script]# ovs-vsctl get port eth2 trunks

>

> [104, 105]

>

> [root at XXX-BServer01 backend_ui_script]# ifconfig | grep eth2

>

> eth2      Link encap:Ethernet  HWaddr 00:25:90:EA:28:E2

>

> eth2.104  Link encap:Ethernet  HWaddr 00:25:90:EA:28:E2

>

> eth2.105  Link encap:Ethernet  HWaddr 00:25:90:EA:28:E2

>

>

>

> If I now add another port eth3 to the bridge, it automatically creates following interfaces:

>

> [root at XXX-BServer01 backend_ui_script]# ifconfig | grep eth3

>

> eth3      Link encap:Ethernet  HWaddr 00:25:90:EA:28:E3

>

> eth3.104  Link encap:Ethernet  HWaddr 00:25:90:EA:28:E3

>

> eth3.105  Link encap:Ethernet  HWaddr 00:25:90:EA:28:E3

>

>

>

> Even though I want to use eth3 with other VLANs . Can you please look into this?

>

> I am already on kernel 3.10.

>

>

>

> Regards,

>

> Madhur

>

>

>

> -----Original Message-----

> From: Ben Pfaff [mailto:blp at nicira.com]

> Sent: 18 September 2014 00:07

> To: Madhur Sethi

> Cc: 'discuss at openvswitch.org'

> Subject: Re: [ovs-discuss] ovs del-port does not clean up ethX.Y vlan

> interfaces

>

>

>

> OK.

>

>

>

> OVS is supposed to remove the vlan interfaces when they are no longer needed.  VLAN splinters are not widely used so there could be a bug.

>

> I'll try to check but it's a low priority.

>

>

>

> Until then, please consider using some other workaround.  The FAQ

> lists

>

> several:

>

>

>

> Q: VLANs don't work.

>

>

>

> A: Many drivers in Linux kernels before version 3.3 had VLAN-related

>

>    bugs.  If you are having problems with VLANs that you suspect to be

>

>    driver related, then you have several options:

>

>

>

>        - Upgrade to Linux 3.3 or later.

>

>

>

>        - Build and install a fixed version of the particular driver

>

>          that is causing trouble, if one is available.

>

>

>

>        - Use a NIC whose driver does not have VLAN problems.

>

>

>

>        - Use "VLAN splinters", a feature in Open vSwitch 1.4 and later

>

>          that works around bugs in kernel drivers.  To enable VLAN

>

>          splinters on interface eth0, use the command:

>

>

>

>            ovs-vsctl set interface eth0

> other-config:enable-vlan-splinters=true

>

>

>

>          For VLAN splinters to be effective, Open vSwitch must know

>

>          which VLANs are in use.  See the "VLAN splinters" section in

>

>          the Interface table in ovs-vswitchd.conf.db(5) for details on

>

>          how Open vSwitch infers in-use VLANs.

>

>

>

>          VLAN splinters increase memory use and reduce performance, so

>

>          use them only if needed.

>

>

>

>        - Apply the "vlan workaround" patch from the XenServer kernel

>

>          patch queue, build Open vSwitch against this patched kernel,

>

>          and then use ovs-vlan-bug-workaround(8) to enable the VLAN

>

>          workaround for each interface whose driver is buggy.

>

>

>

>          (This is a nontrivial exercise, so this option is included

>

>          only for completeness.)

>

>

>

>    It is not always easy to tell whether a Linux kernel driver has

>

>    buggy VLAN support.  The ovs-vlan-test(8) and ovs-test(8) utilities

>

>    can help you test.  See their manpages for details.  Of the two

>

>    utilities, ovs-test(8) is newer and more thorough, but

>

>    ovs-vlan-test(8) may be easier to use.

>

>

>

> On Wed, Sep 17, 2014 at 05:55:54PM +0000, Madhur Sethi wrote:

>

> > No Ben. No ipaddress was configured on the eth3.5. None of the ethX on the host in my setup have ipaddresses.

>

> >

>

> > Regards,

>

> > Madhur Sethi

>

> > -----Original Message-----

>

> > From: Ben Pfaff [mailto:blp at nicira.com]

>

> > Sent: 17 September 2014 23:23

>

> > To: Madhur Sethi

>

> > Cc: 'discuss at openvswitch.org'

>

> > Subject: Re: [ovs-discuss] ovs del-port does not clean up ethX.Y

> > vlan

>

> > interfaces

>

> >

>

> > Did you configure an IP address on eth3.5 (e.g. with "ifconfig")?

>

> >

>

> > On Wed, Sep 17, 2014 at 05:26:50PM +0000, Madhur Sethi wrote:

>

> > > Thanks for the reply Ben.

>

> > >

>

> > > Yes , I did enable the vlan-splinters. The ports have intel igb drivers and the vlan doesn't work without enabling the vlan splinters. If its deprecated then could you please point me to the newer workaround?

>

> > >

>

> > >

>

> > > Regards,

>

> > > Madhur Sethi

>

> > >

>

> > > -----Original Message-----

>

> > > From: Ben Pfaff [mailto:blp at nicira.com]

>

> > > Sent: 17 September 2014 22:52

>

> > > To: Madhur Sethi

>

> > > Cc: 'discuss at openvswitch.org'

>

> > > Subject: Re: [ovs-discuss] ovs del-port does not clean up ethX.Y

>

> > > vlan interfaces

>

> > >

>

> > > On Wed, Sep 17, 2014 at 09:49:23AM +0000, Madhur Sethi wrote:

>

> > > > I am facing an issue wrt the del-port command here. Refer to my config here:

>

> > > > Commands used:

>

> > > > ovs-vsctl add-port OVS-VlanBridge vnet96 ovs-vsctl set port

> > > > vnet96

>

> > > > tag=5 ovs-vsctl add-port OVS-VlanBridge eth3

>

> > > >

>

> > > >

>

> > > > [root@ kvm ~]# ovs-vsctl show

>

> > > > 412338cc-eca8-4ea0-a4d8-793ec0444d23

>

> > > > Bridge OVS-VlanBridge

>

> > > >        Port OVS-VlanBridge

>

> > > >             Interface OVS-VlanBridge

>

> > > >                 type: internal

>

> > > >        Port "eth3"

>

> > > >             Interface "eth3"

>

> > > >        Port "vnet96"

>

> > > >             tag: 5

>

> > > >             Interface "vnet96"

>

> > > >

>

> > > > The port vnet96  is connected to a vm interface which provides outside access to the vm for VLAN 5.

>

> > > > The eth3 port is the physical port on the host connected to the outside world.  It acts as a trunk with no trunk tags specified, hence being a VLAN all trunk port.

>

> > > > Ifconfig output on the host :

>

> > > >

>

> > > > [root@ kvm ~]# ifconfig | grep eth3

>

> > > > eth3      Link encap:Ethernet  HWaddr 0C:C4:7A:12:33:27

>

> > > > eth3.5    Link encap:Ethernet  HWaddr 0C:C4:7A:12:33:27

>

> > > >

>

> > > > The eth3.5 is automatically created by the OVS. If however I delete the eth3 from OVS-VlanBridge using the del-port command the eth3.5 is not cleaned up. Do I need an additional command to clean this up? Or is this an bug?

>

> > >

>

> > > eth3.5 would only be created automatically by OVS if you enable the deprecated "vlan splinters" feature.  Did you enable vlan splinters?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://openvswitch.org/pipermail/discuss/attachments/20141008/6bdff661/attachment-0001.html>


More information about the discuss mailing list