[ovs-discuss] OpenVSwitch - Error packet OFPFMFC_BAD_COMMAND of code ofp_flow_mod_failed_code coming as malformed.
Ben Pfaff
blp at nicira.com
Wed May 23 09:02:49 PDT 2012
Sorry, it's too hard to get the actual OpenFlow messages out of pcap
files. If you have the OpenFlow messages, rather than the ".pcap"s,
I'll take a look.
On Wed, May 23, 2012 at 05:35:28AM +0000, Prabina Pattnaik wrote:
> Please find attached following files with this mail, it is coming malformed in wireshark 1.4.11 (with openflow plugin 1.0):-
> 1. malformed OFPFMFC_BAD_COMMAND error packet
> 2. malformed OFPFMFC_ALL_TABLES_FULL error packet
>
> Observation-
> Error packets which are above 64 bytes of code "ofp_flow_mod_failed_code" are coming as malformed. Other error packets of different code are coming ok.
> After applying our patch for limit the table flows in OVS 1.2.2, OFPFMFC_ALL_TABLES_FULL error packet was also malformed, so enclosing that also for reference.
>
> Regards,
> Prabina
>
>
> -----Original Message-----
> From: Ben Pfaff [mailto:blp at nicira.com]
> Sent: Tuesday, May 22, 2012 11:41 PM
> To: Prabina Pattnaik
> Cc: bugs at openvswitch.org
> Subject: Re: [ovs-discuss] OpenVSwitch - Error packet OFPFMFC_BAD_COMMAND of code ofp_flow_mod_failed_code coming as malformed.
>
> Can you show me this malformed error packet, and tell me in what way
> it is malformed?
>
> On Tue, May 22, 2012 at 09:50:20AM +0000, Prabina Pattnaik wrote:
> > Hi Ben,
> >
> > We agree that implementation of 'at least 64 bytes' is as per spec (to allow data above 64 bytes depends on vendor specific switch implementation).
> > But in current implementation, when the code (mentioned below) limits the size of data to 64 bytes (if data field of the error packet is more than 64 bytes), a malformed OFPFMFC_BAD_COMMAND error packets gets generated (visible on wireshark with openflow plugin).
> >
> > As per our analysis, removal of code to limit the data size to 64, resolves the issue of malformed packet.
> >
> > File: lib/ofputil.c
> > Routine ofputil_encode_error_msg
> >
> > If (oh){
> > Xid = oh->xid;
> > data = oh;
> > len = ntohs(oh->length);
> > - if (len > 64){
> > - len =64;
> > - }
> > }
> >
> >
> > Regards,
> > Prabina
> >
> >
> > -----Original Message-----
> > From: Ben Pfaff [mailto:blp at nicira.com]
> > Sent: Monday, May 21, 2012 10:24 PM
> > To: Prabina Pattnaik
> > Cc: bugs at openvswitch.org
> > Subject: Re: [ovs-discuss] OpenVSwitch - Error packet OFPFMFC_BAD_COMMAND of code ofp_flow_mod_failed_code coming as malformed.
> >
> > On Mon, May 21, 2012 at 11:15:28AM +0000, Prabina Pattnaik wrote:
> > > As per openflow 1.0 spec "data" contains at "least" first 64 bytes
> > > of failed request. This is working correct also in current OVS 1.2.2
> > > code.
> > >
> > > But it is taking an extra check in code (lib/ofp-util.c) on "data"
> > > length that:-
> > >
> > > if data is greater than 64 bytes then it would be truncated to 64
> > > bytes which is making this packet as malformed. OVS code is working
> > > on "at most" 64 bytes length instead of "at least" 64 bytes.
> > >
> > > To avoid the truncation of 'data field ' to 64 bytes, the condition
> > > to check the length of data field in file (lib/ofp-util.c), routine
> > > ofputil_encode_error_msg can be removed.
> >
> > I disagree with your interpretation. "At least" 64 bytes means that
> > OVS is allowed to truncate the inner message after 64 bytes. That is
> > what it is doing.
> >
> >
> >
> > DISCLAIMER:
> >
> > -----------------------------------------------------------------------------------------------------------------------
> >
> > The contents of this e-mail and any attachment(s) are confidential and
> > intended
> >
> > 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. .
> >
> > -----------------------------------------------------------------------------------------------------------------------
>
>
>
> DISCLAIMER:
>
> -----------------------------------------------------------------------------------------------------------------------
>
> The contents of this e-mail and any attachment(s) are confidential and
> intended
>
> 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. .
>
> -----------------------------------------------------------------------------------------------------------------------
More information about the discuss
mailing list