[ovs-discuss] Open VSwitch - No 'OFPBRC_BAD_VERSION' error packet received when there is version mismatch between feature request and feature reply

Varun Gupta Varun.Gupta at nechclst.in
Mon May 21 10:52:55 UTC 2012


 We are evaluating OVS 1.2.2  and would like to report an unexpected behavior of OVS.

* Bug Description
Switch is not notifying the controller for OFPBRC_BAD_VERSION, /* ofp_header.version not supported. */  when there is version mismatch between feature request and feature reply. The switch was resetting the connection and only a warning message was generated on switch in log (/var/log/messages) before resetting connection.

* What you did that make the problem appear?

1.        Made the following bridge:
ovs-vsctl show
    Bridge "br0"
        fail_mode: secure
        Port "br0"
            Interface "br0"
                type: internal
        Port "em1"
            Interface "em1"
        Port "vnet0"
            Interface "vnet0"

2.       Issue can be generated by NOX as controller:-

3.       Change ofp-version variable in send_features_request routine to 2 in openflow.c file in NOX

4.       Make connection between switch and NOX

* What you expected to happen?
      Error packet with code " OFPBRC_BAD_VERSION " should generate by switch to controller.

* What actually happened.
   No error packet is generating and connection resets by switch after stats request packet from controller.

* The Open vSwitch version number (as output by "ovs-vswitchd --version")

ovs-vswitchd (Open vSwitch) 1.2.2
Compiled May 21 2012 11:23:22
OpenFlow versions 0x1:0x1

* The Git commit number (as output by "git rev-parse HEAD"),
   if you built from a Git snapshot.
   Not from git.

 * Any local patches or changes you have applied (if any).
   No patches are applied.

* The kernel version on which Open vSwitch is running (from

   /proc/version) and the distribution and version number of

   your OS (e.g. "Centos 5.0").

Linux version (mockbuild at x86-04.phx2.fedoraproject.org<mailto:mockbuild at x86-04.phx2.fedoraproject.org>) (gcc version 4.6.0 20110428 (Red Hat 4.6.0-6) (GCC) ) #1 SMP Mon May 9 20:45:15 UTC 2011

OVS OS- Fedora 15
NOX OS - Ubuntu 10.0.4

* The output of "ovs-dpctl show".
system at br0:
                lookups: frags:0, hit:30, missed:6, lost:0
                port 0: br0 (internal)
                port 1: em1

* A fix or workaround, if you have one.
When Incorrect version is set in ofp-header in a feature request packet from controller, the switch resets the connection and no error packet is sent to controller, only warning message is generated on switch.
If we add a condition in vconn.c file to prevent the reset of connection on receiving incorrect version in feature request packet and in ofproto.c file to first check whether version in feature request packet is same as that of version supported by switch ,if versions are different we return error packet to controller. This gives us the desired output.

* Any other information that you think might be relevant.
We have verified this on OVS-1.4.1, same is happening on this release also.



The contents of this e-mail and any attachment(s) are confidential and

for the named recipient(s) only. 

It shall not attach any liability on the originator or NECHCL or its

affiliates. Any views or opinions presented in 

this email are solely those of the author and may not necessarily reflect the

opinions of NECHCL or its affiliates. 

Any form of reproduction, dissemination, copying, disclosure, modification,

distribution and / or publication of 

this message without the prior written consent of the author of this e-mail is

strictly prohibited. If you have 

received this email in error please delete it and notify the sender

immediately. .

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://openvswitch.org/pipermail/ovs-discuss/attachments/20120521/ecbdc40e/attachment.html>

More information about the discuss mailing list