On Mon, 13 May 2019 22:20:01 +0900,
Muhammad Tauseef Khan wrote:
> 
> Hi,
> I have been trying to use conntrack with RYU and I am experiencing the 
> following error messages. I am using a simple match statement and the 
> ActionCT as given on the Ryu's documents page but that is giving me the 
> following errors. I have tried using ovs verion 2.10 as well but no success. 
> Could you please give me an example working code that I can use?

I guess you are hitting this error.

https://github.com/openvswitch/ovs/blob/d58b59c17c70137aebdde37d3c01c26a26b28519/lib/ofp-actions.c#L6467

Specifing a 16 bit value zone_ofs_nbits (or simply omitting the entire
zone thing) should fix the problem.



> 1.  EVENT ofp_event->SimpleSwitch13 EventOFPPacketIn
> 2.  packet in 2 00:00:00:00:00:04 00:00:00:00:00:03 2
> 3.  EventOFPErrorMsg received.
> 4.  version=0x4, msg_type=0x1, msg_len=0x9c, xid=0xb3115c64
> 5.   `-- msg_type: OFPT_ERROR(1)
> 6.  OFPErrorMsg(type=0x2, code=0xe, 
> data=b'\x04\x0e\x00\x90\xb3\x11\x5c\x64\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x0a\x80\x00\x0a\x02\x08\x00\x00\x00\x00\x00\x00\x00\x00\x04\x00\x50\x00\x00\x00\x00\x00\x00\x00\x10\x00\x00\x00\x03\xff\xe5\x00\x00\x00\x00\x00\x00\xff\xff\x00\x38\x00\x00\x23\x20\x00\x23\x00\x01\x00\x01\x00\x04\x01\x1b\xff\x00\x00\x00\x00\x00\xff\xff\x00\x20\x00\x00\x23\x20\x00\x24\x00\x00\x00\x01\x00\x33\x0a\x01\x0c\x00\x0a\x01\x0d\xff\x00\x01\x03\xff\x00\x00\x00\x00')
> 7.   |-- type: OFPET_BAD_ACTION(2)
> 8.   |-- code: OFPBAC_BAD_SET_LEN(14)
> 9.   `-- data: version=0x4, msg_type=0xe, msg_len=0x90, xid=0xb3115c64
> 10.      `-- msg_type: OFPT_FLOW_MOD(14)
> 11. EventOFPErrorMsg received.
> 
> I just tried with a small change in this section and it didn't work.
> 1.  if dst in self.mac_to_port[dpid]:
> 2.      out_port = self.mac_to_port[dpid][dst]
> 3.  else:
> 4.      out_port = ofproto.OFPP_FLOOD
> 5.
> 6.
> 7.  actions = [parser.OFPActionOutput(out_port)]
> 8.
> 9.  # install a flow to avoid packet_in next time
> 10. if out_port != ofproto.OFPP_FLOOD:
> 11.     match = parser.OFPMatch(ct_state=(0, 32))
> 12.     actions += [parser.NXActionCT(
> 13.         flags=1,
> 14.         zone_src="reg0",
> 15.         zone_ofs_nbits=nicira_ext.ofs_nbits(4, 31),
> 16.         recirc_table=4,
> 17.         alg=0,
> 18.         actions=[])]
> 19.     if msg.buffer_id != ofproto.OFP_NO_BUFFER:
> 20.         self.add_flow(datapath, 1, match, actions, msg.buffer_id)
> 21.         return
> 22.     else:
> 23.         self.add_flow(datapath, 1, match, actions)
> 
> Thanks in advance and looking for help
> Tauseef

--
IWAMOTO Toshihiro


_______________________________________________
Ryu-devel mailing list
Ryu-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ryu-devel

Reply via email to