[ovs-discuss] how to remove GRE headers using open flow

俊 赵 zhaojun12 at outlook.com
Thu Jun 18 14:48:32 UTC 2015


hi all, i am new to OVS. i have a problem.
i have two servers, called A and B, both of them have installed OVS. and they are connected by GRE tunnel.
result of ovs-vsctl show in A:[root at 00259064a21e ~]# ovs-vsctl showaa44e5ff-a8fe-44bb-aef1-536c6cb6f10b    Bridge OVS-SWITCH        Port gre-fit-cernet            Interface gre-fit-cernet                type: gre                options: {remote_ip="115.25.86.12"}        Port "em1"            Interface "em1"        Port OVS-SWITCH            Interface OVS-SWITCH                type: internal        Port "em2"            Interface "em2"    ovs_version: "2.3.1-git4750c96"
and B:[root at fedora Documents]# ovs-vsctl show32f5a39d-d05f-4979-bc17-4914b6b1f84a    Bridge OVS-SWITCH        Port gre-cernet-fit            Interface gre-cernet-fit                type: gre                options: {remote_ip="202.38.101.24"}        Port "enp3s2"            Interface "enp3s2"        Port OVS-SWITCH            Interface OVS-SWITCH                type: internal    ovs_version: "2.3.1-git4750c96"
there is also a host H connected with A's port "em2" with an Intranet IP
all the traffic destined to H will be delivered through the GRE tunnel and arriving at A.
and i want to using ovs-ofctl add-flow command to add a flow rule to remove the packets GRE headers and redirect the rest message(embeded packet) through port "em2" to H 
but i donot know how to add the flow table rule.
here is some commands i have tried, but failed.
1)ovs-ofctl add-flow OVS-SWITCH idle_timeout=0,in_port=OVS-SWITCH/em1/gre-fit-cernet,dl_type=0x800,nw_proto=0x2F,actions=strip_vlan,output:em22)ovs-ofctl add-flow OVS-SWITCH idle_timeout=0,in_port=OVS-SWITCH/em1/gre-fit-cernet,dl_type=0x800,nw_src=115.25.86.12,tun_dst=10.0.0.2(host H's ip address),actions=output:em2
thanks!

Zhao Jun 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://openvswitch.org/pipermail/ovs-discuss/attachments/20150618/892a17a6/attachment-0002.html>


More information about the discuss mailing list