Flows are changed when post flows to OVS using ODL OVSDB Rest API

asked 2015-09-16 19:21:27 -0700

nevalosa gravatar image

Recently I practice Openstack neutron to build a VxLAN. First I add flow by ovs-ofctl add-flows and validate flows, the vxlan network works fine.

Flows show as below:

table=0, n_packets=264, n_bytes=25480, in_port=18 actions=set_field:0xc8->tun_id,resubmit(,1)
table=0, n_packets=135, n_bytes=12838, in_port=15 actions=set_field:0x64->tun_id,resubmit(,1)
table=0, n_packets=438, n_bytes=42546, actions=resubmit(,1)
table=1, n_packets=264, n_bytes=25480, tun_id=0xc8 actions=output:6000
table=1, n_packets=135, n_bytes=12838, tun_id=0x64 actions=output:6000
table=1, n_packets=135, n_bytes=12838, dl_dst=fa:16:3e:6c:8b:37 actions=output:15
table=1, n_packets=264, n_bytes=25480, dl_dst=fa:16:3e:ff:48:43 actions=output:18
table=1, n_packets=0, n_bytes=0, arp,arp_tpa=30.0.0.2 actions=output:18
table=1, n_packets=0, n_bytes=0, arp,arp_tpa=20.0.0.2 actions=output:15
table=1, n_packets=39, n_bytes=4228, priority=100 actions=drop

Then I try to integrate neutron with ODL, by sending flows with ODL OVSDB RestAPI(http://{host}/restconf/config/opendaylight-inventory:nodes/node/openflow:1/table/0/), the network works as I expected. But flows are changed as below(ovs-ofctl dump-flows):

table=0, n_packets=48382, n_bytes=4666617, priority=2,in_port=6000 actions=output:23,output:9787,output:22,output:18,output:17,output:14,output:15,CONTROLLER:65535

table=0, n_packets=24545, n_bytes=2345770, priority=2,in_port=15 actions=output:23,output:9787,output:22,output:18,output:17,output:6000,output:14,CONTROLLER:65535

table=0, n_packets=24628, n_bytes=2353848, priority=2,in_port=18 actions=output:23,output:9787,output:22,output:17,output:6000,output:14,output:15,CONTROLLER:65535
....
....//ignored some other in_port flows.

My questions are:

  • What happened when controller add flows to OVS?
  • Are these flows equivalent to original flows?
  • Where can I get more information for reference?

Appreciate any help on this.

edit retag flag offensive close merge delete

Comments

This hasn't happened before when I try with Mininet, and flows dump are all the same. Another [Resolved Question](https://ask.opendaylight.org/question/4755/add-flows-via-restconf-to-build-vxlan-resolved/) shows the XML flows.

nevalosa ( 2015-09-16 19:26:10 -0700 )edit