Hi!
I have a question regarding stripping of VLAN tags from packets.

I have the following setup:
I am running ryu 4.15 on an Ubuntu Laptop and Open Vswitch 2.3.0 on a
Raspberry PI3. Both are connected using WiFi.

I was able to connect the two components and started playing around using
the REST interface provided by the ryu app ryu.app.ofctl_rest.

Using that interface I was able to set create some flows and assign them to
the Open Vswitch. However I failed creating a flow rule that strips all
VLAN tags of all incoming packets of a specific port.
Trying to use OpenFlow 1.0 I executed:
curl -X POST -d '{"dpid":
168082741711624,"match":{"in_port":2},"actions":[{"type":
"STRIP_VLAN"},{"type": "OUTPUT","port": 1}]}'
http://localhost:8080/stats/flowentry/add

As a result, a new flow rule is created in the Open Vswitch with all the
parameters I configured. However, the strip_vlan action is simply missing.

Trying to use OpenFlow 1.2 I executed:
curl -X POST -d '{"dpid":
168082741711624,"match":{"in_port":2},"actions":[{"type":
"POP_VLAN"},{"type": "OUTPUT","port": 1}]}'
http://localhost:8080/stats/flowentry/add

As a result, no flow rule is created at the Open Vswitch. Instead the ryu
outputs me the following error message:

(24452) accepted ('127.0.0.1', 42986)
Sending message with xid(18b57a6) to datapath(000098ded01cd308):
version=None,msg_type=None,msg_len=None,xid=0x18b57a6,OFPFlowMod(buffer_id=4294967295,command=0,cookie=0,cookie_mask=0,flags=0,hard_timeout=0,idle_timeout=0,instructions=[OFPInstructionActions(actions=[OFPActionPopVlan(len=8,type=18),
OFPActionOutput(len=16,max_len=65509,port=1,type=0)],type=4)],match=OFPMatch(oxm_fields={'in_port':
2}),out_group=4294967295,out_port=4294967295,priority=0,table_id=0)
127.0.0.1 - - [21/Aug/2018 13:26:07] "POST /stats/flowentry/add HTTP/1.1"
200 115 0.001092
EventOFPErrorMsg received.
version=0x4, msg_type=0x1, msg_len=0x4c, xid=0x18b57a6
 `-- msg_type: OFPT_ERROR(1)
OFPErrorMsg(type=0x2, code=0xa,
data=b'\x04\x0e\x00\x60\x01\x8b\x57\xa6\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x01\x00\x0c\x80\x00\x00\x04\x00\x00\x00\x02\x00\x00\x00\x00')
 |-- type: OFPET_BAD_ACTION(2)
 |-- code: OFPBAC_MATCH_INCONSISTENT(10)
 `-- data: version=0x4, msg_type=0xe, msg_len=0x60, xid=0x18b57a6
     `-- msg_type: OFPT_FLOW_MOD(14)

Could anybody please give me a hint what I am messing up here?

Thanks,
Marco
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Ryu-devel mailing list
Ryu-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ryu-devel

Reply via email to