1 AT_BANNER([ofproto-dpif])
3 AT_SETUP([ofproto-dpif - revalidator/wait])
5 AT_CHECK([ovs-appctl revalidator/wait])
9 AT_SETUP([ofproto-dpif, active-backup bonding])
10 # Create br0 with interfaces p1, p2 and p7, creating bond0 with p1 and p2
11 # and br1 with interfaces p3, p4 and p8.
12 # toggle p1,p2 of bond0 up and down to test bonding in active-backup mode.
14 [add-bond br0 bond0 p1 p2 bond_mode=active-backup --\
15 set interface p1 type=dummy options:pstream=punix:$OVS_RUNDIR/p1.sock ofport_request=1 -- \
16 set interface p2 type=dummy options:pstream=punix:$OVS_RUNDIR/p2.sock ofport_request=2 -- \
17 add-port br0 p7 -- set interface p7 ofport_request=7 type=dummy -- \
19 set bridge br1 other-config:hwaddr=aa:66:aa:66:00:00 -- \
20 set bridge br1 datapath-type=dummy other-config:datapath-id=1234 \
22 add-port br1 p3 -- set interface p3 type=dummy options:stream=unix:$OVS_RUNDIR/p1.sock ofport_request=3 -- \
23 add-port br1 p4 -- set interface p4 type=dummy options:stream=unix:$OVS_RUNDIR/p2.sock ofport_request=4 -- \
24 add-port br1 p8 -- set interface p8 ofport_request=8 type=dummy --])
25 WAIT_FOR_DUMMY_PORTS([p3], [p4])
26 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
28 AT_CHECK([ovs-ofctl add-flow br0 action=normal])
29 AT_CHECK([ovs-ofctl add-flow br1 action=normal])
30 ovs-appctl netdev-dummy/set-admin-state up
31 ovs-appctl time/warp 100
32 ovs-appctl netdev-dummy/set-admin-state p2 down
34 ovs-appctl time/warp 100
35 AT_CHECK([ovs-appctl netdev-dummy/receive p7 'in_port(7),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
36 AT_CHECK([ovs-appctl netdev-dummy/receive p7 'in_port(7),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.3,dst=10.0.0.4,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
37 ovs-appctl time/warp 100
38 ovs-appctl netdev-dummy/set-admin-state p2 up
39 ovs-appctl netdev-dummy/set-admin-state p1 down
40 ovs-appctl time/warp 100
41 AT_CHECK([ovs-appctl netdev-dummy/receive p7 'in_port(7),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0d),eth_type(0x0800),ipv4(src=10.0.0.5,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
42 AT_CHECK([ovs-appctl netdev-dummy/receive p7 'in_port(7),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0e),eth_type(0x0800),ipv4(src=10.0.0.6,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
43 ovs-appctl time/warp 200 100
45 AT_CHECK([cat ovs-vswitchd.log | grep 'in_port=[[348]]' | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
46 recirc_id=0,ip,in_port=3,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,nw_frag=no, actions: <del>
47 recirc_id=0,ip,in_port=3,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:0b,dl_dst=50:54:00:00:00:0c,nw_frag=no, actions: <del>
48 recirc_id=0,ip,in_port=4,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0d,nw_frag=no, actions: <del>
49 recirc_id=0,ip,in_port=4,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0e,nw_frag=no, actions: <del>
50 recirc_id=0,rarp,in_port=4,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:09,dl_dst=ff:ff:ff:ff:ff:ff, actions: <del>
51 recirc_id=0,rarp,in_port=4,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:0b,dl_dst=ff:ff:ff:ff:ff:ff, actions: <del>
56 AT_SETUP([ofproto-dpif, balance-slb bonding])
57 # Create br0 with interfaces bond0(p1, p2, p3) and p7,
58 # and br1 with interfaces p4, p5, p6 and p8.
59 # p1 <-> p4, p2 <-> p5, p3 <-> p6
60 # Send some traffic, make sure the traffic are spread based on source mac.
62 [add-bond br0 bond0 p1 p2 p3 bond_mode=balance-slb --\
63 set interface p1 type=dummy options:pstream=punix:$OVS_RUNDIR/p1.sock ofport_request=1 -- \
64 set interface p2 type=dummy options:pstream=punix:$OVS_RUNDIR/p2.sock ofport_request=2 -- \
65 set interface p3 type=dummy options:pstream=punix:$OVS_RUNDIR/p3.sock ofport_request=3 -- \
66 add-port br0 p7 -- set interface p7 ofport_request=7 type=dummy -- \
68 set bridge br1 other-config:hwaddr=aa:66:aa:66:00:00 -- \
69 set bridge br1 datapath-type=dummy other-config:datapath-id=1234 \
71 add-port br1 p4 -- set interface p4 type=dummy options:stream=unix:$OVS_RUNDIR/p1.sock ofport_request=4 -- \
72 add-port br1 p5 -- set interface p5 type=dummy options:stream=unix:$OVS_RUNDIR/p2.sock ofport_request=5 -- \
73 add-port br1 p6 -- set interface p6 type=dummy options:stream=unix:$OVS_RUNDIR/p3.sock ofport_request=6 -- \
74 add-port br1 p8 -- set interface p8 ofport_request=8 type=dummy --])
75 WAIT_FOR_DUMMY_PORTS([p4], [p5], [p6])
76 AT_CHECK([ovs-ofctl add-flow br0 action=normal])
77 AT_CHECK([ovs-ofctl add-flow br1 action=normal])
78 AT_CHECK([ovs-appctl netdev-dummy/set-admin-state up], 0, [OK
81 ovs-appctl time/warp 100
83 for i in `seq 0 100 |xargs printf '%02x\n'`;
85 pkt="in_port(7),eth(src=50:54:00:00:00:$i,dst=50:54:00:00:01:00),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)"
86 AT_CHECK([ovs-appctl netdev-dummy/receive p7 $pkt])
89 ovs-appctl time/warp 100
90 AT_CHECK([ovs-appctl dpif/dump-flows br1 > br1_flows.txt])
91 # Make sure there is resonable distribution to all three ports.
92 # We don't want to make this check precise, in case hash function changes.
93 AT_CHECK([test `egrep 'in_port\(4\)' br1_flows.txt |wc -l` -gt 3])
94 AT_CHECK([test `egrep 'in_port\(5\)' br1_flows.txt |wc -l` -gt 3])
95 AT_CHECK([test `egrep 'in_port\(6\)' br1_flows.txt |wc -l` -gt 3])
99 AT_SETUP([ofproto-dpif, balance-tcp bonding])
100 # Create br0 with interfaces bond0(p1, p2, p3) and p7,
101 # and br1 with interfaces bond1(p4, p5, p6) and p8.
103 # Send some traffic, make sure the traffic are spread based on L4 headers.
105 [add-bond br0 bond0 p1 p2 p3 bond_mode=balance-tcp lacp=active \
106 other-config:lacp-time=fast other-config:bond-rebalance-interval=0 --\
107 set interface p1 type=dummy options:pstream=punix:$OVS_RUNDIR/p1.sock ofport_request=1 -- \
108 set interface p2 type=dummy options:pstream=punix:$OVS_RUNDIR/p2.sock ofport_request=2 -- \
109 set interface p3 type=dummy options:pstream=punix:$OVS_RUNDIR/p3.sock ofport_request=3 -- \
110 add-port br0 p7 -- set interface p7 ofport_request=7 type=dummy -- \
112 set bridge br1 other-config:hwaddr=aa:66:aa:66:00:00 -- \
113 set bridge br1 datapath-type=dummy other-config:datapath-id=1234 \
114 fail-mode=secure -- \
115 add-bond br1 bond1 p4 p5 p6 bond_mode=balance-tcp lacp=active \
116 other-config:lacp-time=fast other-config:bond-rebalance-interval=0 --\
117 set interface p4 type=dummy options:stream=unix:$OVS_RUNDIR/p1.sock ofport_request=4 -- \
118 set interface p5 type=dummy options:stream=unix:$OVS_RUNDIR/p2.sock ofport_request=5 -- \
119 set interface p6 type=dummy options:stream=unix:$OVS_RUNDIR/p3.sock ofport_request=6 -- \
120 add-port br1 p8 -- set interface p8 ofport_request=8 type=dummy --])
121 AT_CHECK([ovs-appctl netdev-dummy/set-admin-state up], 0, [OK
123 AT_CHECK([ovs-ofctl add-flow br0 action=normal])
124 AT_CHECK([ovs-ofctl add-flow br1 action=normal])
125 AT_CHECK([ovs-appctl upcall/disable-megaflows], [0], [megaflows disabled
127 OVS_WAIT_WHILE([ovs-appctl bond/show | grep "may_enable: false"])
129 ovs-appctl time/warp 100
130 ovs-appctl lacp/show > lacp.txt
131 ovs-appctl bond/show > bond.txt
133 for i in `seq 0 255` ;
135 pkt="in_port(7),eth(src=50:54:00:00:00:05,dst=50:54:00:00:01:00),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=$i),tcp_flags(ack)"
136 AT_CHECK([ovs-appctl netdev-dummy/receive p7 $pkt])
139 ovs-appctl time/warp 300 100
140 AT_CHECK([ovs-appctl dpif/dump-flows br0 |grep tcp > br0_flows.txt])
141 AT_CHECK([ovs-appctl dpif/dump-flows br1 |grep tcp > br1_flows.txt])
142 # Make sure there is resonable distribution to all three ports.
143 # We don't want to make this check precise, in case hash function changes.
144 AT_CHECK([test `grep in_port.4 br1_flows.txt |wc -l` -gt 24])
145 AT_CHECK([test `grep in_port.5 br1_flows.txt |wc -l` -gt 24])
146 AT_CHECK([test `grep in_port.6 br1_flows.txt |wc -l` -gt 24])
150 AT_SETUP([ofproto-dpif - resubmit])
152 ADD_OF_PORTS([br0], [1], [10], [11], [12], [13], [14], [15],
153 [16], [17], [18], [19], [20], [21])
154 AT_DATA([flows.txt], [dnl
155 table=0 in_port=1 priority=1000 icmp actions=output(10),resubmit(2),output(19),resubmit(3),output(21)
156 table=0 in_port=2 priority=1500 icmp actions=output(11),resubmit(,1),output(16),resubmit(2,1),output(18)
157 table=0 in_port=3 priority=2000 icmp actions=output(20)
158 table=1 in_port=1 priority=1000 icmp actions=output(12),resubmit(4,1),output(13),resubmit(3),output(15)
159 table=1 in_port=2 priority=1500 icmp actions=output(17),resubmit(,2)
160 table=1 in_port=3 priority=1500 icmp actions=output(14),resubmit(,2)
162 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
163 AT_CHECK([ovs-appctl ofproto/trace br0 'in_port=1,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,dl_type=0x0800,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=1,nw_tos=0,nw_ttl=128,icmp_type=8,icmp_code=0'], [0], [stdout])
164 AT_CHECK([tail -1 stdout], [0],
165 [Datapath actions: 10,11,12,13,14,15,16,17,18,19,20,21
170 AT_SETUP([ofproto-dpif - goto table])
172 ADD_OF_PORTS([br0], [1], [10], [11])
173 echo "table=0 in_port=1 actions=output(10),goto_table(1)" > flows.txt
174 for i in `seq 1 63`; do echo "table=$i actions=goto_table($(($i+1)))"; done >> flows.txt
175 echo "table=64 actions=output(11)" >> flows.txt
176 AT_CHECK([ovs-ofctl -O OpenFlow12 add-flows br0 flows.txt])
177 AT_CHECK([ovs-appctl ofproto/trace br0 'in_port=1,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,dl_type=0x0800,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=1,nw_tos=0,nw_ttl=128,icmp_type=8,icmp_code=0'], [0], [stdout])
178 AT_CHECK([tail -1 stdout], [0],
179 [Datapath actions: 10,11
184 AT_SETUP([ofproto-dpif - write actions])
186 ADD_OF_PORTS([br0], [1], [10], [11], [12], [13])
187 AT_DATA([flows.txt], [dnl
188 table=0 in_port=1,ip actions=output(10),write_actions(set_field:192.168.3.90->ip_src,output(12)),goto_table(1)
189 table=1 ip actions=write_actions(output(13)),goto_table(2)
190 table=2 ip actions=set_field:192.168.3.91->ip_src,output(11)
192 AT_CHECK([ovs-ofctl -O OpenFlow12 add-flows br0 flows.txt])
193 AT_CHECK([ovs-appctl ofproto/trace br0 'in_port=1,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,dl_type=0x0800,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=1,nw_tos=0,nw_ttl=128,icmp_type=8,icmp_code=0'], [0], [stdout])
194 AT_CHECK([tail -2 stdout], [0],
195 [Megaflow: recirc_id=0,ip,in_port=1,nw_src=192.168.0.1,nw_frag=no
196 Datapath actions: 10,set(ipv4(src=192.168.3.91)),11,set(ipv4(src=192.168.3.90)),13
201 AT_SETUP([ofproto-dpif - clear actions])
203 ADD_OF_PORTS([br0], [1], [10], [11], [12])
204 AT_DATA([flows.txt], [dnl
205 table=0 in_port=1,ip actions=output(10),write_actions(set_field:192.168.3.90->ip_src,output(12)),goto_table(1)
206 table=1 tcp actions=set_field:91->tp_src,output(11),clear_actions
208 AT_CHECK([ovs-ofctl -O OpenFlow12 add-flows br0 flows.txt])
209 AT_CHECK([ovs-appctl ofproto/trace br0 'in_port=1,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,dl_type=0x0800,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=6,nw_tos=0,nw_ttl=128,tp_src=8,tp_dst=9'], [0], [stdout])
210 AT_CHECK([tail -2 stdout], [0],
211 [Megaflow: recirc_id=0,tcp,in_port=1,nw_frag=no,tp_src=8
212 Datapath actions: 10,set(tcp(src=91)),11
217 AT_SETUP([ofproto-dpif - group chaining not supported])
219 ADD_OF_PORTS([br0], [1], [10], [11])
220 AT_CHECK([ovs-ofctl -O OpenFlow12 add-group br0 'group_id=1234,type=all,bucket=output:10,set_field:192.168.3.90->ip_src,group:123,bucket=output:11'],
222 AT_CHECK([STRIP_XIDS stderr | sed 1q], [0],
223 [OFPT_ERROR (OF1.2): OFPGMFC_CHAINING_UNSUPPORTED
228 AT_SETUP([ofproto-dpif - all group in action list])
230 ADD_OF_PORTS([br0], [1], [10], [11])
231 AT_CHECK([ovs-ofctl -O OpenFlow12 add-group br0 'group_id=1234,type=all,bucket=output:10,set_field:192.168.3.90->ip_src,bucket=output:11'])
232 AT_CHECK([ovs-ofctl -O OpenFlow12 add-flow br0 'ip actions=group:1234'])
233 AT_CHECK([ovs-appctl ofproto/trace br0 'in_port=1,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,dl_type=0x0800,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=1,nw_tos=0,nw_ttl=128,icmp_type=8,icmp_code=0'], [0], [stdout])
234 # Must match on the source address to be able to restore it's value for
236 AT_CHECK([tail -2 stdout], [0],
237 [Megaflow: recirc_id=0,ip,in_port=1,nw_src=192.168.0.1,nw_frag=no
238 Datapath actions: set(ipv4(src=192.168.3.90)),10,set(ipv4(src=192.168.0.1)),11
243 AT_SETUP([ofproto-dpif - indirect group in action list])
245 ADD_OF_PORTS([br0], [1], [10])
246 AT_CHECK([ovs-ofctl -O OpenFlow12 add-group br0 group_id=1234,type=indirect,bucket=output:10])
247 AT_CHECK([ovs-ofctl -O OpenFlow12 add-flow br0 'ip actions=group:1234'])
248 AT_CHECK([ovs-appctl ofproto/trace br0 'in_port=1,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,dl_type=0x0800,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=1,nw_tos=0,nw_ttl=128,icmp_type=8,icmp_code=0'], [0], [stdout])
249 AT_CHECK([tail -1 stdout], [0],
250 [Datapath actions: 10
255 AT_SETUP([ofproto-dpif - all group in action set])
257 ADD_OF_PORTS([br0], [1], [10], [11])
258 AT_CHECK([ovs-ofctl -O OpenFlow12 add-group br0 'group_id=1234,type=all,bucket=output:10,set_field:192.168.3.90->ip_src,bucket=output:11'])
259 AT_CHECK([ovs-ofctl -O OpenFlow12 add-flow br0 'ip actions=write_actions(group:1234)'])
260 AT_CHECK([ovs-appctl ofproto/trace br0 'in_port=1,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,dl_type=0x0800,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=1,nw_tos=0,nw_ttl=128,icmp_type=8,icmp_code=0'], [0], [stdout])
261 # Must match on the source address to be able to restore it's value for
263 AT_CHECK([tail -2 stdout], [0],
264 [Megaflow: recirc_id=0,ip,in_port=1,nw_src=192.168.0.1,nw_frag=no
265 Datapath actions: set(ipv4(src=192.168.3.90)),10,set(ipv4(src=192.168.0.1)),11
270 AT_SETUP([ofproto-dpif - indirect group in action set])
272 ADD_OF_PORTS([br0], [1], [10])
273 AT_CHECK([ovs-ofctl -O OpenFlow12 add-group br0 group_id=1234,type=indirect,bucket=output:10])
274 AT_CHECK([ovs-ofctl -O OpenFlow12 add-flow br0 'ip actions=write_actions(group:1234)'])
275 AT_CHECK([ovs-appctl ofproto/trace br0 'in_port=1,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,dl_type=0x0800,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=1,nw_tos=0,nw_ttl=128,icmp_type=8,icmp_code=0'], [0], [stdout])
276 AT_CHECK([tail -1 stdout], [0],
277 [Datapath actions: 10
282 AT_SETUP([ofproto-dpif - select group])
284 ADD_OF_PORTS([br0], [1], [10], [11])
285 AT_CHECK([ovs-ofctl -O OpenFlow12 add-group br0 'group_id=1234,type=select,bucket=output:10,bucket=output:11'])
286 AT_CHECK([ovs-ofctl -O OpenFlow12 add-flow br0 'ip actions=write_actions(group:1234)'])
288 # Try a bunch of different flows and make sure that they get distributed
290 for d in 0 1 2 3 4 5 6 7 8 9 a b c d e f; do
291 AT_CHECK([ovs-appctl ofproto/trace br0 "in_port=1,dl_src=50:54:00:00:00:07,dl_dst=50:54:00:00:00:0$d,dl_type=0x0800,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=1,nw_tos=0,nw_ttl=128,icmp_type=8,icmp_code=0"], [0], [stdout])
292 tail -1 stdout >> results
294 sort results | uniq -c
295 AT_CHECK([sort results | uniq], [0],
296 [Datapath actions: 10
302 AT_SETUP([ofproto-dpif - select group with watch port])
304 ADD_OF_PORTS([br0], [1], [10], [11])
305 AT_CHECK([ovs-ofctl -O OpenFlow12 add-group br0 'group_id=1234,type=select,bucket=watch_port:10,output:10,bucket=output:11'])
306 AT_CHECK([ovs-ofctl -O OpenFlow12 add-flow br0 'ip actions=write_actions(group:1234)'])
307 AT_CHECK([ovs-appctl ofproto/trace br0 'in_port=1,dl_src=50:54:00:00:00:07,dl_dst=50:54:00:00:00:07,dl_type=0x0800,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=1,nw_tos=0,nw_ttl=128,icmp_type=8,icmp_code=0'], [0], [stdout])
308 AT_CHECK([tail -1 stdout], [0],
309 [Datapath actions: 11
314 AT_SETUP([ofproto-dpif - select group with weight])
316 ADD_OF_PORTS([br0], [1], [10], [11], [12])
317 AT_CHECK([ovs-ofctl -O OpenFlow12 add-group br0 'group_id=1234,type=select,bucket=output:10,bucket=output:11,weight=2000,bucket=output:12,weight=0'])
318 AT_CHECK([ovs-ofctl -O OpenFlow12 add-flow br0 'ip actions=write_actions(group:1234)'])
319 AT_CHECK([ovs-appctl ofproto/trace br0 'in_port=1,dl_src=50:54:00:00:00:07,dl_dst=50:54:00:00:00:07,dl_type=0x0800,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=1,nw_tos=0,nw_ttl=128,icmp_type=8,icmp_code=0'], [0], [stdout])
320 AT_CHECK([tail -1 stdout], [0],
321 [Datapath actions: 11
326 AT_SETUP([ofproto-dpif - fast failover group])
328 ADD_OF_PORTS([br0], [1], [10], [11])
329 AT_CHECK([ovs-ofctl -O OpenFlow12 add-group br0 'group_id=1234,type=ff,bucket=watch_port:10,output:10,bucket=watch_port:11,output:11'])
330 AT_CHECK([ovs-ofctl -O OpenFlow12 add-flow br0 'ip actions=write_actions(group:1234)'])
331 AT_CHECK([ovs-appctl ofproto/trace br0 'in_port=1,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,dl_type=0x0800,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=1,nw_tos=0,nw_ttl=128,icmp_type=8,icmp_code=0'], [0], [stdout])
332 AT_CHECK([tail -1 stdout], [0],
333 [Datapath actions: drop
338 AT_SETUP([ofproto-dpif - group stats single bucket])
340 ADD_OF_PORTS([br0], [1], [10], [11])
341 AT_CHECK([ovs-ofctl -O OpenFlow12 add-group br0 'group_id=1234,type=select,bucket=output:10,weight=2000,bucket=output:11,weight=0'])
342 AT_CHECK([ovs-ofctl -O OpenFlow12 add-flow br0 'ip actions=write_actions(group:1234)'])
346 pkt="in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:01:00),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)"
347 AT_CHECK([ovs-appctl netdev-dummy/receive p1 $pkt])
350 ovs-appctl time/warp 100
351 ovs-appctl revalidator/wait
352 AT_CHECK([ovs-ofctl -O OpenFlow12 -vwarn dump-group-stats br0], [0], [stdout])
353 AT_CHECK([STRIP_XIDS stdout | sort], [0], [dnl
354 group_id=1234,ref_count=0,packet_count=3,byte_count=180,bucket0:packet_count=3,byte_count=180,bucket1:packet_count=0,byte_count=0
355 OFPST_GROUP reply (OF1.2):
360 AT_SETUP([ofproto-dpif - group stats all buckets])
362 ADD_OF_PORTS([br0], [1], [10], [11])
363 AT_CHECK([ovs-ofctl -O OpenFlow12 add-group br0 'group_id=1234,type=all,bucket=output:10,bucket=output:11'])
364 AT_CHECK([ovs-ofctl -O OpenFlow12 add-flow br0 'ip actions=write_actions(group:1234)'])
368 pkt="in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:01:00),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)"
369 AT_CHECK([ovs-appctl netdev-dummy/receive p1 $pkt])
372 ovs-appctl time/warp 100
373 ovs-appctl revalidator/wait
374 AT_CHECK([ovs-ofctl -O OpenFlow12 -vwarn dump-group-stats br0], [0], [stdout])
375 AT_CHECK([STRIP_XIDS stdout | sort], [0], [dnl
376 group_id=1234,ref_count=0,packet_count=3,byte_count=180,bucket0:packet_count=3,byte_count=180,bucket1:packet_count=3,byte_count=180
377 OFPST_GROUP reply (OF1.2):
382 AT_SETUP([ofproto-dpif - registers])
384 ADD_OF_PORTS([br0], [20], [21], [22], [33], [90])
385 AT_DATA([flows.txt], [dnl
386 in_port=90 actions=resubmit:2,resubmit:3,resubmit:4,resubmit:91
387 in_port=91 actions=resubmit:5,resubmit:6,resubmit:7,resubmit:92
388 in_port=92 actions=resubmit:8,resubmit:9,resubmit:10,resubmit:11,resubmit:93
389 in_port=93 actions=resubmit:12,resubmit:13,resubmit:14,resubmit:15
391 in_port=2 actions=load:0x000db000->NXM_NX_REG0[[]]
392 in_port=3 actions=load:0xdea->NXM_NX_REG0[[20..31]]
393 in_port=4 actions=load:0xeef->NXM_NX_REG0[[0..11]]
394 in_port=5 actions=move:NXM_NX_REG0[[]]->NXM_NX_REG1[[]]
395 in_port=6 actions=load:0x22222222->NXM_NX_REG2[[]]
396 in_port=7 actions=move:NXM_NX_REG1[[20..31]]->NXM_NX_REG2[[0..11]]
397 in_port=8 actions=move:NXM_NX_REG1[[0..11]]->NXM_NX_REG2[[20..31]]
398 in_port=9,reg0=0xdeadbeef actions=output:20
399 in_port=10,reg1=0xdeadbeef actions=output:21
400 in_port=11,reg2=0xeef22dea actions=output:22
402 dnl Sanilty check all registers
403 in_port=12 actions=load:0x10->NXM_NX_REG0[[]],load:0x11->NXM_NX_REG1[[]],load:0x12->NXM_NX_REG2[[]]
404 in_port=13 actions=load:0x13->NXM_NX_REG3[[]],load:0x14->NXM_NX_REG4[[]],load:0x15->NXM_NX_REG5[[]]
405 in_port=14 actions=load:0x16->NXM_NX_REG6[[]],load:0x17->NXM_NX_REG7[[]]
406 in_port=15,reg0=0x10,reg1=0x11,reg2=0x12,reg3=0x13,reg4=0x14,reg5=0x15,reg6=0x16,reg7=0x17 actions=output:33
409 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
410 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy 'in_port(90),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)'], [0], [stdout])
411 AT_CHECK([tail -1 stdout], [0],
412 [Datapath actions: 20,21,22,33
417 dnl Tests that the standardized xregs are mapped onto the legacy OVS registers
418 dnl in the manner documented in ovs-ofctl(8).
419 AT_SETUP([ofproto-dpif - extended registers])
421 ADD_OF_PORTS([br0], [1], [2], [3])
422 AT_DATA([flows.txt], [dnl
423 table=0 actions=load:0xfedcba9876543210->OXM_OF_PKT_REG1[[]],resubmit(,1)
424 table=1,reg2=0xfedcba98,reg3=0x76543210 actions=2
426 # These low-priority rules shouldn't match. They're here only to make really
427 # sure that the test fails if either of the above rules fails to match.
428 table=0,priority=0 actions=3
429 table=1,priority=0 actions=3
431 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
432 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)'], [0], [stdout])
433 AT_CHECK([tail -1 stdout], [0], [Datapath actions: 2
438 AT_SETUP([ofproto-dpif - load and move order])
440 ADD_OF_PORTS([br0], [1], [10], [11])
441 AT_CHECK([ovs-ofctl -O OpenFlow12 add-group br0 'group_id=1234,type=all,bucket=output:10,move:NXM_NX_REG1[[]]->NXM_OF_IP_SRC[[]],bucket=output:11'])
442 AT_CHECK([ovs-ofctl -O OpenFlow12 add-flow br0 'ip actions=write_actions(load:0xffffffff->NXM_NX_REG1[[]],move:NXM_NX_REG1[[]]->NXM_NX_REG2[[]],group:1234)'])
443 AT_CHECK([ovs-appctl ofproto/trace br0 'in_port=1,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,dl_type=0x0800,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=1,nw_tos=0,nw_ttl=128,icmp_type=8,icmp_code=0'], [0], [stdout])
444 AT_CHECK([tail -2 stdout], [0],
445 [Megaflow: recirc_id=0,ip,in_port=1,nw_src=192.168.0.1,nw_frag=no
446 Datapath actions: set(ipv4(src=255.255.255.255)),10,set(ipv4(src=192.168.0.1)),11
451 dnl Tests that 1.5 copy-field can copy into the standardized xregs.
452 AT_SETUP([ofproto-dpif - copy-field into extended registers])
454 ADD_OF_PORTS([br0], [1], [2], [3])
455 AT_DATA([flows.txt], [dnl
456 table=0 actions=move:OXM_OF_ETH_SRC[[0..47]]->OXM_OF_PKT_REG0[[0..47]],goto_table(1)
457 table=1,xreg0=0x0000505400000005 actions=2
459 # These low-priority rules shouldn't match. They're here only to make really
460 # sure that the test fails if either of the above rules fails to match.
461 table=0,priority=0 actions=3
462 table=1,priority=0 actions=3
464 AT_CHECK([ovs-ofctl -O OpenFlow15 add-flows br0 flows.txt])
465 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)'], [0], [stdout])
466 AT_CHECK([tail -1 stdout], [0], [Datapath actions: 2
471 AT_SETUP([ofproto-dpif - push-pop])
473 ADD_OF_PORTS([br0], [20], [21], [22], [33], [90])
474 AT_DATA([flows.txt], [dnl
475 in_port=90 actions=load:20->NXM_NX_REG0[[0..7]],load:21->NXM_NX_REG1[[0..7]],load:22->NXM_NX_REG2[[0..7]], load:33->NXM_NX_REG3[[0..7]], push:NXM_NX_REG0[[]], push:NXM_NX_REG1[[0..7]],push:NXM_NX_REG2[[0..15]], push:NXM_NX_REG3[[]], resubmit:2, resubmit:3, resubmit:4, resubmit:5
476 in_port=2 actions=pop:NXM_NX_REG0[[0..7]],output:NXM_NX_REG0[[]]
477 in_port=3 actions=pop:NXM_NX_REG1[[0..7]],output:NXM_NX_REG1[[]]
478 in_port=4 actions=pop:NXM_NX_REG2[[0..15]],output:NXM_NX_REG2[[]]
479 in_port=5 actions=pop:NXM_NX_REG3[[]],output:NXM_NX_REG3[[]]
482 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
483 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy 'in_port(90),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)'], [0], [stdout])
484 AT_CHECK([tail -1 stdout], [0],
485 [Datapath actions: 33,22,21,20
490 AT_SETUP([ofproto-dpif - output])
492 ADD_OF_PORTS([br0], [1], [9], [10], [11], [55], [66], [77], [88])
493 AT_DATA([flows.txt], [dnl
494 in_port=1 actions=resubmit:2,resubmit:3,resubmit:4,resubmit:5,resubmit:6,resubmit:7,resubmit:8
495 in_port=2 actions=output:9
496 in_port=3 actions=load:55->NXM_NX_REG0[[]],output:NXM_NX_REG0[[]],load:66->NXM_NX_REG1[[]]
497 in_port=4 actions=output:10,output:NXM_NX_REG0[[]],output:NXM_NX_REG1[[]],output:11
498 in_port=5 actions=load:77->NXM_NX_REG0[[0..15]],load:88->NXM_NX_REG0[[16..31]]
499 in_port=6 actions=output:NXM_NX_REG0[[0..15]],output:NXM_NX_REG0[[16..31]]
500 in_port=7 actions=load:0x110000ff->NXM_NX_REG0[[]],output:NXM_NX_REG0[[]]
501 in_port=8 actions=1,9,load:9->NXM_OF_IN_PORT[[]],1,9
503 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
504 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)'], [0], [stdout])
505 AT_CHECK([tail -1 stdout], [0],
506 [Datapath actions: 9,55,10,55,66,11,77,88,9,1
511 AT_SETUP([ofproto-dpif - dec_ttl])
513 ADD_OF_PORTS([br0], [1], [2], [3], [4])
514 AT_DATA([flows.txt], [dnl
515 table=0 in_port=1 action=dec_ttl,output:2,resubmit(1,1),output:4
516 table=1 in_port=1 action=dec_ttl,output:3
518 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
519 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=111,tos=0,ttl=2,frag=no)' -generate], [0], [stdout])
520 AT_CHECK([tail -4 stdout], [0],
521 [Megaflow: recirc_id=0,ip,in_port=1,nw_ttl=2,nw_frag=no
522 Datapath actions: set(ipv4(ttl=1)),2,4
523 This flow is handled by the userspace slow path because it:
524 - Sends "packet-in" messages to the OpenFlow controller.
526 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=111,tos=0,ttl=3,frag=no)'], [0], [stdout])
527 AT_CHECK([tail -2 stdout], [0],
528 [Megaflow: recirc_id=0,ip,in_port=1,nw_ttl=3,nw_frag=no
529 Datapath actions: set(ipv4(ttl=2)),2,set(ipv4(ttl=1)),3,4
531 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x86dd),ipv6(src=::1,dst=::2,label=0,proto=10,tclass=0x70,hlimit=128,frag=no)'], [0], [stdout])
532 AT_CHECK([tail -2 stdout], [0],
533 [Megaflow: recirc_id=0,ipv6,in_port=1,nw_ttl=128,nw_frag=no
534 Datapath actions: set(ipv6(hlimit=127)),2,set(ipv6(hlimit=126)),3,4
537 AT_CAPTURE_FILE([ofctl_monitor.log])
538 AT_CHECK([ovs-ofctl monitor br0 65534 invalid_ttl --detach --no-chdir --pidfile 2> ofctl_monitor.log])
539 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=111,tos=0,ttl=2,frag=no)' -generate], [0], [stdout])
540 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
541 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
542 NXT_PACKET_IN (xid=0x0): table_id=1 cookie=0x0 total_len=34 in_port=1 (via invalid_ttl) data_len=34 (unbuffered)
543 ip,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=111,nw_tos=0,nw_ecn=0,nw_ttl=1
548 dnl A dec_ttl action at offset 32 in ofpacts will cause the ofpacts
549 dnl buffer to be resized just before pushing the id of the dec_ttl action.
550 dnl Thus the implementation must account for this by using the
551 dnl reallocated buffer rather than the original buffer.
553 dnl A number of similar rules are added to try and exercise
554 dnl xrealloc sufficiently that it returns a different base pointer
555 AT_SETUP([ofproto-dpif - dec_ttl without arguments at offset 32 in ofpacts])
557 ADD_OF_PORTS([br0], [1])
558 (for i in `seq 0 255`; do
559 printf "dl_src=10:11:11:11:11:%02x actions=output:1,output:1,output:1,dec_ttl,controller\n" $i
561 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
565 dnl A dec_ttl action at offset 32 in ofpacts will cause the ofpacts
566 dnl buffer to be resized just before pushing the id of the dec_ttl action.
567 dnl Thus the implementation must account for this by using the
568 dnl reallocated buffer rather than the original buffer.
570 dnl A number of similar rules are added to try and exercise
571 dnl xrealloc sufficiently that it returns a different base pointer
572 AT_SETUP([ofproto-dpif - dec_ttl with arguments at offset 32 in ofpacts])
574 ADD_OF_PORTS([br0], [1])
575 (for i in `seq 0 255`; do
576 printf "dl_src=10:11:11:11:11:%02x actions=output:1,output:1,output:1,dec_ttl(1),controller\n" $i
578 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
582 dnl A note action at offset 24 in ofpacts will cause the ofpacts
583 dnl buffer to be resized just before pushing the id of the dec_ttl action.
584 dnl Thus the implementation must account for this by using the
585 dnl reallocated buffer rather than the original buffer.
587 dnl A number of similar rules are added to try and exercise
588 dnl xrealloc sufficiently that it returns a different base pointer
589 AT_SETUP([ofproto-dpif - note at offset 24 in ofpacts])
591 ADD_OF_PORTS([br0], [1])
592 (for i in `seq 0 255`; do
593 printf "dl_src=10:11:11:11:11:%02x actions=output:1,output:1,note:ff,controller\n" $i
595 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
599 AT_SETUP([ofproto-dpif - output, OFPP_NONE ingress port])
601 ADD_OF_PORTS([br0], [1], [2])
603 AT_CHECK([ovs-ofctl add-flow br0 action=normal])
605 # "in_port" defaults to OFPP_NONE if it's not specified.
606 flow="icmp,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,icmp_type=8,icmp_code=0"
607 AT_CHECK([ovs-appctl ofproto/trace br0 "$flow"], [0], [stdout])
608 AT_CHECK([tail -1 stdout | sed 's/Datapath actions: //' | tr "," "\n" | sort -n], [0], [dnl
617 AT_SETUP([ofproto-dpif - DSCP])
618 OVS_VSWITCHD_START([add-port br0 p1 -- set Interface p1 type=dummy])
619 ADD_OF_PORTS([br0], [9])
620 AT_DATA([flows.txt], [dnl
621 actions=output:LOCAL,enqueue:1:1,enqueue:1:2,enqueue:1:2,enqueue:1:1,output:1,mod_nw_tos:0,output:1,output:LOCAL
623 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
624 AT_CHECK([ovs-vsctl -- \
625 set Port p1 qos=@newqos --\
626 --id=@newqos create QoS type=linux-htb queues=1=@q1,2=@q2 --\
627 --id=@q1 create Queue dscp=1 --\
628 --id=@q2 create Queue dscp=2], [0], [ignore])
629 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy 'in_port(9),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=1.1.1.1,dst=2.2.2.2,proto=1,tos=0xff,ttl=128,frag=no),icmp(type=8,code=0)'], [0], [stdout])
630 AT_CHECK([tail -2 stdout], [0],
631 [Megaflow: recirc_id=0,skb_priority=0,ip,in_port=9,nw_tos=252,nw_frag=no
632 Datapath actions: dnl
634 set(ipv4(tos=0x4/0xfc)),set(skb_priority(0x1)),1,dnl
635 set(ipv4(tos=0x8/0xfc)),set(skb_priority(0x2)),1,dnl
637 set(ipv4(tos=0x4/0xfc)),set(skb_priority(0x1)),1,dnl
638 set(ipv4(tos=0xfc/0xfc)),set(skb_priority(0)),1,dnl
639 set(ipv4(tos=0/0xfc)),1,100
644 AT_SETUP([ofproto-dpif - output/flood flags])
646 ADD_OF_PORTS([br0], [1], [2], [3], [4], [5], [6], [7])
648 AT_DATA([flows.txt], [dnl
649 in_port=local actions=local,flood
650 in_port=1 actions=flood
651 in_port=2 actions=all
652 in_port=3 actions=output:LOCAL,output:1,output:2,output:3,output:4,output:5,output:6,output:7
653 in_port=4 actions=enqueue:LOCAL:1,enqueue:1:1,enqueue:2:1,enqueue:3:2,enqueue:4:1,enqueue:5:1,enqueue:6:1,enqueue:7:1
655 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
656 AT_CHECK([ovs-ofctl mod-port br0 5 noforward])
657 AT_CHECK([ovs-ofctl mod-port br0 6 noflood])
659 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy 'in_port(100),eth(src=00:00:00:00:00:01,dst=00:00:00:00:00:02),eth_type(0x0900)'], [0], [stdout])
660 AT_CHECK([tail -1 stdout \
661 | sed -e 's/Datapath actions: //' | tr ',' '\n' | sort], [0], [dnl
669 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy 'in_port(1),eth(src=00:00:00:00:00:01,dst=00:00:00:00:00:02),eth_type(0x0900)'], [0], [stdout])
670 AT_CHECK([tail -1 stdout \
671 | sed -e 's/Datapath actions: //' | tr ',' '\n' | sort], [0], [dnl
679 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy 'in_port(2),eth(src=00:00:00:00:00:01,dst=00:00:00:00:00:02),eth_type(0x0900)'], [0], [stdout])
680 AT_CHECK([tail -1 stdout \
681 | sed -e 's/Datapath actions: //' | tr ',' '\n' | sort], [0], [dnl
690 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy 'in_port(3),eth(src=00:00:00:00:00:01,dst=00:00:00:00:00:02),eth_type(0x0900)'], [0], [stdout])
691 AT_CHECK([tail -1 stdout], [0],
692 [Datapath actions: 100,1,2,4,6,7
695 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy 'in_port(4),eth(src=00:00:00:00:00:01,dst=00:00:00:00:00:02),eth_type(0x0900)'], [0], [stdout])
696 AT_CHECK([tail -1 stdout], [0],
697 [Datapath actions: set(skb_priority(0x1)),100,1,2,set(skb_priority(0x2)),3,set(skb_priority(0x1)),6,7
702 AT_SETUP([ofproto-dpif - Default Table Miss - OF1.0 (OFPTC_TABLE_MISS_CONTROLLER)])
703 OVS_VSWITCHD_START([dnl
704 add-port br0 p1 -- set Interface p1 type=dummy
706 ON_EXIT([kill `cat ovs-ofctl.pid`])
708 AT_CAPTURE_FILE([ofctl_monitor.log])
710 AT_CHECK([ovs-ofctl monitor br0 65534 --detach --no-chdir --pidfile 2> ofctl_monitor.log])
713 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=9),tcp_flags(syn)'
715 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
716 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
717 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
718 NXT_PACKET_IN (xid=0x0): cookie=0x0 total_len=60 in_port=1 (via no_match) data_len=60 (unbuffered)
719 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=syn tcp_csum:0
721 NXT_PACKET_IN (xid=0x0): cookie=0x0 total_len=60 in_port=1 (via no_match) data_len=60 (unbuffered)
722 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=syn tcp_csum:0
724 NXT_PACKET_IN (xid=0x0): cookie=0x0 total_len=60 in_port=1 (via no_match) data_len=60 (unbuffered)
725 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=syn tcp_csum:0
728 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
729 AT_CHECK([ovs-ofctl dump-flows br0 | ofctl_strip | sort], [0], [dnl
736 AT_SETUP([ofproto-dpif - Default Table Miss - OF1.3 (OFPTC_TABLE_MISS_DROP)])
737 OVS_VSWITCHD_START([dnl
738 add-port br0 p1 -- set Interface p1 type=dummy
740 ON_EXIT([kill `cat ovs-ofctl.pid`])
742 AT_CAPTURE_FILE([ofctl_monitor.log])
743 AT_CHECK([ovs-ofctl del-flows br0])
745 AT_CHECK([ovs-ofctl monitor -OOpenFlow13 -P openflow10 br0 65534 --detach --no-chdir --pidfile 2> ofctl_monitor.log])
747 dnl Test that missed packets are droped
749 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=9),tcp_flags(ack,syn)'
751 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
753 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
756 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
757 AT_CHECK([ovs-ofctl -OOpenFlow13 dump-flows br0 | ofctl_strip | sort], [0], [dnl
758 OFPST_FLOW reply (OF1.3):
764 AT_SETUP([ofproto-dpif - Table Miss - goto table and OFPTC_TABLE_MISS_CONTROLLER])
765 OVS_VSWITCHD_START([dnl
766 add-port br0 p1 -- set Interface p1 type=dummy
768 ON_EXIT([kill `cat ovs-ofctl.pid`])
770 AT_CAPTURE_FILE([ofctl_monitor.log])
771 AT_CHECK([ovs-ofctl -OOpenFlow12 add-flow br0 'table=0 actions=goto_table(1)'])
773 AT_CHECK([ovs-ofctl monitor -P openflow10 br0 65534 --detach --no-chdir --pidfile 2> ofctl_monitor.log])
776 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=9),tcp_flags(urg,rst)'
778 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
779 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
780 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
781 OFPT_PACKET_IN (xid=0x0): total_len=60 in_port=1 (via no_match) data_len=60 (unbuffered)
782 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=rst|urg tcp_csum:0
784 OFPT_PACKET_IN (xid=0x0): total_len=60 in_port=1 (via no_match) data_len=60 (unbuffered)
785 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=rst|urg tcp_csum:0
787 OFPT_PACKET_IN (xid=0x0): total_len=60 in_port=1 (via no_match) data_len=60 (unbuffered)
788 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=rst|urg tcp_csum:0
791 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
792 ovs-appctl revalidator/wait
793 AT_CHECK([ovs-ofctl -OOpenFlow12 dump-flows br0 | ofctl_strip | sort], [0], [dnl
794 n_packets=3, n_bytes=180, actions=goto_table:1
795 OFPST_FLOW reply (OF1.2):
801 AT_SETUP([ofproto-dpif - Table Miss - resubmit and OFPTC_TABLE_MISS_CONTROLLER])
802 OVS_VSWITCHD_START([dnl
803 add-port br0 p1 -- set Interface p1 type=dummy
805 ON_EXIT([kill `cat ovs-ofctl.pid`])
807 AT_CAPTURE_FILE([ofctl_monitor.log])
808 AT_CHECK([ovs-ofctl -OOpenFlow12 add-flow br0 'table=0 actions=resubmit(1,1)'])
810 AT_CHECK([ovs-ofctl monitor -P openflow10 br0 65534 --detach --no-chdir --pidfile 2> ofctl_monitor.log])
813 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=9),tcp_flags(0x010)'
816 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
817 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
820 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
821 ovs-appctl revalidator/wait
822 AT_CHECK([ovs-ofctl -OOpenFlow12 dump-flows br0 | ofctl_strip | sort], [0], [dnl
823 n_packets=3, n_bytes=180, actions=resubmit(1,1)
824 OFPST_FLOW reply (OF1.2):
830 AT_SETUP([ofproto-dpif - Table Miss - OFPTC_TABLE_MISS_CONTINUE])
831 OVS_VSWITCHD_START([dnl
832 add-port br0 p1 -- set Interface p1 type=dummy
834 ON_EXIT([kill `cat ovs-ofctl.pid`])
836 AT_CAPTURE_FILE([ofctl_monitor.log])
837 AT_CHECK([ovs-ofctl add-flow br0 'table=1 dl_src=10:11:11:11:11:11 actions=controller'])
838 AT_CHECK([ovs-ofctl -OOpenFlow11 mod-table br0 all continue])
840 dnl Miss table 0, Hit table 1
841 AT_CHECK([ovs-ofctl monitor br0 65534 --detach --no-chdir --pidfile 2> ofctl_monitor.log])
844 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=10:11:11:11:11:11,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=9),tcp_flags(0x010)'
846 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
847 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
849 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
850 NXT_PACKET_IN (xid=0x0): table_id=1 cookie=0x0 total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
851 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=10:11:11:11:11:11,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=ack tcp_csum:0
853 NXT_PACKET_IN (xid=0x0): table_id=1 cookie=0x0 total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
854 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=10:11:11:11:11:11,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=ack tcp_csum:0
856 NXT_PACKET_IN (xid=0x0): table_id=1 cookie=0x0 total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
857 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=10:11:11:11:11:11,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=ack tcp_csum:0
860 dnl Hit table 0, Miss all other tables, sent to controller
861 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --no-chdir --pidfile 2> ofctl_monitor.log])
864 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=9),tcp_flags(0x010)'
866 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
867 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
869 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
870 NXT_PACKET_IN (xid=0x0): table_id=253 cookie=0x0 total_len=60 in_port=1 (via no_match) data_len=60 (unbuffered)
871 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=ack tcp_csum:0
873 NXT_PACKET_IN (xid=0x0): table_id=253 cookie=0x0 total_len=60 in_port=1 (via no_match) data_len=60 (unbuffered)
874 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=ack tcp_csum:0
876 NXT_PACKET_IN (xid=0x0): table_id=253 cookie=0x0 total_len=60 in_port=1 (via no_match) data_len=60 (unbuffered)
877 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=ack tcp_csum:0
880 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
881 ovs-appctl revalidator/wait
882 AT_CHECK([ovs-ofctl -OOpenFlow12 dump-flows br0 | ofctl_strip | sort], [0], [dnl
883 table=1, n_packets=3, n_bytes=180, dl_src=10:11:11:11:11:11 actions=CONTROLLER:65535
884 OFPST_FLOW reply (OF1.2):
890 AT_SETUP([ofproto-dpif - Table Miss - goto table and OFPTC_TABLE_MISS_CONTINUE])
891 OVS_VSWITCHD_START([dnl
892 add-port br0 p1 -- set Interface p1 type=dummy
894 ON_EXIT([kill `cat ovs-ofctl.pid`])
896 AT_CAPTURE_FILE([ofctl_monitor.log])
897 AT_DATA([flows.txt], [dnl
898 table=0 actions=goto_table(1)
899 table=2 dl_src=10:11:11:11:11:11 actions=controller
901 AT_CHECK([ovs-ofctl -OOpenFlow12 add-flows br0 flows.txt])
902 AT_CHECK([ovs-ofctl -OOpenFlow11 mod-table br0 all continue])
904 dnl Hit table 0, Miss table 1, Hit table 2
905 AT_CHECK([ovs-ofctl monitor br0 65534 --detach --no-chdir --pidfile 2> ofctl_monitor.log])
908 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=10:11:11:11:11:11,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=9),tcp_flags(0x010)'
910 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
911 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
913 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
914 NXT_PACKET_IN (xid=0x0): table_id=2 cookie=0x0 total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
915 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=10:11:11:11:11:11,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=ack tcp_csum:0
917 NXT_PACKET_IN (xid=0x0): table_id=2 cookie=0x0 total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
918 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=10:11:11:11:11:11,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=ack tcp_csum:0
920 NXT_PACKET_IN (xid=0x0): table_id=2 cookie=0x0 total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
921 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=10:11:11:11:11:11,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=ack tcp_csum:0
924 dnl Hit table 1, Miss all other tables, sent to controller
925 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --no-chdir --pidfile 2> ofctl_monitor.log])
928 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=9),tcp_flags(0x010)'
930 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
931 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
933 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
934 NXT_PACKET_IN (xid=0x0): table_id=253 cookie=0x0 total_len=60 in_port=1 (via no_match) data_len=60 (unbuffered)
935 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=ack tcp_csum:0
937 NXT_PACKET_IN (xid=0x0): table_id=253 cookie=0x0 total_len=60 in_port=1 (via no_match) data_len=60 (unbuffered)
938 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=ack tcp_csum:0
940 NXT_PACKET_IN (xid=0x0): table_id=253 cookie=0x0 total_len=60 in_port=1 (via no_match) data_len=60 (unbuffered)
941 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=ack tcp_csum:0
944 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
945 ovs-appctl revalidator/wait
946 AT_CHECK([ovs-ofctl -OOpenFlow12 dump-flows br0 | ofctl_strip | sort], [0], [dnl
947 n_packets=6, n_bytes=360, actions=goto_table:1
948 table=2, n_packets=3, n_bytes=180, dl_src=10:11:11:11:11:11 actions=CONTROLLER:65535
949 OFPST_FLOW reply (OF1.2):
955 AT_SETUP([ofproto-dpif - Table Miss - resubmit and OFPTC_TABLE_MISS_CONTINUE])
956 OVS_VSWITCHD_START([dnl
957 add-port br0 p1 -- set Interface p1 type=dummy
959 ON_EXIT([kill `cat ovs-ofctl.pid`])
961 AT_CAPTURE_FILE([ofctl_monitor.log])
962 AT_DATA([flows.txt], [dnl
963 table=0 actions=resubmit(1,1)
964 table=2 dl_src=10:11:11:11:11:11 actions=controller
966 AT_CHECK([ovs-ofctl -OOpenFlow12 add-flows br0 flows.txt])
967 AT_CHECK([ovs-ofctl -OOpenFlow11 mod-table br0 all continue])
969 dnl Hit table 0, Miss table 1, Dropped
970 AT_CHECK([ovs-ofctl monitor br0 65534 --detach --no-chdir --pidfile 2> ofctl_monitor.log])
973 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=10:11:11:11:11:11,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=9),tcp_flags(0x010)'
975 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
977 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
980 dnl Hit table 1, Dropped
981 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --no-chdir --pidfile 2> ofctl_monitor.log])
984 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=9),tcp_flags(0x010)'
986 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
988 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
991 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
992 ovs-appctl revalidator/wait
993 AT_CHECK([ovs-ofctl -OOpenFlow12 dump-flows br0 | ofctl_strip | sort], [0], [dnl
994 n_packets=6, n_bytes=360, actions=resubmit(1,1)
995 table=2, dl_src=10:11:11:11:11:11 actions=CONTROLLER:65535
996 OFPST_FLOW reply (OF1.2):
1002 AT_SETUP([ofproto-dpif - Table Miss - OFPTC_TABLE_MISS_DROP])
1003 OVS_VSWITCHD_START([dnl
1004 add-port br0 p1 -- set Interface p1 type=dummy
1006 ON_EXIT([kill `cat ovs-ofctl.pid`])
1008 AT_CAPTURE_FILE([ofctl_monitor.log])
1009 AT_CHECK([ovs-ofctl -OOpenFlow11 mod-table br0 all drop])
1011 AT_CHECK([ovs-ofctl monitor -P openflow10 br0 65534 --detach --no-chdir --pidfile 2> ofctl_monitor.log])
1013 dnl Test that missed packets are droped
1015 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=9),tcp_flags(0x010)'
1017 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
1019 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1022 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1023 AT_CHECK([ovs-ofctl dump-flows br0 | ofctl_strip | sort], [0], [dnl
1030 AT_SETUP([ofproto-dpif - Table Miss - goto table and OFPTC_TABLE_MISS_DROP])
1031 OVS_VSWITCHD_START([dnl
1032 add-port br0 p1 -- set Interface p1 type=dummy
1034 ON_EXIT([kill `cat ovs-ofctl.pid`])
1036 AT_CAPTURE_FILE([ofctl_monitor.log])
1037 AT_CHECK([ovs-ofctl del-flows br0])
1038 AT_CHECK([ovs-ofctl -OOpenFlow12 add-flow br0 'table=0 actions=goto_table(1)'])
1039 AT_CHECK([ovs-ofctl -OOpenFlow11 mod-table br0 all drop])
1041 AT_CHECK([ovs-ofctl monitor -P openflow10 br0 65534 --detach --no-chdir --pidfile 2> ofctl_monitor.log])
1043 dnl Test that missed packets are droped
1045 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=9),tcp_flags(0x010)'
1047 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
1049 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1052 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1053 ovs-appctl revalidator/wait
1054 AT_CHECK([ovs-ofctl -OOpenFlow12 dump-flows br0 | ofctl_strip | sort], [0], [dnl
1055 n_packets=3, n_bytes=180, actions=goto_table:1
1056 OFPST_FLOW reply (OF1.2):
1062 AT_SETUP([ofproto-dpif - Table Miss - resubmit and OFPTC_TABLE_MISS_DROP])
1063 OVS_VSWITCHD_START([dnl
1064 add-port br0 p1 -- set Interface p1 type=dummy
1066 ON_EXIT([kill `cat ovs-ofctl.pid`])
1068 AT_CAPTURE_FILE([ofctl_monitor.log])
1069 AT_CHECK([ovs-ofctl del-flows br0])
1070 AT_CHECK([ovs-ofctl -OOpenFlow12 add-flow br0 'table=0 actions=resubmit(1,1)'])
1071 AT_CHECK([ovs-ofctl -OOpenFlow11 mod-table br0 all drop])
1073 AT_CHECK([ovs-ofctl monitor -P openflow10 br0 65534 --detach --no-chdir --pidfile 2> ofctl_monitor.log])
1075 dnl Test that missed packets are droped
1077 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=9),tcp_flags(0x010)'
1079 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
1081 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1084 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1085 ovs-appctl revalidator/wait
1086 AT_CHECK([ovs-ofctl -OOpenFlow12 dump-flows br0 | ofctl_strip | sort], [0], [dnl
1087 n_packets=3, n_bytes=180, actions=resubmit(1,1)
1088 OFPST_FLOW reply (OF1.2):
1094 AT_SETUP([ofproto-dpif - controller])
1095 OVS_VSWITCHD_START([dnl
1096 add-port br0 p1 -- set Interface p1 type=dummy
1098 ON_EXIT([kill `cat ovs-ofctl.pid`])
1100 AT_CAPTURE_FILE([ofctl_monitor.log])
1101 AT_DATA([flows.txt], [dnl
1102 cookie=0x0 dl_src=10:11:11:11:11:11 actions=controller
1103 cookie=0x1 dl_src=20:22:22:22:22:22 actions=controller,resubmit(80,1)
1104 cookie=0x2 dl_src=30:33:33:33:33:33 actions=mod_vlan_vid:15,controller
1106 cookie=0x3 table=1 in_port=80 actions=load:1->NXM_NX_REG0[[]],mod_vlan_vid:80,controller,resubmit(81,2)
1107 cookie=0x4 table=2 in_port=81 actions=load:2->NXM_NX_REG1[[]],mod_dl_src:80:81:81:81:81:81,controller,resubmit(82,3)
1108 cookie=0x5 table=3 in_port=82 actions=load:3->NXM_NX_REG2[[]],mod_dl_dst:82:82:82:82:82:82,controller,resubmit(83,4)
1109 cookie=0x6 table=4 in_port=83 actions=load:4->NXM_NX_REG3[[]],mod_nw_src:83.83.83.83,controller,resubmit(84,5)
1110 cookie=0x7 table=5 in_port=84 actions=load:5->NXM_NX_REG4[[]],load:6->NXM_NX_TUN_ID[[]],mod_nw_dst:84.84.84.84,controller,resubmit(85,6)
1111 cookie=0x8 table=6 in_port=85 actions=mod_tp_src:85,controller,resubmit(86,7)
1112 cookie=0x9 table=7 in_port=86 actions=mod_tp_dst:86,controller,controller
1113 cookie=0xa dl_src=40:44:44:44:44:41 actions=mod_vlan_vid:99,mod_vlan_pcp:1,controller
1114 cookie=0xd dl_src=80:88:88:88:88:88 arp actions=load:2->OXM_OF_ARP_OP[[]],controller,load:0xc0a88001->OXM_OF_ARP_SPA[[]],controller,load:0x404444444441->OXM_OF_ARP_THA[[]],load:0x01010101->OXM_OF_ARP_SPA[[]],load:0x02020202->OXM_OF_ARP_TPA[[]],controller
1116 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
1119 AT_CHECK([ovs-ofctl monitor -P openflow10 br0 65534 --detach --no-chdir --pidfile 2> ofctl_monitor.log])
1122 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=9),tcp_flags(0x010)'
1124 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1125 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1127 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1128 OFPT_PACKET_IN (xid=0x0): total_len=60 in_port=1 (via no_match) data_len=60 (unbuffered)
1129 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=ack tcp_csum:0
1131 OFPT_PACKET_IN (xid=0x0): total_len=60 in_port=1 (via no_match) data_len=60 (unbuffered)
1132 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=ack tcp_csum:0
1134 OFPT_PACKET_IN (xid=0x0): total_len=60 in_port=1 (via no_match) data_len=60 (unbuffered)
1135 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=9,tcp_flags=ack tcp_csum:0
1138 dnl Singleton controller action.
1139 AT_CHECK([ovs-ofctl monitor -P openflow10 br0 65534 --detach --no-chdir --pidfile 2> ofctl_monitor.log])
1142 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=10:11:11:11:11:11,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=10),tcp_flags(0x002)'
1144 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1145 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1147 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1148 OFPT_PACKET_IN (xid=0x0): total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1149 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=10:11:11:11:11:11,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=10,tcp_flags=syn tcp_csum:0
1151 OFPT_PACKET_IN (xid=0x0): total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1152 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=10:11:11:11:11:11,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=10,tcp_flags=syn tcp_csum:0
1154 OFPT_PACKET_IN (xid=0x0): total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1155 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=10:11:11:11:11:11,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=10,tcp_flags=syn tcp_csum:0
1158 dnl Modified controller action.
1159 AT_CHECK([ovs-ofctl monitor -P openflow10 br0 65534 --detach --no-chdir --pidfile 2> ofctl_monitor.log])
1162 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=30:33:33:33:33:33,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=10),tcp_flags(0x001)'
1164 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1165 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1167 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1168 OFPT_PACKET_IN (xid=0x0): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1169 tcp,metadata=0,in_port=0,dl_vlan=15,dl_vlan_pcp=0,dl_src=30:33:33:33:33:33,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=10,tcp_flags=fin tcp_csum:0
1171 OFPT_PACKET_IN (xid=0x0): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1172 tcp,metadata=0,in_port=0,dl_vlan=15,dl_vlan_pcp=0,dl_src=30:33:33:33:33:33,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=10,tcp_flags=fin tcp_csum:0
1174 OFPT_PACKET_IN (xid=0x0): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1175 tcp,metadata=0,in_port=0,dl_vlan=15,dl_vlan_pcp=0,dl_src=30:33:33:33:33:33,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=10,tcp_flags=fin tcp_csum:0
1178 dnl Modified VLAN controller action.
1179 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1182 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:44:41,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=16,tos=0,ttl=64,frag=no)'
1184 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1185 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1187 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1188 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1189 ip,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:44:41,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=16,nw_tos=0,nw_ecn=0,nw_ttl=64
1191 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1192 ip,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:44:41,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=16,nw_tos=0,nw_ecn=0,nw_ttl=64
1194 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1195 ip,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:44:41,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=16,nw_tos=0,nw_ecn=0,nw_ttl=64
1199 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --no-chdir --pidfile 2> ofctl_monitor.log])
1202 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=20:22:22:22:22:22,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=11),tcp_flags(0x001)'
1204 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 18])
1205 ovs-appctl -t ovs-ofctl exit
1207 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1208 NXT_PACKET_IN (xid=0x0): cookie=0x1 total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1209 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=20:22:22:22:22:22,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=11,tcp_flags=fin tcp_csum:0
1211 NXT_PACKET_IN (xid=0x0): table_id=1 cookie=0x3 total_len=64 in_port=1 reg0=0x1 (via action) data_len=64 (unbuffered)
1212 tcp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=20:22:22:22:22:22,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=11,tcp_flags=fin tcp_csum:0
1214 NXT_PACKET_IN (xid=0x0): table_id=2 cookie=0x4 total_len=64 in_port=1 reg0=0x1 reg1=0x2 (via action) data_len=64 (unbuffered)
1215 tcp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=11,tcp_flags=fin tcp_csum:0
1217 NXT_PACKET_IN (xid=0x0): table_id=3 cookie=0x5 total_len=64 in_port=1 reg0=0x1 reg1=0x2 reg2=0x3 (via action) data_len=64 (unbuffered)
1218 tcp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=82:82:82:82:82:82,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=11,tcp_flags=fin tcp_csum:0
1220 NXT_PACKET_IN (xid=0x0): table_id=4 cookie=0x6 total_len=64 in_port=1 reg0=0x1 reg1=0x2 reg2=0x3 reg3=0x4 (via action) data_len=64 (unbuffered)
1221 tcp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=82:82:82:82:82:82,nw_src=83.83.83.83,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=11,tcp_flags=fin tcp_csum:1a03
1223 NXT_PACKET_IN (xid=0x0): table_id=5 cookie=0x7 total_len=64 in_port=1 tun_id=0x6 reg0=0x1 reg1=0x2 reg2=0x3 reg3=0x4 reg4=0x5 (via action) data_len=64 (unbuffered)
1224 tcp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=82:82:82:82:82:82,nw_src=83.83.83.83,nw_dst=84.84.84.84,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=11,tcp_flags=fin tcp_csum:3205
1226 NXT_PACKET_IN (xid=0x0): table_id=6 cookie=0x8 total_len=64 in_port=1 tun_id=0x6 reg0=0x1 reg1=0x2 reg2=0x3 reg3=0x4 reg4=0x5 (via action) data_len=64 (unbuffered)
1227 tcp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=82:82:82:82:82:82,nw_src=83.83.83.83,nw_dst=84.84.84.84,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=85,tp_dst=11,tcp_flags=fin tcp_csum:31b8
1229 NXT_PACKET_IN (xid=0x0): table_id=7 cookie=0x9 total_len=64 in_port=1 tun_id=0x6 reg0=0x1 reg1=0x2 reg2=0x3 reg3=0x4 reg4=0x5 (via action) data_len=64 (unbuffered)
1230 tcp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=82:82:82:82:82:82,nw_src=83.83.83.83,nw_dst=84.84.84.84,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=85,tp_dst=86,tcp_flags=fin tcp_csum:316d
1232 NXT_PACKET_IN (xid=0x0): table_id=7 cookie=0x9 total_len=64 in_port=1 tun_id=0x6 reg0=0x1 reg1=0x2 reg2=0x3 reg3=0x4 reg4=0x5 (via action) data_len=64 (unbuffered)
1233 tcp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=82:82:82:82:82:82,nw_src=83.83.83.83,nw_dst=84.84.84.84,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=85,tp_dst=86,tcp_flags=fin tcp_csum:316d
1237 AT_CHECK([ovs-ofctl monitor br0 65534 --detach --no-chdir --pidfile 2> ofctl_monitor.log])
1240 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 20 22 22 22 22 22 08 00 45 00 00 1C 00 00 00 00 00 11 00 00 C0 A8 00 01 C0 A8 00 02 00 08 00 0B 00 00 12 34 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00'
1242 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 18])
1243 ovs-appctl -t ovs-ofctl exit
1245 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1246 NXT_PACKET_IN (xid=0x0): cookie=0x1 total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1247 udp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=20:22:22:22:22:22,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=0,tp_src=8,tp_dst=11 udp_csum:1234
1249 NXT_PACKET_IN (xid=0x0): table_id=1 cookie=0x3 total_len=64 in_port=1 reg0=0x1 (via action) data_len=64 (unbuffered)
1250 udp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=20:22:22:22:22:22,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=0,tp_src=8,tp_dst=11 udp_csum:1234
1252 NXT_PACKET_IN (xid=0x0): table_id=2 cookie=0x4 total_len=64 in_port=1 reg0=0x1 reg1=0x2 (via action) data_len=64 (unbuffered)
1253 udp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=0,tp_src=8,tp_dst=11 udp_csum:1234
1255 NXT_PACKET_IN (xid=0x0): table_id=3 cookie=0x5 total_len=64 in_port=1 reg0=0x1 reg1=0x2 reg2=0x3 (via action) data_len=64 (unbuffered)
1256 udp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=82:82:82:82:82:82,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=0,tp_src=8,tp_dst=11 udp_csum:1234
1258 NXT_PACKET_IN (xid=0x0): table_id=4 cookie=0x6 total_len=64 in_port=1 reg0=0x1 reg1=0x2 reg2=0x3 reg3=0x4 (via action) data_len=64 (unbuffered)
1259 udp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=82:82:82:82:82:82,nw_src=83.83.83.83,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=0,tp_src=8,tp_dst=11 udp_csum:2c37
1261 NXT_PACKET_IN (xid=0x0): table_id=5 cookie=0x7 total_len=64 in_port=1 tun_id=0x6 reg0=0x1 reg1=0x2 reg2=0x3 reg3=0x4 reg4=0x5 (via action) data_len=64 (unbuffered)
1262 udp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=82:82:82:82:82:82,nw_src=83.83.83.83,nw_dst=84.84.84.84,nw_tos=0,nw_ecn=0,nw_ttl=0,tp_src=8,tp_dst=11 udp_csum:4439
1264 NXT_PACKET_IN (xid=0x0): table_id=6 cookie=0x8 total_len=64 in_port=1 tun_id=0x6 reg0=0x1 reg1=0x2 reg2=0x3 reg3=0x4 reg4=0x5 (via action) data_len=64 (unbuffered)
1265 udp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=82:82:82:82:82:82,nw_src=83.83.83.83,nw_dst=84.84.84.84,nw_tos=0,nw_ecn=0,nw_ttl=0,tp_src=85,tp_dst=11 udp_csum:43ec
1267 NXT_PACKET_IN (xid=0x0): table_id=7 cookie=0x9 total_len=64 in_port=1 tun_id=0x6 reg0=0x1 reg1=0x2 reg2=0x3 reg3=0x4 reg4=0x5 (via action) data_len=64 (unbuffered)
1268 udp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=82:82:82:82:82:82,nw_src=83.83.83.83,nw_dst=84.84.84.84,nw_tos=0,nw_ecn=0,nw_ttl=0,tp_src=85,tp_dst=86 udp_csum:43a1
1270 NXT_PACKET_IN (xid=0x0): table_id=7 cookie=0x9 total_len=64 in_port=1 tun_id=0x6 reg0=0x1 reg1=0x2 reg2=0x3 reg3=0x4 reg4=0x5 (via action) data_len=64 (unbuffered)
1271 udp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=82:82:82:82:82:82,nw_src=83.83.83.83,nw_dst=84.84.84.84,nw_tos=0,nw_ecn=0,nw_ttl=0,tp_src=85,tp_dst=86 udp_csum:43a1
1274 dnl Modified ARP controller action.
1275 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1278 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=80:88:88:88:88:88,dst=ff:ff:ff:ff:ff:ff),eth_type(0x0806),arp(sip=192.168.0.1,tip=192.168.0.2,op=1,sha=50:54:00:00:00:05,tha=00:00:00:00:00:00)'
1281 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 18])
1282 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
1283 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1284 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1285 arp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=80:88:88:88:88:88,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=192.168.0.1,arp_tpa=192.168.0.2,arp_op=2,arp_sha=50:54:00:00:00:05,arp_tha=00:00:00:00:00:00
1286 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1287 arp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=80:88:88:88:88:88,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=192.168.128.1,arp_tpa=192.168.0.2,arp_op=2,arp_sha=50:54:00:00:00:05,arp_tha=00:00:00:00:00:00
1288 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1289 arp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=80:88:88:88:88:88,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=1.1.1.1,arp_tpa=2.2.2.2,arp_op=2,arp_sha=50:54:00:00:00:05,arp_tha=40:44:44:44:44:41
1290 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1291 arp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=80:88:88:88:88:88,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=192.168.0.1,arp_tpa=192.168.0.2,arp_op=2,arp_sha=50:54:00:00:00:05,arp_tha=00:00:00:00:00:00
1292 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1293 arp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=80:88:88:88:88:88,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=192.168.128.1,arp_tpa=192.168.0.2,arp_op=2,arp_sha=50:54:00:00:00:05,arp_tha=00:00:00:00:00:00
1294 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1295 arp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=80:88:88:88:88:88,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=1.1.1.1,arp_tpa=2.2.2.2,arp_op=2,arp_sha=50:54:00:00:00:05,arp_tha=40:44:44:44:44:41
1296 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1297 arp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=80:88:88:88:88:88,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=192.168.0.1,arp_tpa=192.168.0.2,arp_op=2,arp_sha=50:54:00:00:00:05,arp_tha=00:00:00:00:00:00
1298 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1299 arp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=80:88:88:88:88:88,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=192.168.128.1,arp_tpa=192.168.0.2,arp_op=2,arp_sha=50:54:00:00:00:05,arp_tha=00:00:00:00:00:00
1300 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1301 arp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=80:88:88:88:88:88,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=1.1.1.1,arp_tpa=2.2.2.2,arp_op=2,arp_sha=50:54:00:00:00:05,arp_tha=40:44:44:44:44:41
1304 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1307 AT_CHECK([ovs-ofctl monitor br0 65534 --detach --no-chdir --pidfile 2> ofctl_monitor.log])
1310 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 20 22 22 22 22 22 08 00 45 00 00 24 00 00 00 00 00 84 00 00 C0 A8 00 01 C0 A8 00 02 04 58 08 af 00 00 00 00 d9 d7 91 57 01 00 00 34 cf 28 ec 4e 00 01 40 00 00 0a ff ff b7 53 24 19 00 05 00 08 7f 00 00 01 00 05 00 08 c0 a8 02 07 00 0c 00 06 00 05 00 00 80 00 00 04 c0 00 00 04'
1313 AT_CHECK([ovs-appctl time/warp 1000], [0], [ignore])
1314 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 18])
1315 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
1316 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1317 NXT_PACKET_IN (xid=0x0): cookie=0x1 total_len=98 in_port=1 (via action) data_len=98 (unbuffered)
1318 sctp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=20:22:22:22:22:22,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=0,tp_src=1112,tp_dst=2223 sctp_csum:d9d79157
1320 NXT_PACKET_IN (xid=0x0): table_id=1 cookie=0x3 total_len=102 in_port=1 reg0=0x1 (via action) data_len=102 (unbuffered)
1321 sctp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=20:22:22:22:22:22,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=0,tp_src=1112,tp_dst=2223 sctp_csum:d9d79157
1323 NXT_PACKET_IN (xid=0x0): table_id=2 cookie=0x4 total_len=102 in_port=1 reg0=0x1 reg1=0x2 (via action) data_len=102 (unbuffered)
1324 sctp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=0,tp_src=1112,tp_dst=2223 sctp_csum:d9d79157
1326 NXT_PACKET_IN (xid=0x0): table_id=3 cookie=0x5 total_len=102 in_port=1 reg0=0x1 reg1=0x2 reg2=0x3 (via action) data_len=102 (unbuffered)
1327 sctp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=82:82:82:82:82:82,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=0,tp_src=1112,tp_dst=2223 sctp_csum:d9d79157
1329 NXT_PACKET_IN (xid=0x0): table_id=4 cookie=0x6 total_len=102 in_port=1 reg0=0x1 reg1=0x2 reg2=0x3 reg3=0x4 (via action) data_len=102 (unbuffered)
1330 sctp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=82:82:82:82:82:82,nw_src=83.83.83.83,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=0,tp_src=1112,tp_dst=2223 sctp_csum:d9d79157
1332 NXT_PACKET_IN (xid=0x0): table_id=5 cookie=0x7 total_len=102 in_port=1 tun_id=0x6 reg0=0x1 reg1=0x2 reg2=0x3 reg3=0x4 reg4=0x5 (via action) data_len=102 (unbuffered)
1333 sctp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=82:82:82:82:82:82,nw_src=83.83.83.83,nw_dst=84.84.84.84,nw_tos=0,nw_ecn=0,nw_ttl=0,tp_src=1112,tp_dst=2223 sctp_csum:d9d79157
1335 NXT_PACKET_IN (xid=0x0): table_id=6 cookie=0x8 total_len=102 in_port=1 tun_id=0x6 reg0=0x1 reg1=0x2 reg2=0x3 reg3=0x4 reg4=0x5 (via action) data_len=102 (unbuffered)
1336 sctp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=82:82:82:82:82:82,nw_src=83.83.83.83,nw_dst=84.84.84.84,nw_tos=0,nw_ecn=0,nw_ttl=0,tp_src=85,tp_dst=2223 sctp_csum:7f12662e
1338 NXT_PACKET_IN (xid=0x0): table_id=7 cookie=0x9 total_len=102 in_port=1 tun_id=0x6 reg0=0x1 reg1=0x2 reg2=0x3 reg3=0x4 reg4=0x5 (via action) data_len=102 (unbuffered)
1339 sctp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=82:82:82:82:82:82,nw_src=83.83.83.83,nw_dst=84.84.84.84,nw_tos=0,nw_ecn=0,nw_ttl=0,tp_src=85,tp_dst=86 sctp_csum:a7e86f67
1341 NXT_PACKET_IN (xid=0x0): table_id=7 cookie=0x9 total_len=102 in_port=1 tun_id=0x6 reg0=0x1 reg1=0x2 reg2=0x3 reg3=0x4 reg4=0x5 (via action) data_len=102 (unbuffered)
1342 sctp,metadata=0,in_port=0,dl_vlan=80,dl_vlan_pcp=0,dl_src=80:81:81:81:81:81,dl_dst=82:82:82:82:82:82,nw_src=83.83.83.83,nw_dst=84.84.84.84,nw_tos=0,nw_ecn=0,nw_ttl=0,tp_src=85,tp_dst=86 sctp_csum:a7e86f67
1345 AT_CHECK([ovs-ofctl dump-flows br0 | ofctl_strip | sort], [0], [dnl
1346 cookie=0x1, n_packets=3, n_bytes=218, dl_src=20:22:22:22:22:22 actions=CONTROLLER:65535,resubmit(80,1)
1347 cookie=0x2, n_packets=3, n_bytes=180, dl_src=30:33:33:33:33:33 actions=mod_vlan_vid:15,CONTROLLER:65535
1348 cookie=0x3, table=1, n_packets=3, n_bytes=218, in_port=80 actions=load:0x1->NXM_NX_REG0[[]],mod_vlan_vid:80,CONTROLLER:65535,resubmit(81,2)
1349 cookie=0x4, table=2, n_packets=3, n_bytes=218, in_port=81 actions=load:0x2->NXM_NX_REG1[[]],mod_dl_src:80:81:81:81:81:81,CONTROLLER:65535,resubmit(82,3)
1350 cookie=0x5, table=3, n_packets=3, n_bytes=218, in_port=82 actions=load:0x3->NXM_NX_REG2[[]],mod_dl_dst:82:82:82:82:82:82,CONTROLLER:65535,resubmit(83,4)
1351 cookie=0x6, table=4, n_packets=3, n_bytes=218, in_port=83 actions=load:0x4->NXM_NX_REG3[[]],mod_nw_src:83.83.83.83,CONTROLLER:65535,resubmit(84,5)
1352 cookie=0x7, table=5, n_packets=3, n_bytes=218, in_port=84 actions=load:0x5->NXM_NX_REG4[[]],load:0x6->NXM_NX_TUN_ID[[]],mod_nw_dst:84.84.84.84,CONTROLLER:65535,resubmit(85,6)
1353 cookie=0x8, table=6, n_packets=3, n_bytes=218, in_port=85 actions=mod_tp_src:85,CONTROLLER:65535,resubmit(86,7)
1354 cookie=0x9, table=7, n_packets=3, n_bytes=218, in_port=86 actions=mod_tp_dst:86,CONTROLLER:65535,CONTROLLER:65535
1355 cookie=0xa, n_packets=3, n_bytes=180, dl_src=40:44:44:44:44:41 actions=mod_vlan_vid:99,mod_vlan_pcp:1,CONTROLLER:65535
1356 cookie=0xd, n_packets=3, n_bytes=180, arp,dl_src=80:88:88:88:88:88 actions=load:0x2->NXM_OF_ARP_OP[[]],CONTROLLER:65535,load:0xc0a88001->NXM_OF_ARP_SPA[[]],CONTROLLER:65535,load:0x404444444441->NXM_NX_ARP_THA[[]],load:0x1010101->NXM_OF_ARP_SPA[[]],load:0x2020202->NXM_OF_ARP_TPA[[]],CONTROLLER:65535
1357 n_packets=3, n_bytes=180, dl_src=10:11:11:11:11:11 actions=CONTROLLER:65535
1364 AT_SETUP([ofproto-dpif - MPLS handling])
1365 OVS_VSWITCHD_START([dnl
1366 add-port br0 p1 -- set Interface p1 type=dummy
1368 ON_EXIT([kill `cat ovs-ofctl.pid`])
1370 AT_CAPTURE_FILE([ofctl_monitor.log])
1371 AT_DATA([flows.txt], [dnl
1372 cookie=0xa dl_src=40:44:44:44:44:42 actions=push_mpls:0x8847,load:10->OXM_OF_MPLS_LABEL[[]],load:3->OXM_OF_MPLS_TC[[]],controller
1373 cookie=0xa dl_src=41:44:44:44:44:42 actions=push_mpls:0x8847,load:10->OXM_OF_MPLS_LABEL[[]],load:3->OXM_OF_MPLS_TC[[]],pop_mpls:0x0800,controller
1374 cookie=0xa dl_src=40:44:44:44:44:43 actions=push_mpls:0x8847,load:10->OXM_OF_MPLS_LABEL[[]],load:3->OXM_OF_MPLS_TC[[]],controller
1375 cookie=0xa dl_src=40:44:44:44:44:44 actions=push_mpls:0x8847,load:10->OXM_OF_MPLS_LABEL[[]],load:3->OXM_OF_MPLS_TC[[]],controller
1376 cookie=0xa dl_src=40:44:44:44:44:45 actions=push_mpls:0x8847,load:10->OXM_OF_MPLS_LABEL[[]],load:3->OXM_OF_MPLS_TC[[]],dec_mpls_ttl,controller
1377 cookie=0xa dl_src=40:44:44:44:44:46 actions=push_mpls:0x8847,load:10->OXM_OF_MPLS_LABEL[[]],load:3->OXM_OF_MPLS_TC[[]],set_mpls_ttl(10),controller
1378 cookie=0xa dl_src=40:44:44:44:44:47 actions=push_mpls:0x8847,load:10->OXM_OF_MPLS_LABEL[[]],load:3->OXM_OF_MPLS_TC[[]],dec_mpls_ttl,set_mpls_ttl(10),controller
1379 cookie=0xa dl_src=40:44:44:44:44:48 actions=push_mpls:0x8847,load:10->OXM_OF_MPLS_LABEL[[]],load:3->OXM_OF_MPLS_TC[[]],set_mpls_ttl(10),dec_mpls_ttl,controller
1380 cookie=0xa mpls,dl_src=40:44:44:44:44:49 actions=push_mpls:0x8848,load:10->OXM_OF_MPLS_LABEL[[]],CONTROLLER:65535
1381 cookie=0xb dl_src=50:55:55:55:55:55 dl_type=0x8847 actions=load:1000->OXM_OF_MPLS_LABEL[[]],controller
1382 cookie=0xd dl_src=60:66:66:66:66:66 actions=pop_mpls:0x0800,controller
1383 cookie=0xc dl_src=70:77:77:77:77:77 actions=push_mpls:0x8848,load:1000->OXM_OF_MPLS_LABEL[[]],load:7->OXM_OF_MPLS_TC[[]],controller
1385 cookie=0xd dl_src=60:66:66:66:00:01 actions=pop_mpls:0x0800,dec_ttl,controller
1386 cookie=0xd dl_src=60:66:66:66:00:02 actions=pop_mpls:0x0800,load:0xa000001->OXM_OF_IPV4_DST[[]],controller
1387 cookie=0xd dl_src=60:66:66:66:00:03 actions=pop_mpls:0x0800,move:OXM_OF_IPV4_DST[[]]->OXM_OF_IPV4_SRC[[]],controller
1388 cookie=0xd dl_src=60:66:66:66:00:04 actions=pop_mpls:0x0800,push:OXM_OF_IPV4_DST[[]],pop:OXM_OF_IPV4_SRC[[]],controller
1389 cookie=0xd dl_src=60:66:66:66:00:05 actions=pop_mpls:0x0800,multipath(eth_src,50,modulo_n,256,0,OXM_OF_IPV4_SRC[[0..7]]),controller
1390 cookie=0xd dl_src=60:66:66:66:00:06 actions=pop_mpls:0x0800,bundle_load(eth_src,50,hrw,ofport,OXM_OF_IPV4_SRC[[0..15]],slaves:1,2),controller
1391 cookie=0xd dl_src=60:66:66:66:00:07 actions=pop_mpls:0x0800,learn(table=1,hard_timeout=60,eth_type=0x800,nw_proto=6,OXM_OF_IPV4_SRC[[]]=OXM_OF_IPV4_DST[[]]),controller
1393 cookie=0xd dl_src=60:66:66:66:00:08 actions=pop_mpls:0x0806,resubmit(1,1)
1394 cookie=0xd table=1 arp actions=controller
1396 cookie=0xd dl_src=60:66:66:66:00:09 actions=pop_mpls:0x0800,mod_nw_tos:48,controller
1397 cookie=0xd dl_src=60:66:66:66:00:0a actions=pop_mpls:0x0800,mod_nw_dst:10.0.0.1,controller
1398 cookie=0xd dl_src=60:66:66:66:00:0b actions=pop_mpls:0x0800,mod_nw_src:10.0.0.1,controller
1400 cookie=0xd dl_src=60:66:66:66:01:00 actions=pop_mpls:0x8848,controller
1401 cookie=0xd dl_src=60:66:66:66:01:01 actions=pop_mpls:0x8847,dec_mpls_ttl,controller
1402 cookie=0xd dl_src=60:66:66:66:01:02 actions=pop_mpls:0x8848,load:3->OXM_OF_MPLS_TC[[]],controller
1404 cookie=0xd dl_src=60:66:66:66:02:00 actions=pop_mpls:0x8847,pop_mpls:0x0800,controller
1405 cookie=0xd dl_src=60:66:66:66:02:01 actions=pop_mpls:0x8848,pop_mpls:0x0800,dec_ttl,controller
1406 cookie=0xd dl_src=60:66:66:66:02:10 actions=pop_mpls:0x8847,dec_mpls_ttl,pop_mpls:0x0800,dec_ttl,controller
1408 cookie=0xd dl_src=60:66:66:66:03:00 actions=pop_mpls:0x8848,pop_mpls:0x8848,controller
1409 cookie=0xd dl_src=60:66:66:66:03:01 actions=pop_mpls:0x8847,pop_mpls:0x8847,dec_mpls_ttl,controller
1410 cookie=0xd dl_src=60:66:66:66:03:10 actions=pop_mpls:0x8848,dec_mpls_ttl,pop_mpls:0x8848,dec_mpls_ttl,controller
1412 cookie=0xd dl_src=60:66:66:66:04:00 actions=pop_mpls:0x0800,push_mpls:0x8847,controller
1413 cookie=0xd dl_src=60:66:66:66:04:01 actions=pop_mpls:0x0800,push_mpls:0x8848,dec_mpls_ttl,controller
1414 cookie=0xd dl_src=60:66:66:66:04:10 actions=pop_mpls:0x0800,dec_ttl,push_mpls:0x8848,dec_mpls_ttl,controller
1416 cookie=0xd dl_src=60:66:66:66:05:00 actions=push_mpls:0x8848,pop_mpls:0x8847,controller
1417 cookie=0xd dl_src=60:66:66:66:05:01 actions=push_mpls:0x8847,pop_mpls:0x8848,dec_mpls_ttl,controller
1418 cookie=0xd dl_src=60:66:66:66:05:10 actions=push_mpls:0x8848,dec_mpls_ttl,pop_mpls:0x8847,dec_mpls_ttl,controller
1420 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
1422 dnl Modified MPLS controller action.
1423 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1426 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:44:42,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=17,tos=0,ttl=64,frag=no),udp(src=7777,dst=80)'
1428 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1429 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1431 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1432 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1433 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:42,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=64,mpls_bos=1
1435 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1436 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:42,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=64,mpls_bos=1
1438 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1439 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:42,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=64,mpls_bos=1
1442 dnl Modified MPLS controller action.
1443 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1446 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=41:44:44:44:44:42,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=16,tos=0,ttl=64,frag=no)'
1448 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1449 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1451 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1452 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1453 ip,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=41:44:44:44:44:42,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=16,nw_tos=0,nw_ecn=0,nw_ttl=64
1455 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1456 ip,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=41:44:44:44:44:42,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=16,nw_tos=0,nw_ecn=0,nw_ttl=64
1458 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1459 ip,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=41:44:44:44:44:42,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=16,nw_tos=0,nw_ecn=0,nw_ttl=64
1462 dnl Modified MPLS controller action.
1463 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1465 dnl in_port(1),eth(src=00:01:02:03:04:05,dst=10:11:12:13:14:15),eth_type(0x8847),mpls(label=100,tc=3,ttl=64,bos=1)
1468 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:44:43,dst=50:54:00:00:00:07),eth_type(0x8847),mpls(label=11,tc=3,ttl=64,bos=1)'
1470 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1471 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1473 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1474 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1475 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:43,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=64,mpls_bos=0,mpls_lse1=46912
1477 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1478 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:43,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=64,mpls_bos=0,mpls_lse1=46912
1480 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1481 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:43,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=64,mpls_bos=0,mpls_lse1=46912
1484 dnl Modified MPLS controller action.
1485 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1488 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:44:44,dst=50:54:00:00:00:07),eth_type(0x8100),vlan(vid=99,pcp=7),encap(eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=16,tos=0,ttl=64,frag=no))'
1490 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1491 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1493 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1494 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1495 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=7,dl_src=40:44:44:44:44:44,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=64,mpls_bos=1
1497 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1498 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=7,dl_src=40:44:44:44:44:44,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=64,mpls_bos=1
1500 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1501 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=7,dl_src=40:44:44:44:44:44,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=64,mpls_bos=1
1504 dnl Modified MPLS controller action.
1505 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1508 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:44:45,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=16,tos=0,ttl=64,frag=no)'
1510 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1511 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1513 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1514 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1515 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:45,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=63,mpls_bos=1
1517 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1518 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:45,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=63,mpls_bos=1
1520 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1521 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:45,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=63,mpls_bos=1
1524 dnl Modified MPLS controller action.
1525 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1528 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:44:46,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=16,tos=0,ttl=64,frag=no)'
1530 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1531 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1533 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1534 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1535 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:46,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=10,mpls_bos=1
1537 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1538 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:46,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=10,mpls_bos=1
1540 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1541 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:46,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=10,mpls_bos=1
1544 dnl Modified MPLS controller action.
1545 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1548 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:44:47,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=16,tos=0,ttl=64,frag=no)'
1550 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1551 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1553 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1554 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1555 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:47,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=10,mpls_bos=1
1557 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1558 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:47,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=10,mpls_bos=1
1560 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1561 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:47,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=10,mpls_bos=1
1564 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1566 dnl Modified MPLS controller action.
1567 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1570 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:44:49,dst=50:54:00:00:00:07),eth_type(0x8847),mpls(label=10,tc=3,ttl=64,bos=1)'
1572 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1573 ovs-appctl -t ovs-ofctl exit
1575 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1576 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1577 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:49,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=64,mpls_bos=0,mpls_lse1=42816
1579 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1580 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:49,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=64,mpls_bos=0,mpls_lse1=42816
1582 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1583 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:49,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=64,mpls_bos=0,mpls_lse1=42816
1586 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1588 dnl Modified MPLS controller action.
1589 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1592 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:44:48,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=16,tos=0,ttl=64,frag=no)'
1594 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1595 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1597 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1598 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1599 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:48,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=9,mpls_bos=1
1601 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1602 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:48,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=9,mpls_bos=1
1604 NXT_PACKET_IN (xid=0x0): cookie=0xa total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1605 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:44:48,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=3,mpls_ttl=9,mpls_bos=1
1608 dnl Modified MPLS actions.
1609 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1612 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:55:55:55:55:55,dst=50:54:00:00:00:07),eth_type(0x8847),mpls(label=100,tc=7,ttl=64,bos=1)'
1614 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1615 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1617 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1618 NXT_PACKET_IN (xid=0x0): cookie=0xb total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1619 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:55:55:55:55:55,dl_dst=50:54:00:00:00:07,mpls_label=1000,mpls_tc=7,mpls_ttl=64,mpls_bos=1
1621 NXT_PACKET_IN (xid=0x0): cookie=0xb total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1622 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:55:55:55:55:55,dl_dst=50:54:00:00:00:07,mpls_label=1000,mpls_tc=7,mpls_ttl=64,mpls_bos=1
1624 NXT_PACKET_IN (xid=0x0): cookie=0xb total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
1625 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:55:55:55:55:55,dl_dst=50:54:00:00:00:07,mpls_label=1000,mpls_tc=7,mpls_ttl=64,mpls_bos=1
1628 dnl Modified MPLS ipv6 controller action.
1629 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1632 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=70:77:77:77:77:77,dst=50:54:00:00:00:07),eth_type(0x86dd),ipv6(src=::1,dst=::2,label=0,proto=10,tclass=0x70,hlimit=128,frag=no)'
1634 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1635 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1637 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1638 NXT_PACKET_IN (xid=0x0): cookie=0xc total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1639 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=70:77:77:77:77:77,dl_dst=50:54:00:00:00:07,mpls_label=1000,mpls_tc=7,mpls_ttl=128,mpls_bos=1
1641 NXT_PACKET_IN (xid=0x0): cookie=0xc total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1642 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=70:77:77:77:77:77,dl_dst=50:54:00:00:00:07,mpls_label=1000,mpls_tc=7,mpls_ttl=128,mpls_bos=1
1644 NXT_PACKET_IN (xid=0x0): cookie=0xc total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
1645 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=70:77:77:77:77:77,dl_dst=50:54:00:00:00:07,mpls_label=1000,mpls_tc=7,mpls_ttl=128,mpls_bos=1
1649 dnl Modified MPLS pop action.
1650 dnl The input is a frame with two MPLS headers which tcpdump -vve shows as:
1651 dnl 60:66:66:66:66:66 > 50:54:00:00:00:07, ethertype MPLS multicast (0x8847), length 66: MPLS (label 20, exp 0, ttl 32)
1652 dnl (tos 0x0, ttl 64, id 0, offset 0, flags [none], proto TCP (6), length 44)
1654 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1657 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 66 66 88 47 00 01 41 20 45 00 00 2c 00 00 00 00 40 06 3b 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
1660 # ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=60:66:66:66:66:66,dst=50:54:00:00:00:07),eth_type(0x8847),mpls(label=10,tc=3,ttl=100,bos=1)'
1662 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1663 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1665 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1666 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1667 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:66:66,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
1669 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1670 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:66:66,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
1672 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1673 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:66:66,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
1676 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1678 dnl Modified MPLS pop action.
1679 dnl The input is a frame with a single MPLS label stack entry which tcpdump -vve shows as:
1680 dnl 60:66:66:66:00:01 > 50:54:00:00:00:07, ethertype MPLS multicast (0x8848), length 62: MPLS (label 20, exp 0, [S], ttl 32)
1681 dnl (tos 0x0, ttl 255, id 0, offset 0, flags [none], proto TCP (6), length 44)
1682 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x77ec (correct), seq 42:46, win 10000, length 4
1683 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1686 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 00 01 88 48 00 01 41 20 45 00 00 2c 00 00 00 00 ff 06 3a 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
1688 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1689 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1691 AT_CHECK([STRIP_METADATA ofctl_monitor.log], [0], [dnl
1692 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1693 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:01,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=254,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
1695 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1696 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:01,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=254,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
1698 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1699 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:01,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=254,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
1702 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1704 dnl Modified MPLS pop action.
1705 dnl The input is a frame with a single MPLS label stack entry which tcpdump -vve shows as:
1706 dnl 60:66:66:66:00:02 > 50:54:00:00:00:07, ethertype MPLS unicast (0x8847), length 62: MPLS (label 20, exp 0, [S], ttl 32)
1707 dnl (tos 0x0, ttl 255, id 0, offset 0, flags [none], proto TCP (6), length 44)
1708 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x77ec (correct), seq 42:46, win 10000, length 4
1709 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1712 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 00 02 88 47 00 01 41 20 45 00 00 2c 00 00 00 00 ff 06 3a 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
1714 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1715 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1717 AT_CHECK([STRIP_METADATA ofctl_monitor.log], [0], [dnl
1718 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1719 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:02,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=10.0.0.1,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:2dee
1721 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1722 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:02,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=10.0.0.1,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:2dee
1724 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1725 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:02,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=10.0.0.1,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:2dee
1728 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1730 dnl Modified MPLS pop action.
1731 dnl The input is a frame with a single MPLS label stack entry which tcpdump -vve shows as:
1732 dnl 60:66:66:66:00:03 > 50:54:00:00:00:07, ethertype MPLS multicast (0x8848), length 62: MPLS (label 20, exp 0, [S], ttl 32)
1733 dnl (tos 0x0, ttl 255, id 0, offset 0, flags [none], proto TCP (6), length 44)
1734 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x77ec (correct), seq 42:46, win 10000, length 4
1735 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1738 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 00 03 88 48 00 01 41 20 45 00 00 2c 00 00 00 00 ff 06 3a 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
1740 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1741 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1743 AT_CHECK([STRIP_METADATA ofctl_monitor.log], [0], [dnl
1744 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1745 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:03,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.2,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7743
1747 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1748 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:03,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.2,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7743
1750 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1751 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:03,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.2,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7743
1754 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1756 dnl Modified MPLS pop action.
1757 dnl The input is a frame with a single MPLS label stack entry which tcpdump -vve shows as:
1758 dnl 60:66:66:66:00:04 > 50:54:00:00:00:07, ethertype MPLS unicast (0x8847), length 62: MPLS (label 20, exp 0, [S], ttl 32)
1759 dnl (tos 0x0, ttl 255, id 0, offset 0, flags [none], proto TCP (6), length 44)
1760 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x77ec (correct), seq 42:46, win 10000, length 4
1761 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1764 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 00 04 88 47 00 01 41 20 45 00 00 2c 00 00 00 00 ff 06 3a 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
1766 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1767 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1769 AT_CHECK([STRIP_METADATA ofctl_monitor.log], [0], [dnl
1770 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1771 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:04,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.2,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7743
1773 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1774 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:04,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.2,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7743
1776 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1777 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:04,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.2,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7743
1780 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1782 dnl Modified MPLS pop action.
1783 dnl The input is a frame with a single MPLS label stack entry which tcpdump -vve shows as:
1784 dnl 60:66:66:66:00:05 > 50:54:00:00:00:07, ethertype MPLS unicast (0x8847), length 62: MPLS (label 20, exp 0, [S], ttl 32)
1785 dnl (tos 0x0, ttl 255, id 0, offset 0, flags [none], proto TCP (6), length 44)
1786 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x77ec (correct), seq 42:46, win 10000, length 4
1787 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1790 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 00 05 88 48 00 01 41 20 45 00 00 2c 00 00 00 00 ff 06 3a 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
1792 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1793 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1795 AT_CHECK([STRIP_METADATA ofctl_monitor.log], [0], [dnl
1796 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1797 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.106,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:76db
1799 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1800 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.106,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:76db
1802 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1803 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.106,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:76db
1806 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1808 dnl Modified MPLS pop action.
1809 dnl The input is a frame with a single MPLS label stack entry which tcpdump -vve shows as:
1810 dnl 60:66:66:66:00:06 > 50:54:00:00:00:07, ethertype MPLS multicast (0x8848), length 62: MPLS (label 20, exp 0, [S], ttl 32)
1811 dnl (tos 0x0, ttl 255, id 0, offset 0, flags [none], proto TCP (6), length 44)
1812 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x77ec (correct), seq 42:46, win 10000, length 4
1813 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1816 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 00 06 88 47 00 01 41 20 45 00 00 2c 00 00 00 00 ff 06 3a 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
1818 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1819 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1821 AT_CHECK([STRIP_METADATA ofctl_monitor.log], [0], [dnl
1822 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1823 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:06,dl_dst=50:54:00:00:00:07,nw_src=192.168.255.255,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7745
1825 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1826 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:06,dl_dst=50:54:00:00:00:07,nw_src=192.168.255.255,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7745
1828 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1829 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:06,dl_dst=50:54:00:00:00:07,nw_src=192.168.255.255,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7745
1832 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1834 dnl Modified MPLS pop action.
1835 dnl The input is a frame with a single MPLS label stack entry which tcpdump -vve shows as:
1836 dnl 60:66:66:66:00:07 > 50:54:00:00:00:07, ethertype MPLS multicast (0x8848), length 62: MPLS (label 20, exp 0, [S], ttl 32)
1837 dnl (tos 0x0, ttl 255, id 0, offset 0, flags [none], proto TCP (6), length 44)
1838 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x77ec (correct), seq 42:46, win 10000, length 4
1839 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1842 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 00 07 88 48 00 01 41 20 45 00 00 2c 00 00 00 00 ff 06 3a 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
1844 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1845 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1847 AT_CHECK([STRIP_METADATA ofctl_monitor.log], [0], [dnl
1848 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1849 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:07,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
1851 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1852 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:07,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
1854 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1855 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:07,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
1858 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1860 dnl Modified MPLS pop action.
1861 dnl The input is an ARP frame with a single MPLS label stack entry which tcpdump -vve shows as:
1862 dnl 60:66:66:66:00:08 > ff:ff:ff:ff:ff:ff, ethertype MPLS unicast (0x8847), length 46: MPLS (label 20, exp 0, [S], ttl 32)
1863 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1866 ovs-appctl netdev-dummy/receive p1 'ff ff ff ff ff ff 60 66 66 66 00 08 88 47 00 01 41 20 00 01 08 00 06 04 00 02 60 66 66 66 00 08 c0 a8 00 01 ff ff ff ff ff ff ff ff ff ff'
1868 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1869 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1871 AT_CHECK([STRIP_METADATA ofctl_monitor.log], [0], [dnl
1872 NXT_PACKET_IN (xid=0x0): table_id=1 cookie=0xd total_len=56 in_port=1 (via action) data_len=56 (unbuffered)
1873 arp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:08,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=192.168.0.1,arp_tpa=255.255.255.255,arp_op=2,arp_sha=60:66:66:66:00:08,arp_tha=ff:ff:ff:ff:ff:ff
1875 NXT_PACKET_IN (xid=0x0): table_id=1 cookie=0xd total_len=56 in_port=1 (via action) data_len=56 (unbuffered)
1876 arp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:08,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=192.168.0.1,arp_tpa=255.255.255.255,arp_op=2,arp_sha=60:66:66:66:00:08,arp_tha=ff:ff:ff:ff:ff:ff
1878 NXT_PACKET_IN (xid=0x0): table_id=1 cookie=0xd total_len=56 in_port=1 (via action) data_len=56 (unbuffered)
1879 arp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:08,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=192.168.0.1,arp_tpa=255.255.255.255,arp_op=2,arp_sha=60:66:66:66:00:08,arp_tha=ff:ff:ff:ff:ff:ff
1882 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1884 dnl Modified MPLS pop action.
1885 dnl The input is a frame with a single MPLS label stack entry which tcpdump -vve shows as:
1886 dnl 60:66:66:66:00:09 > 50:54:00:00:00:07, ethertype MPLS multicast (0x8848), length 62: MPLS (label 20, exp 0, [S], ttl 32)
1887 dnl (tos 0x0, ttl 255, id 0, offset 0, flags [none], proto TCP (6), length 44)
1888 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x77ec (correct), seq 42:46, win 10000, length 4
1889 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1892 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 00 09 88 48 00 01 41 20 45 00 00 2c 00 00 00 00 ff 06 3a 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
1894 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1895 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1897 AT_CHECK([STRIP_METADATA ofctl_monitor.log], [0], [dnl
1898 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1899 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:09,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=48,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
1901 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1902 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:09,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=48,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
1904 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1905 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:09,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=48,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
1908 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1910 dnl Modified MPLS pop action.
1911 dnl The input is a frame with a single MPLS label stack entry which tcpdump -vve shows as:
1912 dnl 60:66:66:66:00:0a > 50:54:00:00:00:07, ethertype MPLS multicast (0x8848), length 62: MPLS (label 20, exp 0, [S], ttl 32)
1913 dnl (tos 0x0, ttl 255, id 0, offset 0, flags [none], proto TCP (6), length 44)
1914 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x77ec (correct), seq 42:46, win 10000, length 4
1915 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1918 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 00 0a 88 48 00 01 41 20 45 00 00 2c 00 00 00 00 ff 06 3a 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
1920 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1921 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1923 AT_CHECK([STRIP_METADATA ofctl_monitor.log], [0], [dnl
1924 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1925 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:0a,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=10.0.0.1,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:2dee
1927 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1928 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:0a,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=10.0.0.1,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:2dee
1930 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1931 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:0a,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=10.0.0.1,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:2dee
1934 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1936 dnl Modified MPLS pop action.
1937 dnl The input is a frame with a single MPLS label stack entry which tcpdump -vve shows as:
1938 dnl 60:66:66:66:00:0b > 50:54:00:00:00:07, ethertype MPLS multicast (0x8848), length 62: MPLS (label 20, exp 0, [S], ttl 32)
1939 dnl (tos 0x0, ttl 255, id 0, offset 0, flags [none], proto TCP (6), length 44)
1940 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x77ec (correct), seq 42:46, win 10000, length 4
1941 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1944 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 00 0b 88 48 00 01 41 20 45 00 00 2c 00 00 00 00 ff 06 3a 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
1946 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1947 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1949 AT_CHECK([STRIP_METADATA ofctl_monitor.log], [0], [dnl
1950 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1951 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:0b,dl_dst=50:54:00:00:00:07,nw_src=10.0.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:2ded
1953 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1954 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:0b,dl_dst=50:54:00:00:00:07,nw_src=10.0.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:2ded
1956 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
1957 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:0b,dl_dst=50:54:00:00:00:07,nw_src=10.0.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:2ded
1960 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1962 dnl Modified MPLS pop action.
1963 dnl The input is a frame with two MPLS label stack entries which tcpdump -vve shows as:
1964 dnl 60:66:66:66:01:00 > 50:54:00:00:00:07, ethertype MPLS multicast (0x8848), length 66: MPLS (label 20, exp 0, ttl 32)
1965 dnl (label 20, exp 0, [S], ttl 31)
1966 dnl (tos 0x0, ttl 254, id 0, offset 0, flags [none], proto TCP (6), length 44)
1967 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x7744 (correct), seq 42:46, win 10000, length 4
1968 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1971 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 01 00 88 48 00 01 40 20 00 01 41 1f 45 00 00 2c 00 00 00 00 ff 06 3b 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
1973 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
1974 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
1976 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
1977 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
1978 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:01:00,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=31,mpls_bos=1
1980 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
1981 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:01:00,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=31,mpls_bos=1
1983 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
1984 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:01:00,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=31,mpls_bos=1
1987 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
1989 dnl Modified MPLS pop action.
1990 dnl The input is a frame with two MPLS label stack entries which tcpdump -vve shows as:
1991 dnl 60:66:66:66:01:01 > 50:54:00:00:00:07, ethertype MPLS unicast (0x8847), length 66: MPLS (label 20, exp 0, ttl 32)
1992 dnl (label 20, exp 0, [S], ttl 31)
1993 dnl (tos 0x0, ttl 254, id 0, offset 0, flags [none], proto TCP (6), length 44)
1994 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x7744 (correct), seq 42:46, win 10000, length 4
1995 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
1998 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 01 01 88 47 00 01 40 20 00 01 41 1f 45 00 00 2c 00 00 00 00 ff 06 3b 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
2000 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
2001 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2003 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
2004 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2005 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:01:01,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=30,mpls_bos=1
2007 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2008 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:01:01,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=30,mpls_bos=1
2010 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2011 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:01:01,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=30,mpls_bos=1
2014 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2016 dnl Modified MPLS pop action.
2017 dnl The input is a frame with two MPLS label stack entries which tcpdump -vve shows as:
2018 dnl 60:66:66:66:01:02 > 50:54:00:00:00:07, ethertype MPLS multicast (0x8848), length 66: MPLS (label 20, exp 0, ttl 32)
2019 dnl (label 20, exp 0, [S], ttl 31)
2020 dnl (tos 0x0, ttl 254, id 0, offset 0, flags [none], proto TCP (6), length 44)
2021 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x7744 (correct), seq 42:46, win 10000, length 4
2022 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
2025 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 01 02 88 48 00 01 40 20 00 01 41 1f 45 00 00 2c 00 00 00 00 ff 06 3b 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
2027 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
2028 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2030 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
2031 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2032 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:01:02,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=3,mpls_ttl=31,mpls_bos=1
2034 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2035 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:01:02,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=3,mpls_ttl=31,mpls_bos=1
2037 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2038 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:01:02,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=3,mpls_ttl=31,mpls_bos=1
2041 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2043 dnl Modified MPLS pop action.
2044 dnl The input is a frame with two MPLS label stack entries which tcpdump -vve shows as:
2045 dnl 60:66:66:66:02:00 > 50:54:00:00:02:00, ethertype MPLS unicast (0x8847), length 66: MPLS (label 20, exp 0, ttl 32)
2046 dnl (label 20, exp 0, [S], ttl 31)
2047 dnl (tos 0x0, ttl 254, id 0, offset 0, flags [none], proto TCP (6), length 44)
2048 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x7744 (correct), seq 42:46, win 10000, length 4
2049 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
2052 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 02 00 88 47 00 01 40 20 00 01 41 1f 45 00 00 2c 00 00 00 00 ff 06 3b 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
2054 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
2055 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2057 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
2058 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
2059 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:02:00,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
2061 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
2062 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:02:00,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
2064 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
2065 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:02:00,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
2068 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2070 dnl Modified MPLS pop action.
2071 dnl The input is a frame with two MPLS label stack entries which tcpdump -vve shows as:
2072 dnl 60:66:66:66:02:01 > 50:54:00:00:02:01, ethertype MPLS multicast (0x8848), length 66: MPLS (label 20, exp 0, ttl 32)
2073 dnl (label 20, exp 0, [S], ttl 31)
2074 dnl (tos 0x0, ttl 254, id 0, offset 0, flags [none], proto TCP (6), length 44)
2075 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x7744 (correct), seq 42:46, win 10000, length 4
2076 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
2079 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 02 01 88 48 00 01 40 20 00 01 41 1f 45 00 00 2c 00 00 00 00 ff 06 3b 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
2081 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
2082 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2084 AT_CHECK([STRIP_METADATA ofctl_monitor.log], [0], [dnl
2085 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
2086 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:02:01,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=254,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
2088 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
2089 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:02:01,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=254,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
2091 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
2092 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:02:01,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=254,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
2095 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2097 dnl Modified MPLS pop action.
2098 dnl The input is a frame with two MPLS label stack entries which tcpdump -vve shows as:
2099 dnl 60:66:66:66:02:10 > 50:54:00:00:02:10, ethertype MPLS unicast (0x8847), length 66: MPLS (label 20, exp 0, ttl 32)
2100 dnl (label 20, exp 0, [S], ttl 31)
2101 dnl (tos 0x0, ttl 254, id 0, offset 0, flags [none], proto TCP (6), length 44)
2102 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x7744 (correct), seq 42:46, win 10000, length 4
2103 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
2106 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 02 10 88 47 00 01 40 20 00 01 41 1f 45 00 00 2c 00 00 00 00 ff 06 3b 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
2108 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
2109 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2111 AT_CHECK([STRIP_METADATA ofctl_monitor.log], [0], [dnl
2112 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
2113 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:02:10,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=254,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
2115 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
2116 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:02:10,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=254,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
2118 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
2119 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:02:10,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=254,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
2122 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2124 dnl Modified MPLS pop action.
2125 dnl The input is a frame with three MPLS label stack entries which tcpdump -vve shows as:
2126 dnl 60:66:66:66:03:00 > 50:54:00:00:00:00, ethertype MPLS unicast (0x8847), length 66: MPLS (label 20, exp 0, ttl 32)
2127 dnl (label 20, exp 0, ttl 31)
2128 dnl (label 20, exp 0, [S], ttl 30)
2129 dnl (tos 0x0, ttl 254, id 0, offset 0, flags [none], proto TCP (6), length 44)
2130 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x7744 (correct), seq 42:46, win 10000, length 4
2131 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
2134 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 03 00 88 47 00 01 40 20 00 01 40 1f 00 01 41 1e 45 00 00 2c 00 00 00 00 ff 06 3b 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
2136 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
2137 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2139 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
2140 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2141 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:03:00,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=30,mpls_bos=1
2143 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2144 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:03:00,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=30,mpls_bos=1
2146 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2147 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:03:00,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=30,mpls_bos=1
2150 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2152 dnl Modified MPLS pop action.
2153 dnl The input is a frame with three MPLS label stack entries which tcpdump -vve shows as:
2154 dnl 60:66:66:66:03:01 > 50:54:00:00:00:00, ethertype MPLS multicast (0x8848), length 66: MPLS (label 20, exp 0, ttl 32)
2155 dnl (label 20, exp 0, ttl 31)
2156 dnl (label 20, exp 0, [S], ttl 30)
2157 dnl (tos 0x0, ttl 254, id 0, offset 0, flags [none], proto TCP (6), length 44)
2158 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x7744 (correct), seq 42:46, win 10000, length 4
2159 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
2162 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 03 01 88 48 00 01 40 20 00 01 40 1f 00 01 41 1e 45 00 00 2c 00 00 00 00 ff 06 3b 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
2164 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
2165 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2167 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
2168 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2169 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:03:01,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=29,mpls_bos=1
2171 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2172 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:03:01,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=29,mpls_bos=1
2174 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2175 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:03:01,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=29,mpls_bos=1
2178 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2180 dnl Modified MPLS pop action.
2181 dnl The input is a frame with three MPLS label stack entries which tcpdump -vve shows as:
2182 dnl 60:66:66:66:03:10 > 50:54:00:00:00:00, ethertype MPLS unicast (0x8847), length 66: MPLS (label 20, exp 0, ttl 32)
2183 dnl (label 20, exp 0, ttl 31)
2184 dnl (label 20, exp 0, [S], ttl 30)
2185 dnl (tos 0x0, ttl 254, id 0, offset 0, flags [none], proto TCP (6), length 44)
2186 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x7744 (correct), seq 42:46, win 10000, length 4
2187 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
2190 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 03 10 88 47 00 01 40 20 00 01 40 1f 00 01 41 1e 45 00 00 2c 00 00 00 00 ff 06 3b 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
2192 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
2193 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2195 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
2196 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2197 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:03:10,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=29,mpls_bos=1
2199 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2200 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:03:10,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=29,mpls_bos=1
2202 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2203 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:03:10,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=29,mpls_bos=1
2206 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2208 dnl Modified MPLS pop action.
2209 dnl The input is a frame with a single MPLS label stack entry which tcpdump -vve shows as:
2210 dnl 60:66:66:66:04:00 > 50:54:00:00:00:07, ethertype MPLS multicast (0x8848), length 62: MPLS (label 20, exp 0, [S], ttl 32)
2211 dnl (tos 0x0, ttl 255, id 0, offset 0, flags [none], proto TCP (6), length 44)
2212 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x77ec (correct), seq 42:46, win 10000, length 4
2213 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
2216 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 04 00 88 48 00 01 41 20 45 00 00 2c 00 00 00 00 ff 06 3a 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
2218 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
2219 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2221 AT_CHECK([STRIP_METADATA ofctl_monitor.log], [0], [dnl
2222 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2223 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:04:00,dl_dst=50:54:00:00:00:07,mpls_label=0,mpls_tc=0,mpls_ttl=255,mpls_bos=1
2225 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2226 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:04:00,dl_dst=50:54:00:00:00:07,mpls_label=0,mpls_tc=0,mpls_ttl=255,mpls_bos=1
2228 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2229 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:04:00,dl_dst=50:54:00:00:00:07,mpls_label=0,mpls_tc=0,mpls_ttl=255,mpls_bos=1
2232 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2234 dnl Modified MPLS pop action.
2235 dnl The input is a frame with a single MPLS label stack entry which tcpdump -vve shows as:
2236 dnl 60:66:66:66:04:01 > 50:54:00:00:00:07, ethertype MPLS unicast (0x8847), length 62: MPLS (label 20, exp 0, [S], ttl 32)
2237 dnl (tos 0x0, ttl 255, id 0, offset 0, flags [none], proto TCP (6), length 44)
2238 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x77ec (correct), seq 42:46, win 10000, length 4
2239 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
2242 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 04 01 88 47 00 01 41 20 45 00 00 2c 00 00 00 00 ff 06 3a 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
2244 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
2245 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2247 AT_CHECK([STRIP_METADATA ofctl_monitor.log], [0], [dnl
2248 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2249 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:04:01,dl_dst=50:54:00:00:00:07,mpls_label=0,mpls_tc=0,mpls_ttl=254,mpls_bos=1
2251 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2252 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:04:01,dl_dst=50:54:00:00:00:07,mpls_label=0,mpls_tc=0,mpls_ttl=254,mpls_bos=1
2254 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2255 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:04:01,dl_dst=50:54:00:00:00:07,mpls_label=0,mpls_tc=0,mpls_ttl=254,mpls_bos=1
2258 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2260 dnl Modified MPLS pop action.
2261 dnl The input is a frame with a single MPLS label stack entry which tcpdump -vve shows as:
2262 dnl 60:66:66:66:04:10 > 50:54:00:00:00:07, ethertype MPLS multicast (0x8848), length 62: MPLS (label 20, exp 0, [S], ttl 32)
2263 dnl (tos 0x0, ttl 255, id 0, offset 0, flags [none], proto TCP (6), length 44)
2264 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x77ec (correct), seq 42:46, win 10000, length 4
2265 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
2268 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 04 10 88 48 00 01 41 20 45 00 00 2c 00 00 00 00 ff 06 3a 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
2270 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
2271 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2273 AT_CHECK([STRIP_METADATA ofctl_monitor.log], [0], [dnl
2274 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2275 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:04:10,dl_dst=50:54:00:00:00:07,mpls_label=0,mpls_tc=0,mpls_ttl=253,mpls_bos=1
2277 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2278 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:04:10,dl_dst=50:54:00:00:00:07,mpls_label=0,mpls_tc=0,mpls_ttl=253,mpls_bos=1
2280 NXT_PACKET_IN (xid=0x0): table_id=254 cookie=0x0 total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2281 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:04:10,dl_dst=50:54:00:00:00:07,mpls_label=0,mpls_tc=0,mpls_ttl=253,mpls_bos=1
2284 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2286 dnl Modified MPLS pop action.
2287 dnl The input is a frame with a single MPLS label stack entry which tcpdump -vve shows as:
2288 dnl 60:66:66:66:05:00 > 50:54:00:00:00:07, ethertype MPLS unicast (0x8847), length 62: MPLS (label 20, exp 0, [S], ttl 32)
2289 dnl (tos 0x0, ttl 255, id 0, offset 0, flags [none], proto TCP (6), length 44)
2290 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x77ec (correct), seq 42:46, win 10000, length 4
2291 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
2294 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 05 00 88 47 00 01 41 20 45 00 00 2c 00 00 00 00 ff 06 3a 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
2296 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
2297 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2299 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
2300 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2301 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:05:00,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=32,mpls_bos=1
2303 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2304 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:05:00,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=32,mpls_bos=1
2306 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2307 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:05:00,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=32,mpls_bos=1
2310 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2312 dnl Modified MPLS pop action.
2313 dnl The input is a frame with a single MPLS label stack entry which tcpdump -vve shows as:
2314 dnl 60:66:66:66:05:01 > 50:54:00:00:00:07, ethertype MPLS multicast (0x8848), length 62: MPLS (label 20, exp 0, [S], ttl 32)
2315 dnl (tos 0x0, ttl 255, id 0, offset 0, flags [none], proto TCP (6), length 44)
2316 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x77ec (correct), seq 42:46, win 10000, length 4
2317 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
2320 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 05 01 88 48 00 01 41 20 45 00 00 2c 00 00 00 00 ff 06 3a 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
2322 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
2323 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2325 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
2326 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2327 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:05:01,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=31,mpls_bos=1
2329 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2330 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:05:01,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=31,mpls_bos=1
2332 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2333 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:05:01,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=31,mpls_bos=1
2336 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2338 dnl Modified MPLS pop action.
2339 dnl The input is a frame with a single MPLS label stack entry which tcpdump -vve shows as:
2340 dnl 60:66:66:66:05:10 > 50:54:00:00:00:07, ethertype MPLS unicast (0x8847), length 62: MPLS (label 20, exp 0, [S], ttl 32)
2341 dnl (tos 0x0, ttl 255, id 0, offset 0, flags [none], proto TCP (6), length 44)
2342 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x77ec (correct), seq 42:46, win 10000, length 4
2343 AT_CHECK([ovs-ofctl monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
2346 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 07 60 66 66 66 05 10 88 47 00 01 41 20 45 00 00 2c 00 00 00 00 ff 06 3a 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
2348 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
2349 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2351 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
2352 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2353 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:05:10,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=31,mpls_bos=1
2355 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2356 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:05:10,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=31,mpls_bos=1
2358 NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=62 in_port=1 (via action) data_len=62 (unbuffered)
2359 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:05:10,dl_dst=50:54:00:00:00:07,mpls_label=20,mpls_tc=0,mpls_ttl=31,mpls_bos=1
2362 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2363 AT_CHECK([ovs-appctl revalidator/wait], [0], [ignore])
2365 AT_CHECK([ovs-ofctl dump-flows br0 | ofctl_strip | sort], [0], [dnl
2366 cookie=0xa, n_packets=3, n_bytes=180, dl_src=40:44:44:44:44:42 actions=push_mpls:0x8847,load:0xa->OXM_OF_MPLS_LABEL[[]],load:0x3->OXM_OF_MPLS_TC[[]],CONTROLLER:65535
2367 cookie=0xa, n_packets=3, n_bytes=180, dl_src=40:44:44:44:44:43 actions=push_mpls:0x8847,load:0xa->OXM_OF_MPLS_LABEL[[]],load:0x3->OXM_OF_MPLS_TC[[]],CONTROLLER:65535
2368 cookie=0xa, n_packets=3, n_bytes=180, dl_src=40:44:44:44:44:44 actions=push_mpls:0x8847,load:0xa->OXM_OF_MPLS_LABEL[[]],load:0x3->OXM_OF_MPLS_TC[[]],CONTROLLER:65535
2369 cookie=0xa, n_packets=3, n_bytes=180, dl_src=40:44:44:44:44:45 actions=push_mpls:0x8847,load:0xa->OXM_OF_MPLS_LABEL[[]],load:0x3->OXM_OF_MPLS_TC[[]],dec_mpls_ttl,CONTROLLER:65535
2370 cookie=0xa, n_packets=3, n_bytes=180, dl_src=40:44:44:44:44:46 actions=push_mpls:0x8847,load:0xa->OXM_OF_MPLS_LABEL[[]],load:0x3->OXM_OF_MPLS_TC[[]],set_mpls_ttl(10),CONTROLLER:65535
2371 cookie=0xa, n_packets=3, n_bytes=180, dl_src=40:44:44:44:44:47 actions=push_mpls:0x8847,load:0xa->OXM_OF_MPLS_LABEL[[]],load:0x3->OXM_OF_MPLS_TC[[]],dec_mpls_ttl,set_mpls_ttl(10),CONTROLLER:65535
2372 cookie=0xa, n_packets=3, n_bytes=180, dl_src=40:44:44:44:44:48 actions=push_mpls:0x8847,load:0xa->OXM_OF_MPLS_LABEL[[]],load:0x3->OXM_OF_MPLS_TC[[]],set_mpls_ttl(10),dec_mpls_ttl,CONTROLLER:65535
2373 cookie=0xa, n_packets=3, n_bytes=180, dl_src=41:44:44:44:44:42 actions=push_mpls:0x8847,load:0xa->OXM_OF_MPLS_LABEL[[]],load:0x3->OXM_OF_MPLS_TC[[]],pop_mpls:0x0800,CONTROLLER:65535
2374 cookie=0xa, n_packets=3, n_bytes=180, mpls,dl_src=40:44:44:44:44:49 actions=push_mpls:0x8848,load:0xa->OXM_OF_MPLS_LABEL[[]],CONTROLLER:65535
2375 cookie=0xb, n_packets=3, n_bytes=180, mpls,dl_src=50:55:55:55:55:55 actions=load:0x3e8->OXM_OF_MPLS_LABEL[[]],CONTROLLER:65535
2376 cookie=0xc, n_packets=3, n_bytes=180, dl_src=70:77:77:77:77:77 actions=push_mpls:0x8848,load:0x3e8->OXM_OF_MPLS_LABEL[[]],load:0x7->OXM_OF_MPLS_TC[[]],CONTROLLER:65535
2377 cookie=0xd, n_packets=3, n_bytes=180, dl_src=60:66:66:66:00:08 actions=pop_mpls:0x0806,resubmit(1,1)
2378 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:00:01 actions=pop_mpls:0x0800,dec_ttl,CONTROLLER:65535
2379 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:00:02 actions=pop_mpls:0x0800,load:0xa000001->NXM_OF_IP_DST[[]],CONTROLLER:65535
2380 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:00:03 actions=pop_mpls:0x0800,move:NXM_OF_IP_DST[[]]->NXM_OF_IP_SRC[[]],CONTROLLER:65535
2381 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:00:04 actions=pop_mpls:0x0800,push:NXM_OF_IP_DST[[]],pop:NXM_OF_IP_SRC[[]],CONTROLLER:65535
2382 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:00:05 actions=pop_mpls:0x0800,multipath(eth_src,50,modulo_n,256,0,NXM_OF_IP_SRC[[0..7]]),CONTROLLER:65535
2383 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:00:06 actions=pop_mpls:0x0800,bundle_load(eth_src,50,hrw,ofport,NXM_OF_IP_SRC[[0..15]],slaves:1,2),CONTROLLER:65535
2384 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:00:07 actions=pop_mpls:0x0800,learn(table=1,hard_timeout=60,eth_type=0x800,nw_proto=6,NXM_OF_IP_SRC[[]]=NXM_OF_IP_DST[[]]),CONTROLLER:65535
2385 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:00:09 actions=pop_mpls:0x0800,mod_nw_tos:48,CONTROLLER:65535
2386 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:00:0a actions=pop_mpls:0x0800,mod_nw_dst:10.0.0.1,CONTROLLER:65535
2387 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:00:0b actions=pop_mpls:0x0800,mod_nw_src:10.0.0.1,CONTROLLER:65535
2388 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:04:00 actions=pop_mpls:0x0800,push_mpls:0x8847,CONTROLLER:65535
2389 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:04:01 actions=pop_mpls:0x0800,push_mpls:0x8848,dec_mpls_ttl,CONTROLLER:65535
2390 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:04:10 actions=pop_mpls:0x0800,dec_ttl,push_mpls:0x8848,dec_mpls_ttl,CONTROLLER:65535
2391 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:05:00 actions=push_mpls:0x8848,pop_mpls:0x8847,CONTROLLER:65535
2392 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:05:01 actions=push_mpls:0x8847,pop_mpls:0x8848,dec_mpls_ttl,CONTROLLER:65535
2393 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:05:10 actions=push_mpls:0x8848,dec_mpls_ttl,pop_mpls:0x8847,dec_mpls_ttl,CONTROLLER:65535
2394 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:66:66 actions=pop_mpls:0x0800,CONTROLLER:65535
2395 cookie=0xd, n_packets=3, n_bytes=198, dl_src=60:66:66:66:01:00 actions=pop_mpls:0x8848,CONTROLLER:65535
2396 cookie=0xd, n_packets=3, n_bytes=198, dl_src=60:66:66:66:01:01 actions=pop_mpls:0x8847,dec_mpls_ttl,CONTROLLER:65535
2397 cookie=0xd, n_packets=3, n_bytes=198, dl_src=60:66:66:66:01:02 actions=pop_mpls:0x8848,load:0x3->OXM_OF_MPLS_TC[[]],CONTROLLER:65535
2398 cookie=0xd, n_packets=3, n_bytes=198, dl_src=60:66:66:66:02:00 actions=pop_mpls:0x8847,pop_mpls:0x0800,CONTROLLER:65535
2399 cookie=0xd, n_packets=3, n_bytes=198, dl_src=60:66:66:66:02:01 actions=pop_mpls:0x8848,pop_mpls:0x0800,dec_ttl,CONTROLLER:65535
2400 cookie=0xd, n_packets=3, n_bytes=198, dl_src=60:66:66:66:02:10 actions=pop_mpls:0x8847,dec_mpls_ttl,pop_mpls:0x0800,dec_ttl,CONTROLLER:65535
2401 cookie=0xd, n_packets=3, n_bytes=210, dl_src=60:66:66:66:03:00 actions=pop_mpls:0x8848,pop_mpls:0x8848,CONTROLLER:65535
2402 cookie=0xd, n_packets=3, n_bytes=210, dl_src=60:66:66:66:03:01 actions=pop_mpls:0x8847,pop_mpls:0x8847,dec_mpls_ttl,CONTROLLER:65535
2403 cookie=0xd, n_packets=3, n_bytes=210, dl_src=60:66:66:66:03:10 actions=pop_mpls:0x8848,dec_mpls_ttl,pop_mpls:0x8848,dec_mpls_ttl,CONTROLLER:65535
2404 cookie=0xd, table=1, n_packets=3, n_bytes=168, arp actions=CONTROLLER:65535
2411 AT_SETUP([ofproto-dpif - MPLS handling with goto_table])
2412 OVS_VSWITCHD_START([dnl
2413 add-port br0 p1 -- set Interface p1 type=dummy
2415 ON_EXIT([kill `cat ovs-ofctl.pid`])
2417 AT_CAPTURE_FILE([ofctl_monitor.log])
2418 AT_DATA([flows.txt], [dnl
2419 table=0 mplsm actions=pop_mpls:0x800,goto_table(1)
2420 table=1 ip,ip_dscp=8 actions=controller
2422 AT_CHECK([ovs-ofctl -O OpenFlow12 add-flows br0 flows.txt])
2425 dnl Modified MPLS pop action.
2426 dnl The input is a frame with a single MPLS label stack entry which tcpdump -vve shows as:
2427 dnl 60:66:66:66:00:08 > 50:54:00:00:00:01, ethertype MPLS multicast (0x8848), length 62: MPLS (label 20, exp 0, [S], ttl 32)
2428 dnl (tos 0x20, ttl 255, id 0, offset 0, flags [none], proto TCP (6), length 44)
2429 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x77ec (correct), seq 42:46, win 10000, length 4
2430 AT_CHECK([ovs-ofctl -O OpenFlow12 monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
2433 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 01 60 66 66 66 00 08 88 48 00 01 41 20 45 20 00 2c 00 00 00 00 ff 06 3a 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
2435 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
2436 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2438 AT_CHECK([STRIP_METADATA ofctl_monitor.log], [0], [dnl
2439 OFPT_PACKET_IN (OF1.2) (xid=0x0): table_id=1 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
2440 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:08,dl_dst=50:54:00:00:00:01,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=32,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
2442 OFPT_PACKET_IN (OF1.2) (xid=0x0): table_id=1 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
2443 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:08,dl_dst=50:54:00:00:00:01,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=32,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
2445 OFPT_PACKET_IN (OF1.2) (xid=0x0): table_id=1 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
2446 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:08,dl_dst=50:54:00:00:00:01,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=32,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
2449 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2451 AT_CHECK([ovs-ofctl -O OpenFlow12 dump-flows br0 | ofctl_strip | sort], [0], [dnl
2452 n_packets=3, n_bytes=186, mplsm actions=pop_mpls:0x0800,goto_table:1
2453 table=1, n_packets=3, n_bytes=174, ip,nw_tos=32 actions=CONTROLLER:65535
2454 OFPST_FLOW reply (OF1.2):
2460 AT_SETUP([ofproto-dpif - MPLS handling with write_actions])
2461 OVS_VSWITCHD_START([dnl
2462 add-port br0 p1 -- set Interface p1 type=dummy
2464 ON_EXIT([kill `cat ovs-ofctl.pid`])
2466 dnl N.B: The first (and only) action that accesses L3 data after the
2467 dnl pop_mpls action is present in write_actions. This exercises recirculation
2468 dnl triggered in write_actions due to a previous action not in write actions.
2469 AT_CAPTURE_FILE([ofctl_monitor.log])
2470 AT_DATA([flows.txt], [dnl
2471 mplsm actions=pop_mpls:0x800,write_actions(dec_ttl,controller)
2473 AT_CHECK([ovs-ofctl -O OpenFlow12 add-flows br0 flows.txt])
2475 dnl Modified MPLS pop action.
2476 dnl The input is a frame with a single MPLS label stack entry which tcpdump -vve shows as:
2477 dnl 60:66:66:66:00:08 > 50:54:00:00:00:01, ethertype MPLS multicast (0x8848), length 62: MPLS (label 20, exp 0, [S], ttl 32)
2478 dnl (tos 0x20, ttl 255, id 0, offset 0, flags [none], proto TCP (6), length 44)
2479 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x77ec (correct), seq 42:46, win 10000, length 4
2480 AT_CHECK([ovs-ofctl -O OpenFlow12 monitor br0 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
2483 ovs-appctl netdev-dummy/receive p1 '50 54 00 00 00 01 60 66 66 66 00 08 88 48 00 01 41 20 45 20 00 2c 00 00 00 00 ff 06 3a 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45'
2485 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
2486 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2488 AT_CHECK([STRIP_METADATA ofctl_monitor.log], [0], [dnl
2489 OFPT_PACKET_IN (OF1.2) (xid=0x0): table_id=254 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
2490 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:08,dl_dst=50:54:00:00:00:01,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=32,nw_ecn=0,nw_ttl=254,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
2492 OFPT_PACKET_IN (OF1.2) (xid=0x0): table_id=254 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
2493 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:08,dl_dst=50:54:00:00:00:01,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=32,nw_ecn=0,nw_ttl=254,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
2495 OFPT_PACKET_IN (OF1.2) (xid=0x0): table_id=254 total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
2496 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=60:66:66:66:00:08,dl_dst=50:54:00:00:00:01,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=32,nw_ecn=0,nw_ttl=254,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
2499 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2501 AT_CHECK([ovs-ofctl -O OpenFlow12 dump-flows br0 | ofctl_strip | sort], [0], [dnl
2502 n_packets=3, n_bytes=186, mplsm actions=pop_mpls:0x0800,write_actions(dec_ttl,CONTROLLER:65535)
2503 OFPST_FLOW reply (OF1.2):
2509 AT_SETUP([ofproto-dpif - table-miss flow (OpenFlow 1.0)])
2510 OVS_VSWITCHD_START([dnl
2511 add-port br0 p1 -- set Interface p1 type=dummy
2513 ON_EXIT([kill `cat ovs-ofctl.pid`])
2515 AT_CAPTURE_FILE([ofctl_monitor.log])
2516 # A table-miss flow has priority 0 and no match
2517 AT_CHECK([ovs-ofctl --protocols=OpenFlow10 add-flow br0 'priority=0 actions=output:CONTROLLER'])
2519 dnl Singleton controller action.
2520 AT_CHECK([ovs-ofctl monitor -P openflow10 --protocols=OpenFlow10 br0 65534 --detach --no-chdir --pidfile 2> ofctl_monitor.log])
2523 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=10:11:11:11:11:11,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=10),tcp_flags(0x002)'
2525 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
2526 ovs-appctl -t ovs-ofctl exit
2528 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
2529 OFPT_PACKET_IN (xid=0x0): total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
2530 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=10:11:11:11:11:11,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=10,tcp_flags=syn tcp_csum:0
2532 OFPT_PACKET_IN (xid=0x0): total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
2533 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=10:11:11:11:11:11,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=10,tcp_flags=syn tcp_csum:0
2535 OFPT_PACKET_IN (xid=0x0): total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
2536 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=10:11:11:11:11:11,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=10,tcp_flags=syn tcp_csum:0
2539 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2540 AT_CHECK([ovs-appctl revalidator/wait], [0], [ignore])
2542 AT_CHECK([ovs-ofctl --protocols=OpenFlow10 dump-flows br0 | ofctl_strip | sort], [0], [dnl
2543 n_packets=3, n_bytes=180, priority=0 actions=CONTROLLER:65535
2551 AT_SETUP([ofproto-dpif - table-miss flow (OpenFlow 1.3)])
2552 OVS_VSWITCHD_START([dnl
2553 add-port br0 p1 -- set Interface p1 type=dummy
2555 ON_EXIT([kill `cat ovs-ofctl.pid`])
2557 AT_CAPTURE_FILE([ofctl_monitor.log])
2558 # A table-miss flow has priority 0 and no match
2559 AT_CHECK([ovs-ofctl --protocols=OpenFlow13 add-flow br0 'priority=0 actions=output:CONTROLLER'])
2561 dnl Singleton controller action.
2562 AT_CHECK([ovs-ofctl monitor -P openflow10 --protocols=OpenFlow13 br0 65534 --detach --no-chdir --pidfile 2> ofctl_monitor.log])
2565 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=10:11:11:11:11:11,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=8,dst=10),tcp_flags(0x002)'
2567 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
2568 ovs-appctl -t ovs-ofctl exit
2570 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2572 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
2573 OFPT_PACKET_IN (OF1.3) (xid=0x0): cookie=0x0 total_len=60 in_port=1 (via no_match) data_len=60 (unbuffered)
2574 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=10:11:11:11:11:11,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=10,tcp_flags=syn tcp_csum:0
2576 OFPT_PACKET_IN (OF1.3) (xid=0x0): cookie=0x0 total_len=60 in_port=1 (via no_match) data_len=60 (unbuffered)
2577 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=10:11:11:11:11:11,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=10,tcp_flags=syn tcp_csum:0
2579 OFPT_PACKET_IN (OF1.3) (xid=0x0): cookie=0x0 total_len=60 in_port=1 (via no_match) data_len=60 (unbuffered)
2580 tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=10:11:11:11:11:11,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=8,tp_dst=10,tcp_flags=syn tcp_csum:0
2583 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2585 AT_CHECK([ovs-ofctl --protocols=OpenFlow13 dump-flows br0 | ofctl_strip | sort], [0], [dnl
2586 n_packets=3, n_bytes=180, priority=0 actions=CONTROLLER:65535
2587 OFPST_FLOW reply (OF1.3):
2593 AT_SETUP([ofproto-dpif - ARP modification slow-path])
2595 ADD_OF_PORTS([br0], [1], [2])
2597 ovs-vsctl -- set Interface p2 type=dummy options:pcap=p2.pcap
2598 ovs-ofctl add-flow br0 'in_port=1,arp actions=load:2->OXM_OF_ARP_OP[[]],2,load:0xc0a88001->OXM_OF_ARP_SPA[[]],2,load:0x404444444441->OXM_OF_ARP_THA[[]],2'
2600 # Input some packets that should follow the arp modification slow-path.
2602 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=80:88:88:88:88:88,dst=ff:ff:ff:ff:ff:ff),eth_type(0x0806),arp(sip=192.168.0.1,tip=192.168.0.2,op=1,sha=50:54:00:00:00:05,tha=00:00:00:00:00:00)'
2604 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
2606 # Check the packets that were output.
2607 AT_CHECK([ovs-ofctl parse-pcap p2.pcap], [0], [dnl
2608 arp,metadata=0,in_port=ANY,vlan_tci=0x0000,dl_src=80:88:88:88:88:88,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=192.168.0.1,arp_tpa=192.168.0.2,arp_op=2,arp_sha=50:54:00:00:00:05,arp_tha=00:00:00:00:00:00
2609 arp,metadata=0,in_port=ANY,vlan_tci=0x0000,dl_src=80:88:88:88:88:88,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=192.168.128.1,arp_tpa=192.168.0.2,arp_op=2,arp_sha=50:54:00:00:00:05,arp_tha=00:00:00:00:00:00
2610 arp,metadata=0,in_port=ANY,vlan_tci=0x0000,dl_src=80:88:88:88:88:88,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=192.168.128.1,arp_tpa=192.168.0.2,arp_op=2,arp_sha=50:54:00:00:00:05,arp_tha=40:44:44:44:44:41
2611 arp,metadata=0,in_port=ANY,vlan_tci=0x0000,dl_src=80:88:88:88:88:88,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=192.168.0.1,arp_tpa=192.168.0.2,arp_op=2,arp_sha=50:54:00:00:00:05,arp_tha=00:00:00:00:00:00
2612 arp,metadata=0,in_port=ANY,vlan_tci=0x0000,dl_src=80:88:88:88:88:88,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=192.168.128.1,arp_tpa=192.168.0.2,arp_op=2,arp_sha=50:54:00:00:00:05,arp_tha=00:00:00:00:00:00
2613 arp,metadata=0,in_port=ANY,vlan_tci=0x0000,dl_src=80:88:88:88:88:88,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=192.168.128.1,arp_tpa=192.168.0.2,arp_op=2,arp_sha=50:54:00:00:00:05,arp_tha=40:44:44:44:44:41
2614 arp,metadata=0,in_port=ANY,vlan_tci=0x0000,dl_src=80:88:88:88:88:88,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=192.168.0.1,arp_tpa=192.168.0.2,arp_op=2,arp_sha=50:54:00:00:00:05,arp_tha=00:00:00:00:00:00
2615 arp,metadata=0,in_port=ANY,vlan_tci=0x0000,dl_src=80:88:88:88:88:88,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=192.168.128.1,arp_tpa=192.168.0.2,arp_op=2,arp_sha=50:54:00:00:00:05,arp_tha=00:00:00:00:00:00
2616 arp,metadata=0,in_port=ANY,vlan_tci=0x0000,dl_src=80:88:88:88:88:88,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=192.168.128.1,arp_tpa=192.168.0.2,arp_op=2,arp_sha=50:54:00:00:00:05,arp_tha=40:44:44:44:44:41
2622 AT_SETUP([ofproto-dpif - VLAN handling])
2624 [set Bridge br0 fail-mode=standalone -- \
2625 add-port br0 p1 trunks=10,12 -- \
2626 add-port br0 p2 tag=10 -- \
2627 add-port br0 p3 tag=12 \
2628 other-config:priority-tags=true -- \
2629 add-port br0 p4 tag=12 -- \
2630 add-port br0 p5 vlan_mode=native-tagged tag=10 -- \
2631 add-port br0 p6 vlan_mode=native-tagged tag=10 trunks=10,12 -- \
2632 add-port br0 p7 vlan_mode=native-untagged tag=12 -- \
2633 add-port br0 p8 vlan_mode=native-untagged tag=12 trunks=10,12 \
2634 other-config:priority-tags=true -- \
2635 set Interface p1 type=dummy -- \
2636 set Interface p2 type=dummy -- \
2637 set Interface p3 type=dummy -- \
2638 set Interface p4 type=dummy -- \
2639 set Interface p5 type=dummy -- \
2640 set Interface p6 type=dummy -- \
2641 set Interface p7 type=dummy -- \
2642 set Interface p8 type=dummy --])
2644 dnl Each of these specifies an in_port by number, a VLAN VID (or "none"),
2645 dnl a VLAN PCP (used if the VID isn't "none") and the expected set of datapath
2651 "100 10 0 1,5,6,7,8,pop_vlan,2" \
2652 "100 10 1 1,5,6,7,8,pop_vlan,2" \
2655 "100 12 0 1,5,6,pop_vlan,3,4,7,8" \
2656 "100 12 1 1,5,6,pop_vlan,4,7,push_vlan(vid=0,pcp=1),3,8" \
2660 "1 10 0 5,6,7,8,100,pop_vlan,2" \
2661 "1 10 1 5,6,7,8,100,pop_vlan,2" \
2664 "1 12 0 5,6,100,pop_vlan,3,4,7,8" \
2665 "1 12 1 5,6,100,pop_vlan,4,7,push_vlan(vid=0,pcp=1),3,8" \
2666 "2 none 0 push_vlan(vid=10,pcp=0),1,5,6,7,8,100" \
2667 "2 0 0 pop_vlan,push_vlan(vid=10,pcp=0),1,5,6,7,8,100" \
2668 "2 0 1 pop_vlan,push_vlan(vid=10,pcp=1),1,5,6,7,8,100" \
2675 "3 none 0 4,7,8,push_vlan(vid=12,pcp=0),1,5,6,100" \
2676 "3 0 0 pop_vlan,4,7,8,push_vlan(vid=12,pcp=0),1,5,6,100" \
2677 "3 0 1 8,pop_vlan,4,7,push_vlan(vid=12,pcp=1),1,5,6,100" \
2684 "4 none 0 3,7,8,push_vlan(vid=12,pcp=0),1,5,6,100" \
2685 "4 0 0 pop_vlan,3,7,8,push_vlan(vid=12,pcp=0),1,5,6,100" \
2686 "4 0 1 3,8,pop_vlan,7,push_vlan(vid=12,pcp=1),1,5,6,100" \
2693 "5 none 0 2,push_vlan(vid=10,pcp=0),1,6,7,8,100" \
2694 "5 0 0 pop_vlan,2,push_vlan(vid=10,pcp=0),1,6,7,8,100" \
2695 "5 0 1 pop_vlan,2,push_vlan(vid=10,pcp=1),1,6,7,8,100" \
2696 "5 10 0 1,6,7,8,100,pop_vlan,2" \
2697 "5 10 1 1,6,7,8,100,pop_vlan,2" \
2700 "5 12 0 1,6,100,pop_vlan,3,4,7,8" \
2701 "5 12 1 1,6,100,pop_vlan,4,7,push_vlan(vid=0,pcp=1),3,8" \
2702 "6 none 0 2,push_vlan(vid=10,pcp=0),1,5,7,8,100" \
2703 "6 0 0 pop_vlan,2,push_vlan(vid=10,pcp=0),1,5,7,8,100" \
2704 "6 0 1 pop_vlan,2,push_vlan(vid=10,pcp=1),1,5,7,8,100" \
2705 "6 10 0 1,5,7,8,100,pop_vlan,2" \
2706 "6 10 1 1,5,7,8,100,pop_vlan,2" \
2709 "6 12 0 1,5,100,pop_vlan,3,4,7,8" \
2710 "6 12 1 1,5,100,pop_vlan,4,7,push_vlan(vid=0,pcp=1),3,8" \
2711 "7 none 0 3,4,8,push_vlan(vid=12,pcp=0),1,5,6,100" \
2712 "7 0 0 pop_vlan,3,4,8,push_vlan(vid=12,pcp=0),1,5,6,100" \
2713 "7 0 1 3,8,pop_vlan,4,push_vlan(vid=12,pcp=1),1,5,6,100" \
2714 "7 10 0 1,5,6,8,100,pop_vlan,2" \
2715 "7 10 1 1,5,6,8,100,pop_vlan,2" \
2718 "7 12 0 1,5,6,100,pop_vlan,3,4,8" \
2719 "7 12 1 1,5,6,100,pop_vlan,4,push_vlan(vid=0,pcp=1),3,8" \
2720 "8 none 0 3,4,7,push_vlan(vid=12,pcp=0),1,5,6,100" \
2721 "8 0 0 pop_vlan,3,4,7,push_vlan(vid=12,pcp=0),1,5,6,100" \
2722 "8 0 1 3,pop_vlan,4,7,push_vlan(vid=12,pcp=1),1,5,6,100" \
2723 "8 10 0 1,5,6,7,100,pop_vlan,2" \
2724 "8 10 1 1,5,6,7,100,pop_vlan,2" \
2727 "8 12 0 1,5,6,100,pop_vlan,3,4,7" \
2728 "8 12 1 1,5,6,100,pop_vlan,4,7,push_vlan(vid=0,pcp=1),3"
2736 if test $vlan = none; then
2737 flow="in_port($in_port),eth(src=50:54:00:00:00:01,dst=ff:ff:ff:ff:ff:ff),eth_type(0xabcd)"
2739 flow="in_port($in_port),eth(src=50:54:00:00:00:01,dst=ff:ff:ff:ff:ff:ff),eth_type(0x8100),vlan(vid=$vlan,pcp=$pcp),encap(eth_type(0xabcd))"
2742 echo "----------------------------------------------------------------------"
2743 echo "in_port=$in_port vlan=$vlan pcp=$pcp"
2745 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy "$flow"], [0], [stdout])
2746 actual=`tail -1 stdout | sed 's/Datapath actions: //'`
2748 AT_CHECK([ovs-dpctl normalize-actions "$flow" "$expected"], [0], [stdout])
2750 AT_CHECK([ovs-dpctl normalize-actions "$flow" "$actual"], [0], [expout])
2756 AT_SETUP([ofproto-dpif - MPLS handling])
2757 OVS_VSWITCHD_START([dnl
2758 add-port br0 p1 -- set Interface p1 type=dummy
2760 ON_EXIT([kill `cat ovs-ofctl.pid`])
2762 AT_CAPTURE_FILE([ofctl_monitor.log])
2763 AT_DATA([flows.txt], [dnl
2764 dl_src=40:44:44:44:00:00 actions=push_mpls:0x8847,controller
2765 dl_src=40:44:44:44:00:01,mpls actions=push_mpls:0x8847,controller
2766 dl_src=40:44:44:44:00:02,mpls actions=push_mpls:0x8848,controller
2768 AT_CHECK([ovs-ofctl --protocols=OpenFlow12 add-flows br0 flows.txt])
2770 dnl In this test, we push an MPLS tag to an ethernet packet.
2771 AT_CHECK([ovs-ofctl --protocols=OpenFlow12 monitor br0 65534 -m -P nxm --detach --pidfile 2> ofctl_monitor.log])
2774 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:00:00,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no)'
2776 OVS_WAIT_UNTIL([test `grep OFPT_PACKET_IN ofctl_monitor.log | wc -l` -ge 3])
2777 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2779 AT_CHECK([cat ofctl_monitor.log | ofctl_strip], [0], [dnl
2780 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
2781 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:00:00,dl_dst=50:54:00:00:00:07,mpls_label=0,mpls_tc=0,mpls_ttl=64,mpls_bos=1
2782 00000000 50 54 00 00 00 07 40 44-44 44 00 00 88 47 00 00
2783 00000010 01 40 45 00 00 28 00 00-00 00 40 06 f9 7c c0 a8
2784 00000020 00 01 c0 a8 00 02 00 00-00 00 00 00 00 00 00 00
2785 00000030 00 00 50 00 00 00 00 00-00 00 00 00 00 00 00 00
2787 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
2788 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:00:00,dl_dst=50:54:00:00:00:07,mpls_label=0,mpls_tc=0,mpls_ttl=64,mpls_bos=1
2789 00000000 50 54 00 00 00 07 40 44-44 44 00 00 88 47 00 00
2790 00000010 01 40 45 00 00 28 00 00-00 00 40 06 f9 7c c0 a8
2791 00000020 00 01 c0 a8 00 02 00 00-00 00 00 00 00 00 00 00
2792 00000030 00 00 50 00 00 00 00 00-00 00 00 00 00 00 00 00
2794 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
2795 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:00:00,dl_dst=50:54:00:00:00:07,mpls_label=0,mpls_tc=0,mpls_ttl=64,mpls_bos=1
2796 00000000 50 54 00 00 00 07 40 44-44 44 00 00 88 47 00 00
2797 00000010 01 40 45 00 00 28 00 00-00 00 40 06 f9 7c c0 a8
2798 00000020 00 01 c0 a8 00 02 00 00-00 00 00 00 00 00 00 00
2799 00000030 00 00 50 00 00 00 00 00-00 00 00 00 00 00 00 00
2802 dnl In this test, we push an MPLS tag to an MPLS packet. The LSE should be
2803 dnl copied exactly, except for the BOS bit.
2804 AT_CHECK([ovs-ofctl --protocols=OpenFlow12 monitor br0 65534 -m -P nxm --detach --pidfile 2> ofctl_monitor.log])
2807 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:00:01,dst=50:54:00:00:00:07),eth_type(0x8847),mpls(label=10,tc=0,ttl=64,bos=1)'
2809 OVS_WAIT_UNTIL([test `grep OFPT_PACKET_IN ofctl_monitor.log | wc -l` -ge 3])
2810 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2812 AT_CHECK([cat ofctl_monitor.log | ofctl_strip], [0], [dnl
2813 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
2814 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:00:01,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=0,mpls_lse1=41280
2815 00000000 50 54 00 00 00 07 40 44-44 44 00 01 88 47 00 00
2816 00000010 a0 40 00 00 a1 40 00 00-00 00 00 00 00 00 00 00
2817 00000020 00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00
2818 00000030 00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00
2820 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
2821 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:00:01,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=0,mpls_lse1=41280
2822 00000000 50 54 00 00 00 07 40 44-44 44 00 01 88 47 00 00
2823 00000010 a0 40 00 00 a1 40 00 00-00 00 00 00 00 00 00 00
2824 00000020 00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00
2825 00000030 00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00
2827 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
2828 mpls,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:00:01,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=0,mpls_lse1=41280
2829 00000000 50 54 00 00 00 07 40 44-44 44 00 01 88 47 00 00
2830 00000010 a0 40 00 00 a1 40 00 00-00 00 00 00 00 00 00 00
2831 00000020 00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00
2832 00000030 00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00
2835 dnl In this test, we push an MPLS tag to an MPLS packet. The LSE should be
2836 dnl copied exactly, except for the BOS bit. The ethertype should be updated
2837 dnl to the MPLS ethertype of the MPLS push action which differs to that
2838 dnl of the input packet.
2839 AT_CHECK([ovs-ofctl --protocols=OpenFlow12 monitor br0 65534 -m -P nxm --detach --pidfile 2> ofctl_monitor.log])
2842 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:00:02,dst=50:54:00:00:00:07),eth_type(0x8847),mpls(label=10,tc=0,ttl=64,bos=1)'
2844 OVS_WAIT_UNTIL([test `grep OFPT_PACKET_IN ofctl_monitor.log | wc -l` -ge 3])
2845 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
2847 AT_CHECK([cat ofctl_monitor.log | ofctl_strip], [0], [dnl
2848 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
2849 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:00:02,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=0,mpls_lse1=41280
2850 00000000 50 54 00 00 00 07 40 44-44 44 00 02 88 48 00 00
2851 00000010 a0 40 00 00 a1 40 00 00-00 00 00 00 00 00 00 00
2852 00000020 00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00
2853 00000030 00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00
2855 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
2856 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:00:02,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=0,mpls_lse1=41280
2857 00000000 50 54 00 00 00 07 40 44-44 44 00 02 88 48 00 00
2858 00000010 a0 40 00 00 a1 40 00 00-00 00 00 00 00 00 00 00
2859 00000020 00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00
2860 00000030 00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00
2862 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
2863 mplsm,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=40:44:44:44:00:02,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=0,mpls_lse1=41280
2864 00000000 50 54 00 00 00 07 40 44-44 44 00 02 88 48 00 00
2865 00000010 a0 40 00 00 a1 40 00 00-00 00 00 00 00 00 00 00
2866 00000020 00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00
2867 00000030 00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00
2873 AT_SETUP([ofproto-dpif - VLAN+MPLS handling])
2874 OVS_VSWITCHD_START([dnl
2875 add-port br0 p1 -- set Interface p1 type=dummy
2877 ON_EXIT([kill `cat ovs-ofctl.pid`])
2879 AT_CAPTURE_FILE([ofctl_monitor.log])
2880 AT_DATA([flows.txt], [dnl
2881 cookie=0xa dl_src=40:44:44:44:54:50 actions=push_mpls:0x8847,load:10->OXM_OF_MPLS_LABEL[[]],push_vlan:0x8100,set_vlan_vid:99,set_vlan_pcp:1,controller
2882 cookie=0xa dl_src=40:44:44:44:54:51 actions=push_mpls:0x8847,load:10->OXM_OF_MPLS_LABEL[[]],push_vlan:0x8100,set_vlan_vid:99,set_vlan_pcp:1,controller
2883 cookie=0xa dl_src=40:44:44:44:54:52 actions=push_mpls:0x8847,load:10->OXM_OF_MPLS_LABEL[[]],push_vlan:0x8100,load:99->OXM_OF_VLAN_VID[[]],set_vlan_pcp:1,controller
2884 cookie=0xa dl_src=40:44:44:44:54:53 actions=push_mpls:0x8847,load:10->OXM_OF_MPLS_LABEL[[]],push_vlan:0x8100,load:99->OXM_OF_VLAN_VID[[]],set_vlan_pcp:1,controller
2885 cookie=0xa dl_src=40:44:44:44:54:54 actions=push_vlan:0x8100,set_vlan_vid:99,set_vlan_pcp:1,push_mpls:0x8847,load:10->OXM_OF_MPLS_LABEL[[]],controller
2886 cookie=0xa dl_src=40:44:44:44:54:55 actions=push_vlan:0x8100,set_vlan_vid:99,set_vlan_pcp:1,push_mpls:0x8847,load:10->OXM_OF_MPLS_LABEL[[]],controller
2887 cookie=0xa dl_src=40:44:44:44:54:56 actions=push_vlan:0x8100,load:99->OXM_OF_VLAN_VID[[]],set_vlan_pcp:1,push_mpls:0x8847,load:10->OXM_OF_MPLS_LABEL[[]],controller
2888 cookie=0xa dl_src=40:44:44:44:54:57 actions=push_vlan:0x8100,load:99->OXM_OF_VLAN_VID[[]],set_vlan_pcp:1,push_mpls:0x8847,load:10->OXM_OF_MPLS_LABEL[[]],controller
2889 cookie=0xa dl_src=40:44:44:44:54:58,vlan_tci=0x1000/0x1000 actions=load:99->OXM_OF_VLAN_VID[[]],set_vlan_pcp:1,push_mpls:0x8847,load:10->OXM_OF_MPLS_LABEL[[]],controller
2890 cookie=0xa dl_src=40:44:44:44:54:59,vlan_tci=0x1000/0x1000 actions=push_mpls:0x8847,load:10->OXM_OF_MPLS_LABEL[[]],set_vlan_pcp:1,load:99->OXM_OF_VLAN_VID[[]],controller
2892 AT_CHECK([ovs-ofctl --protocols=OpenFlow12 add-flows br0 flows.txt])
2894 dnl Modified MPLS controller action.
2895 dnl In this test, we push the MPLS tag before pushing a VLAN tag, so we see
2896 dnl both of these in the final flow
2897 AT_CHECK([ovs-ofctl --protocols=OpenFlow12 monitor br0 65534 -m -P nxm --detach --pidfile 2> ofctl_monitor.log])
2900 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:54:50,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no)'
2902 OVS_WAIT_UNTIL([test `grep OFPT_PACKET_IN ofctl_monitor.log | wc -l` -ge 3])
2903 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2905 AT_CHECK([cat ofctl_monitor.log | ofctl_strip], [0], [dnl
2906 OFPT_PACKET_IN (OF1.2): total_len=68 in_port=1 (via action) data_len=68 (unbuffered)
2907 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:50,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
2908 00000000 50 54 00 00 00 07 40 44-44 44 54 50 81 00 20 63
2909 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
2910 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
2911 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
2912 00000040 00 00 00 00
2914 OFPT_PACKET_IN (OF1.2): total_len=68 in_port=1 (via action) data_len=68 (unbuffered)
2915 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:50,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
2916 00000000 50 54 00 00 00 07 40 44-44 44 54 50 81 00 20 63
2917 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
2918 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
2919 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
2920 00000040 00 00 00 00
2922 OFPT_PACKET_IN (OF1.2): total_len=68 in_port=1 (via action) data_len=68 (unbuffered)
2923 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:50,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
2924 00000000 50 54 00 00 00 07 40 44-44 44 54 50 81 00 20 63
2925 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
2926 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
2927 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
2928 00000040 00 00 00 00
2931 dnl Modified MPLS controller action.
2932 dnl In this test, the input packet in vlan-tagged, which should be stripped
2933 dnl before we push the MPLS and VLAN tags.
2934 AT_CHECK([ovs-ofctl --protocols=OpenFlow12 monitor br0 65534 -m -P nxm --detach --pidfile 2> ofctl_monitor.log])
2937 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:54:51,dst=50:54:00:00:00:07),eth_type(0x8100),vlan(vid=88,pcp=7),encap(eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no))'
2939 OVS_WAIT_UNTIL([test `grep OFPT_PACKET_IN ofctl_monitor.log | wc -l` -ge 3])
2940 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2942 AT_CHECK([cat ofctl_monitor.log | ofctl_strip], [0], [dnl
2943 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
2944 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:51,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
2945 00000000 50 54 00 00 00 07 40 44-44 44 54 51 81 00 20 63
2946 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
2947 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
2948 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
2950 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
2951 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:51,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
2952 00000000 50 54 00 00 00 07 40 44-44 44 54 51 81 00 20 63
2953 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
2954 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
2955 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
2957 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
2958 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:51,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
2959 00000000 50 54 00 00 00 07 40 44-44 44 54 51 81 00 20 63
2960 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
2961 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
2962 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
2965 dnl Modified MPLS controller action.
2966 dnl In this test, we push the MPLS tag before pushing a VLAN tag, so we see
2967 dnl both of these in the final flow
2968 AT_CHECK([ovs-ofctl --protocols=OpenFlow12 monitor br0 65534 -m -P nxm --detach --pidfile 2> ofctl_monitor.log])
2971 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:54:52,dst=52:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no)'
2973 OVS_WAIT_UNTIL([test `grep OFPT_PACKET_IN ofctl_monitor.log | wc -l` -ge 3])
2974 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
2976 AT_CHECK([cat ofctl_monitor.log | ofctl_strip], [0], [dnl
2977 OFPT_PACKET_IN (OF1.2): total_len=68 in_port=1 (via action) data_len=68 (unbuffered)
2978 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:52,dl_dst=52:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
2979 00000000 52 54 00 00 00 07 40 44-44 44 54 52 81 00 20 63
2980 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
2981 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
2982 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
2983 00000040 00 00 00 00
2985 OFPT_PACKET_IN (OF1.2): total_len=68 in_port=1 (via action) data_len=68 (unbuffered)
2986 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:52,dl_dst=52:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
2987 00000000 52 54 00 00 00 07 40 44-44 44 54 52 81 00 20 63
2988 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
2989 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
2990 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
2991 00000040 00 00 00 00
2993 OFPT_PACKET_IN (OF1.2): total_len=68 in_port=1 (via action) data_len=68 (unbuffered)
2994 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:52,dl_dst=52:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
2995 00000000 52 54 00 00 00 07 40 44-44 44 54 52 81 00 20 63
2996 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
2997 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
2998 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
2999 00000040 00 00 00 00
3002 dnl Modified MPLS controller action.
3003 dnl In this test, the input packet in vlan-tagged, which should be stripped
3004 dnl before we push the MPLS and VLAN tags.
3005 AT_CHECK([ovs-ofctl --protocols=OpenFlow12 monitor br0 65534 -m -P nxm --detach --pidfile 2> ofctl_monitor.log])
3008 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:54:53,dst=50:54:00:00:00:07),eth_type(0x8100),vlan(vid=88,pcp=7),encap(eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no))'
3010 OVS_WAIT_UNTIL([test `grep OFPT_PACKET_IN ofctl_monitor.log | wc -l` -ge 3])
3011 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
3013 AT_CHECK([cat ofctl_monitor.log | ofctl_strip], [0], [dnl
3014 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
3015 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:53,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3016 00000000 50 54 00 00 00 07 40 44-44 44 54 53 81 00 20 63
3017 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3018 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3019 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3021 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
3022 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:53,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3023 00000000 50 54 00 00 00 07 40 44-44 44 54 53 81 00 20 63
3024 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3025 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3026 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3028 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
3029 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:53,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3030 00000000 50 54 00 00 00 07 40 44-44 44 54 53 81 00 20 63
3031 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3032 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3033 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3036 dnl Modified MPLS controller action.
3037 dnl In this test, we push the VLAN tag before pushing a MPLS tag, but these
3038 dnl actions are reordered, so we see both of these in the final flow.
3039 AT_CHECK([ovs-ofctl --protocols=OpenFlow12 monitor br0 65534 -m -P nxm --detach --pidfile 2> ofctl_monitor.log])
3042 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:54:54,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no)'
3044 OVS_WAIT_UNTIL([test `grep OFPT_PACKET_IN ofctl_monitor.log | wc -l` -ge 3])
3045 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
3047 AT_CHECK([cat ofctl_monitor.log | ofctl_strip], [0], [dnl
3048 OFPT_PACKET_IN (OF1.2): total_len=68 in_port=1 (via action) data_len=68 (unbuffered)
3049 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:54,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3050 00000000 50 54 00 00 00 07 40 44-44 44 54 54 81 00 20 63
3051 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3052 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3053 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3054 00000040 00 00 00 00
3056 OFPT_PACKET_IN (OF1.2): total_len=68 in_port=1 (via action) data_len=68 (unbuffered)
3057 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:54,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3058 00000000 50 54 00 00 00 07 40 44-44 44 54 54 81 00 20 63
3059 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3060 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3061 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3062 00000040 00 00 00 00
3064 OFPT_PACKET_IN (OF1.2): total_len=68 in_port=1 (via action) data_len=68 (unbuffered)
3065 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:54,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3066 00000000 50 54 00 00 00 07 40 44-44 44 54 54 81 00 20 63
3067 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3068 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3069 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3070 00000040 00 00 00 00
3073 dnl Modified MPLS controller action.
3074 dnl In this test, the input packet in vlan-tagged, which should be stripped
3075 dnl before we push the MPLS and VLAN tags.
3076 AT_CHECK([ovs-ofctl --protocols=OpenFlow12 monitor br0 65534 -m -P nxm --detach --pidfile 2> ofctl_monitor.log])
3079 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:54:55,dst=50:54:00:00:00:07),eth_type(0x8100),vlan(vid=88,pcp=7),encap(eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no))'
3081 OVS_WAIT_UNTIL([test `grep OFPT_PACKET_IN ofctl_monitor.log | wc -l` -ge 3])
3082 OVS_APP_EXIT_AND_WAIT([ovs-ofctl])
3084 AT_CHECK([cat ofctl_monitor.log | ofctl_strip], [0], [dnl
3085 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
3086 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:55,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3087 00000000 50 54 00 00 00 07 40 44-44 44 54 55 81 00 20 63
3088 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3089 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3090 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3092 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
3093 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:55,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3094 00000000 50 54 00 00 00 07 40 44-44 44 54 55 81 00 20 63
3095 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3096 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3097 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3099 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
3100 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:55,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3101 00000000 50 54 00 00 00 07 40 44-44 44 54 55 81 00 20 63
3102 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3103 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3104 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3107 dnl Modified MPLS controller action.
3108 dnl In this test, we push the VLAN tag before pushing a MPLS tag, but these
3109 dnl actions are reordered, so we see both of these in the final flow.
3110 AT_CHECK([ovs-ofctl --protocols=OpenFlow12 monitor br0 65534 -m -P nxm --detach --pidfile 2> ofctl_monitor.log])
3113 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:54:56,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no)'
3115 OVS_WAIT_UNTIL([test `grep OFPT_PACKET_IN ofctl_monitor.log | wc -l` -ge 3])
3116 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
3118 AT_CHECK([cat ofctl_monitor.log | ofctl_strip], [0], [dnl
3119 OFPT_PACKET_IN (OF1.2): total_len=68 in_port=1 (via action) data_len=68 (unbuffered)
3120 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:56,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3121 00000000 50 54 00 00 00 07 40 44-44 44 54 56 81 00 20 63
3122 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3123 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3124 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3125 00000040 00 00 00 00
3127 OFPT_PACKET_IN (OF1.2): total_len=68 in_port=1 (via action) data_len=68 (unbuffered)
3128 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:56,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3129 00000000 50 54 00 00 00 07 40 44-44 44 54 56 81 00 20 63
3130 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3131 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3132 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3133 00000040 00 00 00 00
3135 OFPT_PACKET_IN (OF1.2): total_len=68 in_port=1 (via action) data_len=68 (unbuffered)
3136 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:56,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3137 00000000 50 54 00 00 00 07 40 44-44 44 54 56 81 00 20 63
3138 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3139 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3140 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3141 00000040 00 00 00 00
3144 dnl Modified MPLS controller action.
3145 dnl In this test, the input packet in vlan-tagged, which should be stripped
3146 dnl before we push the MPLS and VLAN tags.
3147 AT_CHECK([ovs-ofctl --protocols=OpenFlow12 monitor br0 -m 65534 -P nxm --detach --pidfile 2> ofctl_monitor.log])
3150 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:54:57,dst=50:54:00:00:00:07),eth_type(0x8100),vlan(vid=88,pcp=7),encap(eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no))'
3152 OVS_WAIT_UNTIL([test `grep OFPT_PACKET_IN ofctl_monitor.log | wc -l` -ge 3])
3153 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
3155 AT_CHECK([cat ofctl_monitor.log | ofctl_strip], [0], [dnl
3156 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
3157 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:57,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3158 00000000 50 54 00 00 00 07 40 44-44 44 54 57 81 00 20 63
3159 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3160 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3161 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3163 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
3164 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:57,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3165 00000000 50 54 00 00 00 07 40 44-44 44 54 57 81 00 20 63
3166 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3167 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3168 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3170 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
3171 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:57,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3172 00000000 50 54 00 00 00 07 40 44-44 44 54 57 81 00 20 63
3173 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3174 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3175 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3178 dnl Modified MPLS controller action.
3179 dnl In this test, the input packet in vlan-tagged, which should be stripped
3180 dnl before we push the MPLS and VLAN tags.
3181 AT_CHECK([ovs-ofctl --protocols=OpenFlow12 monitor br0 65534 -m -P nxm --detach --pidfile 2> ofctl_monitor.log])
3184 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:54:58,dst=50:54:00:00:00:07),eth_type(0x8100),vlan(vid=88,pcp=7),encap(eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no))'
3186 OVS_WAIT_UNTIL([test `grep OFPT_PACKET_IN ofctl_monitor.log | wc -l` -ge 3])
3187 OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
3189 AT_CHECK([cat ofctl_monitor.log | ofctl_strip], [0], [dnl
3190 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
3191 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:58,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3192 00000000 50 54 00 00 00 07 40 44-44 44 54 58 81 00 20 63
3193 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3194 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3195 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3197 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
3198 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:58,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3199 00000000 50 54 00 00 00 07 40 44-44 44 54 58 81 00 20 63
3200 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3201 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3202 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3204 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
3205 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:58,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3206 00000000 50 54 00 00 00 07 40 44-44 44 54 58 81 00 20 63
3207 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3208 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3209 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3212 dnl Modified MPLS controller action.
3213 dnl In this test, the input packet in vlan-tagged, which should be modified
3214 dnl before we push MPLS and VLAN tags.
3215 AT_CHECK([ovs-ofctl --protocols=OpenFlow12 monitor br0 65534 -m -P nxm --detach --pidfile 2> ofctl_monitor.log])
3218 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=40:44:44:44:54:59,dst=50:54:00:00:00:07),eth_type(0x8100),vlan(vid=88,pcp=7),encap(eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no))'
3220 OVS_WAIT_UNTIL([test `grep OFPT_PACKET_IN ofctl_monitor.log | wc -l` -ge 3])
3221 ovs-appctl -t ovs-ofctl exit
3223 AT_CHECK([cat ofctl_monitor.log | ofctl_strip], [0], [dnl
3224 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
3225 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:59,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3226 00000000 50 54 00 00 00 07 40 44-44 44 54 59 81 00 20 63
3227 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3228 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3229 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3231 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
3232 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:59,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3233 00000000 50 54 00 00 00 07 40 44-44 44 54 59 81 00 20 63
3234 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3235 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3236 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3238 OFPT_PACKET_IN (OF1.2): total_len=64 in_port=1 (via action) data_len=64 (unbuffered)
3239 mpls,metadata=0,in_port=0,dl_vlan=99,dl_vlan_pcp=1,dl_src=40:44:44:44:54:59,dl_dst=50:54:00:00:00:07,mpls_label=10,mpls_tc=0,mpls_ttl=64,mpls_bos=1
3240 00000000 50 54 00 00 00 07 40 44-44 44 54 59 81 00 20 63
3241 00000010 88 47 00 00 a1 40 45 00-00 28 00 00 00 00 40 06
3242 00000020 f9 7c c0 a8 00 01 c0 a8-00 02 00 00 00 00 00 00
3243 00000030 00 00 00 00 00 00 50 00-00 00 00 00 00 00 00 00
3246 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
3247 AT_CHECK([ovs-appctl revalidator/wait], [0], [ignore])
3248 AT_CHECK([ovs-ofctl --protocols=OpenFlow12 dump-flows br0 | ofctl_strip | sort], [0], [dnl
3249 cookie=0xa, n_packets=3, n_bytes=180, dl_src=40:44:44:44:54:50 actions=push_mpls:0x8847,load:0xa->OXM_OF_MPLS_LABEL[[]],push_vlan:0x8100,set_field:4195->vlan_vid,set_field:1->vlan_pcp,CONTROLLER:65535
3250 cookie=0xa, n_packets=3, n_bytes=180, dl_src=40:44:44:44:54:51 actions=push_mpls:0x8847,load:0xa->OXM_OF_MPLS_LABEL[[]],push_vlan:0x8100,set_field:4195->vlan_vid,set_field:1->vlan_pcp,CONTROLLER:65535
3251 cookie=0xa, n_packets=3, n_bytes=180, dl_src=40:44:44:44:54:52 actions=push_mpls:0x8847,load:0xa->OXM_OF_MPLS_LABEL[[]],push_vlan:0x8100,load:0x63->OXM_OF_VLAN_VID[[]],set_field:1->vlan_pcp,CONTROLLER:65535
3252 cookie=0xa, n_packets=3, n_bytes=180, dl_src=40:44:44:44:54:53 actions=push_mpls:0x8847,load:0xa->OXM_OF_MPLS_LABEL[[]],push_vlan:0x8100,load:0x63->OXM_OF_VLAN_VID[[]],set_field:1->vlan_pcp,CONTROLLER:65535
3253 cookie=0xa, n_packets=3, n_bytes=180, dl_src=40:44:44:44:54:54 actions=push_vlan:0x8100,set_field:4195->vlan_vid,set_field:1->vlan_pcp,push_mpls:0x8847,load:0xa->OXM_OF_MPLS_LABEL[[]],CONTROLLER:65535
3254 cookie=0xa, n_packets=3, n_bytes=180, dl_src=40:44:44:44:54:55 actions=push_vlan:0x8100,set_field:4195->vlan_vid,set_field:1->vlan_pcp,push_mpls:0x8847,load:0xa->OXM_OF_MPLS_LABEL[[]],CONTROLLER:65535
3255 cookie=0xa, n_packets=3, n_bytes=180, dl_src=40:44:44:44:54:56 actions=push_vlan:0x8100,load:0x63->OXM_OF_VLAN_VID[[]],set_field:1->vlan_pcp,push_mpls:0x8847,load:0xa->OXM_OF_MPLS_LABEL[[]],CONTROLLER:65535
3256 cookie=0xa, n_packets=3, n_bytes=180, dl_src=40:44:44:44:54:57 actions=push_vlan:0x8100,load:0x63->OXM_OF_VLAN_VID[[]],set_field:1->vlan_pcp,push_mpls:0x8847,load:0xa->OXM_OF_MPLS_LABEL[[]],CONTROLLER:65535
3257 cookie=0xa, n_packets=3, n_bytes=180, vlan_tci=0x1000/0x1000,dl_src=40:44:44:44:54:58 actions=load:0x63->OXM_OF_VLAN_VID[[]],set_field:1->vlan_pcp,push_mpls:0x8847,load:0xa->OXM_OF_MPLS_LABEL[[]],CONTROLLER:65535
3258 cookie=0xa, n_packets=3, n_bytes=180, vlan_tci=0x1000/0x1000,dl_src=40:44:44:44:54:59 actions=push_mpls:0x8847,load:0xa->OXM_OF_MPLS_LABEL[[]],set_field:1->vlan_pcp,load:0x63->OXM_OF_VLAN_VID[[]],CONTROLLER:65535
3259 OFPST_FLOW reply (OF1.2):
3265 AT_SETUP([ofproto-dpif - fragment handling])
3267 ADD_OF_PORTS([br0], [1], [2], [3], [4], [5], [6], [90])
3268 AT_DATA([flows.txt], [dnl
3269 priority=75 tcp ip_frag=no tp_dst=80 actions=output:1
3270 priority=75 tcp ip_frag=first tp_dst=80 actions=output:2
3271 priority=75 tcp ip_frag=later tp_dst=80 actions=output:3
3272 priority=50 tcp ip_frag=no actions=output:4
3273 priority=50 tcp ip_frag=first actions=output:5
3274 priority=50 tcp ip_frag=later actions=output:6
3276 AT_CHECK([ovs-ofctl replace-flows br0 flows.txt])
3278 base_flow="in_port(90),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=128"
3279 no_flow="$base_flow,frag=no),tcp(src=12345,dst=80)"
3280 first_flow="$base_flow,frag=first),tcp(src=12345,dst=80)"
3281 later_flow="$base_flow,frag=later)"
3283 # mode no first later
3286 'drop 1 drop drop' \
3295 AT_CHECK([ovs-ofctl set-frags br0 $mode])
3296 for type in no first later; do
3297 eval flow=\$${type}_flow exp_output=\$$type
3298 printf "\n%s\n" "----$mode $type-----"
3299 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy "$flow"], [0], [stdout])
3301 if test $mode = drop && test $type != no; then
3302 echo 'Packets dropped because they are IP fragments and the fragment handling mode is "drop".' >> expout
3304 echo "Datapath actions: $exp_output" >> expout
3305 AT_CHECK([grep 'IP fragments' stdout; tail -1 stdout], [0], [expout])
3311 AT_SETUP([ofproto-dpif - exit])
3313 ADD_OF_PORTS([br0], [1], [2], [3], [10], [11], [12], [13], [14])
3314 AT_DATA([flows.txt], [dnl
3315 in_port=1 actions=output:10,exit,output:11
3316 in_port=2 actions=output:12,resubmit:1,output:12
3317 in_port=3 actions=output:13,resubmit:2,output:14
3319 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
3320 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)'], [0], [stdout])
3321 AT_CHECK([tail -1 stdout], [0],
3322 [Datapath actions: 10
3324 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy 'in_port(2),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)'], [0], [stdout])
3325 AT_CHECK([tail -1 stdout], [0],
3326 [Datapath actions: 12,10
3328 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy 'in_port(3),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)'], [0], [stdout])
3329 AT_CHECK([tail -1 stdout], [0],
3330 [Datapath actions: 13,12,10
3336 AT_SETUP([ofproto-dpif - mirroring, select_all])
3338 ADD_OF_PORTS([br0], 1, 2, 3)
3340 set Bridge br0 mirrors=@m --\
3341 --id=@p3 get Port p3 --\
3342 --id=@m create Mirror name=mymirror select_all=true output_port=@p3
3344 AT_DATA([flows.txt], [dnl
3345 in_port=1 actions=output:2
3346 in_port=2 actions=output:1
3348 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
3350 flow="in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)"
3351 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy "$flow"], [0], [stdout])
3352 AT_CHECK_UNQUOTED([tail -1 stdout], [0],
3353 [Datapath actions: 2,3
3356 flow="in_port(2),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)"
3357 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy "$flow"], [0], [stdout])
3358 AT_CHECK_UNQUOTED([tail -1 stdout], [0],
3359 [Datapath actions: 1,3
3366 AT_SETUP([ofproto-dpif - mirroring, select_src])
3368 ADD_OF_PORTS([br0], 1, 2, 3)
3370 set Bridge br0 mirrors=@m --\
3371 --id=@p1 get Port p1 -- --id=@p3 get Port p3 --\
3372 --id=@m create Mirror name=mymirror select_src_port=@p1 output_port=@p3
3374 AT_DATA([flows.txt], [dnl
3375 in_port=1 actions=output:2
3376 in_port=2 actions=output:1
3378 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
3380 flow="in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)"
3381 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy "$flow"], [0], [stdout])
3382 AT_CHECK_UNQUOTED([tail -1 stdout], [0],
3383 [Datapath actions: 2,3
3386 flow="in_port(2),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)"
3387 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy "$flow"], [0], [stdout])
3388 AT_CHECK_UNQUOTED([tail -1 stdout], [0],
3389 [Datapath actions: 1
3394 AT_SETUP([ofproto-dpif - mirroring, OFPP_NONE ingress port])
3396 ADD_OF_PORTS([br0], 1, 2)
3398 set Bridge br0 mirrors=@m --\
3399 --id=@p2 get Port p2 --\
3400 --id=@m create Mirror name=mymirror select_all=true output_port=@p2
3402 AT_CHECK([ovs-ofctl add-flow br0 action=output:1])
3404 # "in_port" defaults to OFPP_NONE if it's not specified.
3405 flow="icmp,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_ttl=128,icmp_type=8,icmp_code=0"
3406 AT_CHECK([ovs-appctl ofproto/trace br0 "$flow"], [0], [stdout])
3407 AT_CHECK_UNQUOTED([tail -1 stdout], [0],
3408 [Datapath actions: 1,2
3415 AT_SETUP([ofproto-dpif - mirroring, select_dst])
3417 ADD_OF_PORTS([br0], 1, 2, 3)
3419 set Bridge br0 mirrors=@m --\
3420 --id=@p2 get Port p2 -- --id=@p3 get Port p3 --\
3421 --id=@m create Mirror name=mymirror select_dst_port=@p2 output_port=@p3
3423 AT_DATA([flows.txt], [dnl
3424 in_port=1 actions=output:2
3425 in_port=2 actions=output:1
3427 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
3429 flow="in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)"
3430 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy "$flow"], [0], [stdout])
3431 AT_CHECK_UNQUOTED([tail -1 stdout], [0],
3432 [Datapath actions: 2,3
3435 flow="in_port(2),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)"
3436 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy "$flow"], [0], [stdout])
3437 AT_CHECK_UNQUOTED([tail -1 stdout], [0],
3438 [Datapath actions: 1
3445 AT_SETUP([ofproto-dpif - mirroring, select_vlan])
3447 ADD_OF_PORTS([br0], 1, 2, 3)
3449 set Bridge br0 mirrors=@m --\
3450 --id=@p2 get Port p2 -- --id=@p3 get Port p3 --\
3451 --id=@m create Mirror name=mymirror select_all=true select_vlan=11 output_port=@p3
3453 AT_DATA([flows.txt], [dnl
3454 in_port=1, actions=output:2
3456 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
3458 flow="in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)"
3459 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy "$flow"], [0], [stdout])
3460 AT_CHECK_UNQUOTED([tail -1 stdout], [0],
3461 [Datapath actions: 2
3464 flow="in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x8100),vlan(vid=10,pcp=0),encap(eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0))"
3465 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy "$flow"], [0], [stdout])
3466 AT_CHECK_UNQUOTED([tail -1 stdout], [0],
3467 [Datapath actions: 2
3470 flow="in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x8100),vlan(vid=11,pcp=0),encap(eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0))"
3471 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy "$flow"], [0], [stdout])
3472 AT_CHECK_UNQUOTED([tail -1 stdout], [0],
3473 [Datapath actions: 2,3
3480 AT_SETUP([ofproto-dpif - mirroring, output_port])
3482 ADD_OF_PORTS([br0], 1, 2, 3)
3484 set Bridge br0 mirrors=@m --\
3485 --id=@p3 get Port p3 --\
3486 --id=@m create Mirror name=mymirror select_all=true output_port=@p3
3488 AT_DATA([flows.txt], [dnl
3489 in_port=1 actions=mod_vlan_vid:17,output:2
3490 in_port=2 actions=output:1
3492 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
3494 flow="in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)"
3495 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy "$flow"], [0], [stdout])
3496 AT_CHECK_UNQUOTED([tail -1 stdout], [0],
3497 [Datapath actions: push_vlan(vid=17,pcp=0),2,pop_vlan,3
3500 flow="in_port(2),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)"
3501 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy "$flow"], [0], [stdout])
3502 AT_CHECK_UNQUOTED([tail -1 stdout], [0],
3503 [Datapath actions: 1,3
3509 AT_SETUP([ofproto-dpif - mirroring, output_vlan])
3511 ADD_OF_PORTS([br0], 1, 2)
3513 set Bridge br0 mirrors=@m --\
3514 --id=@m create Mirror name=mymirror select_all=true output_vlan=12
3516 AT_DATA([flows.txt], [dnl
3517 in_port=1 actions=output:2
3518 in_port=2 actions=mod_vlan_vid:17,output:1
3520 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
3522 flow="in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)"
3523 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy "$flow"], [0], [stdout])
3524 actual=`tail -1 stdout | sed 's/Datapath actions: //'`
3526 expected="2,push_vlan(vid=12,pcp=0),1,2,100"
3527 AT_CHECK([ovs-dpctl normalize-actions "$flow" "$expected"], [0], [stdout])
3529 AT_CHECK([ovs-dpctl normalize-actions "$flow" "$actual"], [0], [expout])
3531 flow="in_port(2),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=128,frag=no),icmp(type=8,code=0)"
3532 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy "$flow"], [0], [stdout])
3533 actual=`tail -1 stdout | sed 's/Datapath actions: //'`
3535 expected="push_vlan(vid=17,pcp=0),1,pop_vlan,push_vlan(vid=12,pcp=0),1,2,100"
3536 AT_CHECK([ovs-dpctl normalize-actions "$flow" "$expected"], [0], [stdout])
3538 AT_CHECK([ovs-dpctl normalize-actions "$flow" "$actual"], [0], [expout])
3543 # Two testcases below are for the ofproto/trace command
3544 # The first one tests all correct syntax:
3545 # ofproto/trace [dp_name] odp_flow [-generate|packet]
3546 # ofproto/trace br_name br_flow [-generate|packet]
3547 AT_SETUP([ofproto-dpif - ofproto/trace command 1])
3548 OVS_VSWITCHD_START([set bridge br0 fail-mode=standalone])
3549 ADD_OF_PORTS([br0], 1, 2, 3)
3551 AT_DATA([flows.txt], [dnl
3552 in_port=1 actions=output:2
3553 in_port=2 actions=output:1
3555 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
3557 odp_flow="in_port(1)"
3559 # Test command: ofproto/trace odp_flow with in_port as a name.
3560 AT_CHECK([ovs-appctl ofproto/trace "$odp_flow"], [0], [stdout])
3561 AT_CHECK([tail -1 stdout], [0], [dnl
3565 odp_flow="in_port(1)"
3566 # Test command: ofproto/trace odp_flow
3567 AT_CHECK([ovs-appctl ofproto/trace "$odp_flow"], [0], [stdout])
3568 AT_CHECK([tail -1 stdout], [0], [dnl
3572 # Test command: ofproto/trace dp_name odp_flow
3573 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy "$odp_flow"], [0], [stdout])
3574 AT_CHECK([tail -1 stdout], [0], [dnl
3577 # Test commmand: ofproto/trace br_name br_flow
3578 AT_CHECK([ovs-appctl ofproto/trace br0 "$br_flow"], [0], [stdout])
3579 AT_CHECK([tail -1 stdout], [0], [dnl
3583 # Delete the inserted flows
3584 AT_CHECK([ovs-ofctl del-flows br0 "in_port=1"], [0], [stdout])
3585 AT_CHECK([ovs-ofctl del-flows br0 "in_port=2"], [0], [stdout])
3587 # This section beflow tests the [-generate] option
3588 odp_flow="in_port(3),eth(src=50:54:00:00:00:05,dst=ff:ff:ff:ff:ff:ff)"
3589 br_flow="arp,metadata=0,in_port=3,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=ff:ff:ff:ff:ff:ff"
3591 # Test command: ofproto/trace odp_flow
3592 AT_CHECK([ovs-appctl ofproto/trace "$odp_flow"], [0], [stdout])
3593 # Check for no MAC learning entry
3594 AT_CHECK_UNQUOTED([ovs-appctl fdb/show br0 | sed 's/[[0-9]]\{1,\}$/?/'], [0], [dnl
3598 # Test command: ofproto/trace br_name br_flow
3599 AT_CHECK([ovs-appctl ofproto/trace br0 "$br_flow"], [0], [stdout])
3600 # Check for no MAC learning entry
3601 AT_CHECK_UNQUOTED([ovs-appctl fdb/show br0 | sed 's/[[0-9]]\{1,\}$/?/'], [0], [dnl
3605 # Test command: ofproto/trace odp_flow -generate
3606 AT_CHECK([ovs-appctl ofproto/trace "$odp_flow" -generate], [0], [stdout])
3607 # Check for the MAC learning entry
3608 AT_CHECK_UNQUOTED([ovs-appctl fdb/show br0 | sed 's/[[0-9]]\{1,\}$/?/'], [0], [dnl
3610 3 0 50:54:00:00:00:05 ?
3613 # Test command: ofproto/trace dp_name odp_flow -generate
3614 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy \
3615 "in_port(1),eth(src=50:54:00:00:00:06,dst=50:54:00:00:00:05)" \
3616 -generate], [0], [stdout])
3617 # Check for both MAC learning entries
3618 AT_CHECK_UNQUOTED([ovs-appctl fdb/show br0 | sed 's/[[0-9]]\{1,\}$/?/'], [0], [dnl
3620 3 0 50:54:00:00:00:05 ?
3621 1 0 50:54:00:00:00:06 ?
3624 # Test command: ofproto/trace br_name br_flow -generate
3625 AT_CHECK([ovs-appctl ofproto/trace br0 \
3626 "in_port=2,dl_src=50:54:00:00:00:07,dl_dst=50:54:00:00:00:06" \
3627 -generate], [0], [stdout])
3628 # Check for both MAC learning entries.
3629 AT_CHECK_UNQUOTED([ovs-appctl fdb/show br0 | sed 's/[[0-9]]\{1,\}$/?/'], [0], [dnl
3631 3 0 50:54:00:00:00:05 ?
3632 1 0 50:54:00:00:00:06 ?
3633 2 0 50:54:00:00:00:07 ?
3636 # This section beflow tests the [packet] option
3637 # The ovs-tcpundump of packets between port1 and port2
3638 pkt1to2="50540000000250540000000108064500001C000100004001F98CC0A80001C0A800020800F7FF00000000"
3639 pkt2to1="50540000000150540000000208064500001C000100004001F98CC0A80002C0A800010800F7FF00000000"
3641 # Construct the MAC learning table
3642 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy \
3643 "in_port(1),eth(src=50:54:00:00:00:01,dst=ff:ff:ff:ff:ff:ff)" \
3644 -generate], [0], [stdout])
3646 # Construct the MAC learning table
3647 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy \
3648 "in_port(2),eth(src=50:54:00:00:00:02,dst=ff:ff:ff:ff:ff:ff)" \
3649 -generate], [0], [stdout])
3651 # Test command: ofproto/trace odp_flow packet
3652 AT_CHECK([ovs-appctl ofproto/trace \
3653 "in_port(1),skb_priority(1),skb_mark(2)" "$pkt1to2"], [0], [stdout])
3654 AT_CHECK([tail -1 stdout], [0], [dnl
3657 AT_CHECK([head -n 2 stdout], [0], [dnl
3659 Flow: pkt_mark=0x2,skb_priority=0x1,arp,metadata=0,in_port=1,vlan_tci=0x0000,dl_src=50:54:00:00:00:01,dl_dst=50:54:00:00:00:02,arp_spa=0.0.0.0,arp_tpa=0.0.0.0,arp_sha=00:00:00:00:00:00,arp_tha=00:00:00:00:00:00
3662 # Test command: ofproto/trace dp_name odp_flow packet
3663 AT_CHECK([ovs-appctl ofproto/trace ovs-dummy \
3664 "in_port(1),skb_priority(1),skb_mark(2)" "$pkt1to2"], [0], [stdout])
3665 AT_CHECK([tail -1 stdout], [0], [dnl
3668 AT_CHECK([head -n 2 stdout], [0], [dnl
3670 Flow: pkt_mark=0x2,skb_priority=0x1,arp,metadata=0,in_port=1,vlan_tci=0x0000,dl_src=50:54:00:00:00:01,dl_dst=50:54:00:00:00:02,arp_spa=0.0.0.0,arp_tpa=0.0.0.0,arp_sha=00:00:00:00:00:00,arp_tha=00:00:00:00:00:00
3673 # Test command: ofproto/trace br_name br_flow packet
3674 AT_CHECK([ovs-appctl ofproto/trace br0 \
3675 "in_port=2,skb_priority=2,pkt_mark=1" "$pkt2to1"], [0], [stdout],[stderr])
3676 AT_CHECK([tail -1 stdout], [0], [dnl
3679 AT_CHECK([head -n 2 stdout], [0], [dnl
3681 Flow: pkt_mark=0x1,skb_priority=0x2,arp,metadata=0,in_port=2,vlan_tci=0x0000,dl_src=50:54:00:00:00:02,dl_dst=50:54:00:00:00:01,arp_spa=0.0.0.0,arp_tpa=0.0.0.0,arp_sha=00:00:00:00:00:00,arp_tha=00:00:00:00:00:00
3687 # The second test tests the corner cases
3688 AT_SETUP([ofproto-dpif - ofproto/trace command 2])
3690 ADD_OF_PORTS([br0], 1, 2)
3693 odp_flow="in_port(1),eth(src=50:54:00:00:00:01,dst=50:54:00:00:00:02)"
3694 br_flow="in_port=1,dl_src=50:54:00:00:00:01,dl_dst=50:54:00:00:00:02"
3696 generate="-generate"
3697 pkt="50540000000250540000000108064500001C000100004001F98CC0A80001C0A800020800F7FF00000000"
3699 # Test incorrect command: ofproto/trace wrong_name odp_flow [-generate|packet]
3705 [AT_CHECK([ovs-appctl ofproto/trace wrong_name "$odp_flow" option],
3707 AT_CHECK([tail -2 stderr], [0], [dnl
3708 Cannot find the datapath
3709 ovs-appctl: ovs-vswitchd: server returned an error
3712 # Test incorrect command: ofproto/trace empty_string odp_flow [-generate|packet]
3718 [AT_CHECK([ovs-appctl ofproto/trace "" "$odp_flow" option],
3720 AT_CHECK([tail -2 stderr], [0], [dnl
3721 Cannot find the datapath
3722 ovs-appctl: ovs-vswitchd: server returned an error
3725 # Test incorrect command: ofproto/trace nonexist_dp_name odp_flow [-generate|packet]
3731 [AT_CHECK([ovs-appctl ofproto/trace ovs-system "$odp_flow" option],
3733 AT_CHECK([tail -2 stderr], [0], [dnl
3734 Cannot find the datapath
3735 ovs-appctl: ovs-vswitchd: server returned an error
3738 # Test incorrect command: ofproto/trace br_name odp_flow [-generate|packet]
3744 [AT_CHECK([ovs-appctl ofproto/trace br0 "$odp_flow" option],
3746 AT_CHECK([tail -2 stderr], [0], [dnl
3747 Cannot find the datapath
3748 ovs-appctl: ovs-vswitchd: server returned an error
3751 # Test incorrect command: ofproto/trace dp_name br_flow [-generate|packet]
3757 [AT_CHECK([ovs-appctl ofproto/trace ovs-dummy "$br_flow" option],
3759 AT_CHECK([tail -2 stderr], [0], [dnl
3761 ovs-appctl: ovs-vswitchd: server returned an error
3764 # Test incorrect command: ofproto/trace br_flow [-generate|packet]
3770 [AT_CHECK([ovs-appctl ofproto/trace "$br_flow" option],
3772 AT_CHECK([tail -2 stderr], [0], [dnl
3773 Must specify bridge name
3774 ovs-appctl: ovs-vswitchd: server returned an error
3777 # Test incorrect command: ofproto/trace dp_name odp_flow garbage_option
3778 AT_CHECK([ovs-appctl ofproto/trace \
3779 ovs-dummy "$odp_flow" garbage_option],
3780 [2], [stdout],[stderr])
3781 AT_CHECK([tail -2 stderr], [0], [dnl
3782 Trailing garbage in packet data
3783 ovs-appctl: ovs-vswitchd: server returned an error
3786 # Test incorrect command: ofproto/trace with 4 arguments
3787 AT_CHECK([ovs-appctl ofproto/trace \
3788 arg1, arg2, arg3, arg4], [2], [stdout],[stderr])
3789 AT_CHECK([tail -2 stderr], [0], [dnl
3790 "ofproto/trace" command takes at most 3 arguments
3791 ovs-appctl: ovs-vswitchd: server returned an error
3794 # Test incorrect command: ofproto/trace with 0 argument
3795 AT_CHECK([ovs-appctl ofproto/trace ], [2], [stdout],[stderr])
3796 AT_CHECK([tail -2 stderr], [0], [dnl
3797 "ofproto/trace" command requires at least 1 arguments
3798 ovs-appctl: ovs-vswitchd: server returned an error
3804 AT_SETUP([ofproto-dpif - ofproto/trace-packet-out])
3806 ADD_OF_PORTS([br0], 1, 2, 3)
3808 AT_DATA([flows.txt], [dnl
3809 in_port=1 actions=output:2
3810 in_port=2 actions=output:1
3812 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
3814 AT_CHECK([ovs-appctl ofproto/trace-packet-out br0 in_port=1 'mod_vlan_vid:123,resubmit(,0)'], [0], [stdout])
3815 AT_CHECK([tail -1 stdout], [0], [dnl
3816 Datapath actions: push_vlan(vid=123,pcp=0),2
3823 m4_define([OFPROTO_TRACE],
3825 AT_CHECK([ovs-appctl ofproto/trace $1 "$flow" $3], [0], [stdout])
3826 actual=`tail -1 stdout | sed 's/Datapath actions: //'`
3828 AT_CHECK([ovs-dpctl normalize-actions "$flow" "$expected" $5],
3831 AT_CHECK([ovs-dpctl normalize-actions "$flow" "$actual" $5],
3834 AT_SETUP([ofproto-dpif - MAC learning])
3835 OVS_VSWITCHD_START([set bridge br0 fail-mode=standalone])
3836 ADD_OF_PORTS([br0], 1, 2, 3)
3838 arp='eth_type(0x0806),arp(sip=192.168.0.1,tip=192.168.0.2,op=1,sha=50:54:00:00:00:05,tha=00:00:00:00:00:00)'
3840 # Trace an ARP packet arriving on p3, to create a MAC learning entry.
3843 [in_port(3),eth(src=50:54:00:00:00:05,dst=ff:ff:ff:ff:ff:ff),$arp],
3847 # Check for the MAC learning entry.
3848 AT_CHECK_UNQUOTED([ovs-appctl fdb/show br0 | sed 's/[[0-9]]\{1,\}$/?/'], [0], [dnl
3850 3 0 50:54:00:00:00:05 ?
3853 # Trace a packet arrival destined for the learned MAC.
3854 # (This will also learn a MAC.)
3857 [in_port(1),eth(src=50:54:00:00:00:06,dst=50:54:00:00:00:05),$arp],
3861 # Check for both MAC learning entries.
3862 AT_CHECK_UNQUOTED([ovs-appctl fdb/show br0 | sed 's/[[0-9]]\{1,\}$/?/'], [0], [dnl
3864 3 0 50:54:00:00:00:05 ?
3865 1 0 50:54:00:00:00:06 ?
3868 # Trace a packet arrival that updates the first learned MAC entry.
3871 [in_port(2),eth(src=50:54:00:00:00:05,dst=ff:ff:ff:ff:ff:ff),$arp],
3875 # Check that the MAC learning entry was updated.
3876 AT_CHECK_UNQUOTED([ovs-appctl fdb/show br0 | sed 's/[[0-9]]\{1,\}$/?/'], [0], [dnl
3878 1 0 50:54:00:00:00:06 ?
3879 2 0 50:54:00:00:00:05 ?
3882 # Add another bridge.
3886 -- set bridge br1 datapath-type=dummy])
3887 ADD_OF_PORTS([br1], 4, 5)
3889 # Trace some packet arrivals in br1 to create MAC learning entries there too.
3892 [in_port(4),eth(src=50:54:00:00:00:06,dst=ff:ff:ff:ff:ff:ff),$arp],
3897 [in_port(5),eth(src=50:54:00:00:00:07,dst=ff:ff:ff:ff:ff:ff),$arp],
3901 # Check that the MAC learning entries were added.
3902 AT_CHECK_UNQUOTED([ovs-appctl fdb/show br1 | sed 's/[[0-9]]\{1,\}$/?/'], [0], [dnl
3904 4 0 50:54:00:00:00:06 ?
3905 5 0 50:54:00:00:00:07 ?
3908 # Delete port p1 and see that its MAC learning entry disappeared, and
3909 # that the MAC learning entry for the same MAC was also deleted from br1.
3910 AT_CHECK([ovs-vsctl del-port p1])
3911 AT_CHECK_UNQUOTED([ovs-appctl fdb/show br0 | sed 's/[[0-9]]\{1,\}$/?/'], [0], [dnl
3913 2 0 50:54:00:00:00:05 ?
3915 AT_CHECK_UNQUOTED([ovs-appctl fdb/show br1 | sed 's/[[0-9]]\{1,\}$/?/'], [0], [dnl
3917 5 0 50:54:00:00:00:07 ?
3923 AT_SETUP([ofproto-dpif - MAC table overflow])
3925 [set bridge br0 fail-mode=standalone other-config:mac-table-size=10])
3926 ADD_OF_PORTS([br0], 1, 2, 3)
3928 arp='eth_type(0x0806),arp(sip=192.168.0.1,tip=192.168.0.2,op=1,sha=50:54:00:00:00:05,tha=00:00:00:00:00:00)'
3930 AT_CHECK([ovs-appctl time/stop])
3932 # Trace 10 ARP packets arriving on p3, to create MAC learning entries.
3933 for i in 0 1 2 3 4 5 6 7 8 9; do
3936 [in_port(3),eth(src=50:54:00:00:00:0$i,dst=ff:ff:ff:ff:ff:ff),$arp],
3939 ovs-appctl time/warp 1000
3942 # Check for the MAC learning entries.
3943 AT_CHECK_UNQUOTED([ovs-appctl fdb/show br0 | sed 's/ *[[0-9]]\{1,\}$//' | sort],
3945 3 0 50:54:00:00:00:00
3946 3 0 50:54:00:00:00:01
3947 3 0 50:54:00:00:00:02
3948 3 0 50:54:00:00:00:03
3949 3 0 50:54:00:00:00:04
3950 3 0 50:54:00:00:00:05
3951 3 0 50:54:00:00:00:06
3952 3 0 50:54:00:00:00:07
3953 3 0 50:54:00:00:00:08
3954 3 0 50:54:00:00:00:09
3958 # Trace another ARP packet on another MAC.
3961 [in_port(3),eth(src=50:54:00:00:00:10,dst=ff:ff:ff:ff:ff:ff),$arp],
3965 # Check that the new one chased the oldest one out of the table.
3966 AT_CHECK_UNQUOTED([ovs-appctl fdb/show br0 | sed 's/[[0-9]]\{1,\}$/?/' | sort],
3968 3 0 50:54:00:00:00:01 ?
3969 3 0 50:54:00:00:00:02 ?
3970 3 0 50:54:00:00:00:03 ?
3971 3 0 50:54:00:00:00:04 ?
3972 3 0 50:54:00:00:00:05 ?
3973 3 0 50:54:00:00:00:06 ?
3974 3 0 50:54:00:00:00:07 ?
3975 3 0 50:54:00:00:00:08 ?
3976 3 0 50:54:00:00:00:09 ?
3977 3 0 50:54:00:00:00:10 ?
3983 # CHECK_SFLOW_SAMPLING_PACKET(LOOPBACK_ADDR, ADDR_WITHOUT_BRACKETS)
3985 # Test that sFlow samples packets correctly using IPv4/IPv6 sFlow collector
3987 # IP_VERSION_TYPE is used in AT_SETUP
3988 m4_define([CHECK_SFLOW_SAMPLING_PACKET],
3989 [AT_SETUP([ofproto-dpif - sFlow packet sampling - $2 collector])
3990 AT_XFAIL_IF([test "$IS_WIN32" = "yes"])
3991 OVS_VSWITCHD_START([set Bridge br0 fail-mode=standalone])
3993 ON_EXIT([kill `cat test-sflow.pid`])
3994 AT_CHECK([ovstest test-sflow --log-file --detach --no-chdir --pidfile 0:$1 > sflow.log], [0], [], [ignore])
3995 AT_CAPTURE_FILE([sflow.log])
3996 SFLOW_PORT=`parse_listening_port < test-sflow.log`
3997 ovs-appctl time/stop
3999 ADD_OF_PORTS([br0], 1, 2)
4001 set Interface br0 options:ifindex=1002 -- \
4002 set Interface p1 options:ifindex=1004 -- \
4003 set Interface p2 options:ifindex=1003 -- \
4004 set Bridge br0 sflow=@sf -- \
4005 --id=@sf create sflow targets=\"$1:$SFLOW_PORT\" \
4006 header=128 sampling=1 polling=1 agent=$LOOPBACK_INTERFACE
4008 dnl open with ARP packets to seed the bridge-learning. The output
4009 dnl ifIndex numbers should be reported predictably after that.
4010 dnl Since we set sampling=1 we should see all of these packets
4011 dnl reported. Sorting the output by data-source and seqNo makes
4012 dnl it deterministic. Ensuring that we send at least two packets
4013 dnl into each port means we get to check the seq nos are
4014 dnl incrementing correctly.
4015 dnl because packets from different ports can be handled by separate
4016 dnl threads, put some sleeps
4018 ovs-appctl netdev-dummy/receive p1 'in_port(2),eth(src=50:54:00:00:00:05,dst=FF:FF:FF:FF:FF:FF),eth_type(0x0806),arp(sip=192.168.0.2,tip=192.168.0.1,op=1,sha=50:54:00:00:00:05,tha=00:00:00:00:00:00)'
4020 ovs-appctl netdev-dummy/receive p2 'in_port(1),eth(src=50:54:00:00:00:07,dst=FF:FF:FF:FF:FF:FF),eth_type(0x0806),arp(sip=192.168.0.1,tip=192.168.0.2,op=1,sha=50:54:00:00:00:07,tha=00:00:00:00:00:00)'
4022 ovs-appctl netdev-dummy/receive p1 'in_port(2),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'
4024 ovs-appctl netdev-dummy/receive p2 'in_port(1),eth(src=50:54:00:00:00:07,dst=50:54:00:00:00:05),eth_type(0x0800),ipv4(src=192.168.0.2,dst=192.168.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=0,code=0)'
4025 ovs-appctl netdev-dummy/receive p2 'in_port(1),eth(src=50:54:00:00:00:07,dst=50:54:00:00:00:05),eth_type(0x86dd),ipv6(src=fe80::1,dst=fe80::2,label=0,proto=10,tclass=0x70,hlimit=128,frag=no)'
4027 dnl sleep long enough to get more than one counter sample
4028 dnl from each datasource so we can check sequence numbers
4029 ovs-appctl time/warp 3000 100
4031 ovs-appctl -t test-sflow exit
4033 AT_CHECK_UNQUOTED([[sort sflow.log | $EGREP 'HEADER|ERROR' | sed 's/ /\
4054 hdr=FF-FF-FF-FF-FF-FF-50-54-00-00-00-05-08-06-00-01-08-00-06-04-00-01-50-54-00-00-00-05-C0-A8-00-02-00-00-00-00-00-00-C0-A8-00-01-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
4074 hdr=FF-FF-FF-FF-FF-FF-50-54-00-00-00-07-08-06-00-01-08-00-06-04-00-01-50-54-00-00-00-07-C0-A8-00-01-00-00-00-00-00-00-C0-A8-00-02-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
4094 hdr=50-54-00-00-00-07-50-54-00-00-00-05-08-00-45-00-00-1C-00-00-00-00-40-01-F9-8D-C0-A8-00-01-C0-A8-00-02-08-00-F7-FF-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
4114 hdr=50-54-00-00-00-05-50-54-00-00-00-07-08-00-45-00-00-1C-00-00-00-00-40-01-F9-8D-C0-A8-00-02-C0-A8-00-01-00-00-FF-FF-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
4134 hdr=50-54-00-00-00-05-50-54-00-00-00-07-86-DD-67-00-00-00-00-00-0A-80-FE-80-00-00-00-00-00-00-00-00-00-00-00-00-00-01-FE-80-00-00-00-00-00-00-00-00-00-00-00-00-00-02-00-00-00-00-00-00
4137 AT_CHECK_UNQUOTED([[sort sflow.log | $EGREP 'IFCOUNTERS|ERROR' | head -6 | sed 's/ /\
4151 in_broadcasts=4294967295
4154 in_unknownprotos=4294967295
4157 out_multicasts=4294967295
4158 out_broadcasts=4294967295
4174 in_broadcasts=4294967295
4177 in_unknownprotos=4294967295
4180 out_multicasts=4294967295
4181 out_broadcasts=4294967295
4197 in_broadcasts=4294967295
4200 in_unknownprotos=4294967295
4203 out_multicasts=4294967295
4204 out_broadcasts=4294967295
4220 in_broadcasts=4294967295
4223 in_unknownprotos=4294967295
4226 out_multicasts=4294967295
4227 out_broadcasts=4294967295
4243 in_broadcasts=4294967295
4246 in_unknownprotos=4294967295
4249 out_multicasts=4294967295
4250 out_broadcasts=4294967295
4266 in_broadcasts=4294967295
4269 in_unknownprotos=4294967295
4272 out_multicasts=4294967295
4273 out_broadcasts=4294967295
4280 CHECK_SFLOW_SAMPLING_PACKET([127.0.0.1], [IPv4])
4281 CHECK_SFLOW_SAMPLING_PACKET([[[::1]]], [IPv6])
4283 # CHECK_NETFLOW_EXPIRATION(LOOPBACK_ADDR, IP_VERSION_TYPE)
4285 # Test that basic NetFlow reports flow statistics correctly:
4286 # The initial packet of a flow are correctly accounted.
4287 # Later packets within a flow are correctly accounted.
4288 # Flow actions changing (in this case, due to MAC learning)
4289 # cause a record to be sent.
4291 # IP_VERSION_TYPE is used in AT_SETUP
4292 m4_define([CHECK_NETFLOW_EXPIRATION],
4293 [AT_SETUP([ofproto-dpif - NetFlow flow expiration - $2 collector])
4294 OVS_VSWITCHD_START([set Bridge br0 fail-mode=standalone])
4295 ADD_OF_PORTS([br0], 1, 2)
4297 ovs-appctl time/stop
4298 ON_EXIT([kill `cat test-netflow.pid`])
4299 AT_CHECK([ovstest test-netflow --log-file --detach --no-chdir --pidfile 0:$1 > netflow.log], [0], [], [ignore])
4300 AT_CAPTURE_FILE([netflow.log])
4301 NETFLOW_PORT=`parse_listening_port < test-netflow.log`
4304 set Bridge br0 netflow=@nf -- \
4305 --id=@nf create NetFlow targets=\"$1:$NETFLOW_PORT\" \
4306 engine_id=1 engine_type=2 active_timeout=30 add-id-to-interface=false
4308 for delay in 1000 30000; do
4309 ovs-appctl netdev-dummy/receive p1 'in_port(2),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'
4310 sleep 1 # ensure the order in which these two packets are processed
4311 ovs-appctl netdev-dummy/receive p2 'in_port(1),eth(src=50:54:00:00:00:07,dst=50:54:00:00:00:05),eth_type(0x0800),ipv4(src=192.168.0.2,dst=192.168.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=0,code=0)'
4313 ovs-appctl time/warp $delay
4316 ovs-appctl time/warp 6000
4317 ovs-appctl revalidator/wait
4319 ovs-appctl -t test-netflow exit
4321 AT_CHECK([test `grep "192.168.0.1 > 192.168.0.2, if 1 > 65535, 1 pkts, 60 bytes, ICMP 8:0" netflow.log | wc -l` -eq 1])
4323 AT_CHECK([test `grep "192.168.0.1 > 192.168.0.2, if 1 > 2, 1 pkts, 60 bytes, ICMP 8:0" netflow.log | wc -l` -eq 1])
4325 combined=`grep "192.168.0.2 > 192.168.0.1, if 2 > 1, 2 pkts, 120 bytes, ICMP 0:0" netflow.log | wc -l`
4326 separate=`grep "192.168.0.2 > 192.168.0.1, if 2 > 1, 1 pkts, 60 bytes, ICMP 0:0" netflow.log | wc -l`
4327 AT_CHECK([test $separate = 2 || test $combined = 1], [0])
4331 CHECK_NETFLOW_EXPIRATION([127.0.0.1], [IPv4])
4332 CHECK_NETFLOW_EXPIRATION([[[::1]]], [IPv6])
4334 # CHECK_NETFLOW_ACTIVE_EXPIRATION(LOOPBACK_ADDR, IP_VERSION_TYPE)
4336 # Test that basic NetFlow reports active expirations correctly.
4338 # IP_VERSION_TYPE is used in AT_SETUP
4339 m4_define([CHECK_NETFLOW_ACTIVE_EXPIRATION],
4340 [AT_SETUP([ofproto-dpif - NetFlow active expiration - $2 collector])
4342 OVS_VSWITCHD_START([set Bridge br0 fail-mode=standalone])
4343 ADD_OF_PORTS([br0], 1, 2)
4345 ON_EXIT([kill `cat test-netflow.pid`])
4346 AT_CHECK([ovstest test-netflow --log-file --detach --no-chdir --pidfile 0:$1 > netflow.log], [0], [], [ignore])
4347 AT_CAPTURE_FILE([netflow.log])
4348 NETFLOW_PORT=`parse_listening_port < test-netflow.log`
4351 set Bridge br0 netflow=@nf -- \
4352 --id=@nf create NetFlow targets=\"$1:$NETFLOW_PORT\" \
4353 engine_id=1 engine_type=2 active_timeout=10 add-id-to-interface=false
4355 AT_CHECK([ovs-appctl time/stop])
4357 while test $n -le 60; do
4360 ovs-appctl netdev-dummy/receive p1 'in_port(2),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=6,tos=0,ttl=64,frag=no),tcp(src=1234,dst=80)'
4361 ovs-appctl netdev-dummy/receive p2 'in_port(1),eth(src=50:54:00:00:00:07,dst=50:54:00:00:00:05),eth_type(0x0800),ipv4(src=192.168.0.2,dst=192.168.0.1,proto=6,tos=0,ttl=64,frag=no),tcp(src=80,dst=1234)'
4363 ovs-appctl time/warp 1000
4366 ovs-appctl time/warp 10000
4368 ovs-appctl revalidator/wait
4370 ovs-appctl -t test-netflow exit
4372 # Count the number of reported packets:
4373 # - From source to destination before MAC learning kicks in (just one).
4374 # - From source to destination after that.
4375 # - From destination to source.
4383 pkts=`echo "$line" | sed 's/.*, \([[0-9]]*\) pkts,.*/\1/'`
4390 "seq "*": 192.168.0.1 > 192.168.0.2, if 1 > 65535, "*" pkts, "*" bytes, TCP 1234 > 80, time "*)
4393 "seq "*": 192.168.0.1 > 192.168.0.2, if 1 > 2, "*" pkts, "*" bytes, TCP 1234 > 80, time "*)
4396 "seq "*": 192.168.0.2 > 192.168.0.1, if 2 > 1, "*" pkts, "*" bytes, TCP 80 > 1234, time "*)
4403 eval $counter=\`expr \$$counter + \$pkts\`
4404 n_recs=`expr $n_recs + 1`
4407 # There should be exactly 1 MAC learning packet,
4408 # exactly 59 other packets in that direction,
4409 # and exactly 60 packets in the other direction.
4410 AT_CHECK([echo $n_learn $n_in $n_out $n_other], [0], [1 59 60 0
4415 CHECK_NETFLOW_ACTIVE_EXPIRATION([127.0.0.1], [IPv4])
4416 CHECK_NETFLOW_ACTIVE_EXPIRATION([[[::1]]], [IPv6])
4418 AT_SETUP([ofproto-dpif - flow stats])
4420 AT_CHECK([ovs-ofctl add-flow br0 "ip,actions=NORMAL"])
4421 AT_CHECK([ovs-ofctl add-flow br0 "icmp,actions=NORMAL"])
4423 ovs-appctl time/stop
4425 for i in `seq 1 10`; do
4426 ovs-appctl netdev-dummy/receive br0 'in_port(0),eth(src=50:54:00:00:00:07,dst=50:54:00:00:00:05),eth_type(0x0800),ipv4(src=192.168.0.2,dst=192.168.0.1,proto=6,tos=0,ttl=64,frag=no)'
4429 ovs-appctl time/warp 1000
4430 ovs-appctl revalidator/wait
4432 AT_CHECK([ovs-ofctl dump-flows br0], [0], [stdout])
4433 AT_CHECK([STRIP_XIDS stdout | sed -n 's/duration=[[0-9]]*\.[[0-9]]*s/duration=0.0s/p' | sort], [0], [dnl
4434 cookie=0x0, duration=0.0s, table=0, n_packets=0, n_bytes=0, idle_age=1, icmp actions=NORMAL
4435 cookie=0x0, duration=0.0s, table=0, n_packets=10, n_bytes=600, idle_age=1, ip actions=NORMAL
4440 AT_SETUP([ofproto-dpif - flow stats, set-n-threads])
4442 AT_CHECK([ovs-ofctl add-flow br0 "ip,actions=NORMAL"])
4443 AT_CHECK([ovs-ofctl add-flow br0 "icmp,actions=NORMAL"])
4445 ovs-appctl time/stop
4447 for i in `seq 1 10`; do
4448 ovs-appctl netdev-dummy/receive br0 'in_port(0),eth(src=50:54:00:00:00:07,dst=50:54:00:00:00:05),eth_type(0x0800),ipv4(src=192.168.0.2,dst=192.168.0.1,proto=6,tos=0,ttl=64,frag=no)'
4451 ovs-appctl time/warp 100
4452 AT_CHECK([ovs-vsctl set Open_vSwitch . other-config:n-revalidator-threads=2])
4453 ovs-appctl time/warp 1000
4455 AT_CHECK([ovs-ofctl dump-flows br0], [0], [stdout])
4456 AT_CHECK([STRIP_XIDS stdout | sed -n 's/duration=[[0-9]]*\.[[0-9]]*s/duration=0.0s/p' | sort], [0], [dnl
4457 cookie=0x0, duration=0.0s, table=0, n_packets=0, n_bytes=0, idle_age=1, icmp actions=NORMAL
4458 cookie=0x0, duration=0.0s, table=0, n_packets=10, n_bytes=600, idle_age=1, ip actions=NORMAL
4463 AT_SETUP([idle_age and hard_age increase over time])
4466 # get_ages DURATION HARD IDLE
4468 # Fetch the flow duration, hard age, and idle age into the variables
4469 # whose names are given as arguments. Rounds DURATION down to the
4470 # nearest integer. If hard_age doesn't appear in the output, sets
4471 # HARD to "none". If idle_age doesn't appear in the output, sets IDLE
4474 AT_CHECK([ovs-ofctl dump-flows br0], [0], [stdout])
4476 duration=`sed -n 's/.*duration=\([[0-9]]*\)\(\.[[0-9]]*\)\{0,1\}s.*/\1/p' stdout`
4477 AT_CHECK([[expr X"$duration" : 'X[0-9][0-9]*$']], [0], [ignore])
4478 AS_VAR_COPY([$1], [duration])
4480 hard=`sed -n 's/.*hard_age=\([[0-9]]*\),.*/\1/p' stdout`
4481 if test X"$hard" = X; then
4484 AT_CHECK([[expr X"$hard" : 'X[0-9][0-9]*$']], [0], [ignore])
4486 AS_VAR_COPY([$2], [hard])
4488 idle=`sed -n 's/.*idle_age=\([[0-9]]*\),.*/\1/p' stdout`
4489 if test X"$idle" = X; then
4492 AT_CHECK([[expr X"$idle" : 'X[0-9][0-9]*$']], [0], [ignore])
4494 AS_VAR_COPY([$3], [idle])
4497 # Add a flow and get its initial hard and idle age.
4498 AT_CHECK([ovs-ofctl add-flow br0 hard_timeout=199,idle_timeout=188,actions=drop])
4499 get_ages duration1 hard1 idle1
4501 ovs-appctl time/stop
4502 # Warp time forward by 10 seconds, then modify the flow's actions.
4503 ovs-appctl time/warp 10000
4504 get_ages duration2 hard2 idle2
4505 AT_CHECK([ovs-ofctl mod-flows br0 actions=flood])
4507 # Warp time forward by 10 seconds.
4508 ovs-appctl time/warp 10000
4509 get_ages duration3 hard3 idle3
4511 # Warp time forward 10 more seconds, then pass some packets through the flow,
4512 # then warp forward a few more times because idle times are only updated
4514 ovs-appctl time/warp 10000
4515 ovs-appctl netdev-dummy/receive br0 'in_port(0),eth(src=50:54:00:00:00:07,dst=50:54:00:00:00:05),eth_type(0x0800),ipv4(src=192.168.0.2,dst=192.168.0.1,proto=6,tos=0,ttl=64,frag=no),tcp(src=80,dst=1234)'
4516 ovs-appctl time/warp 3000 1000
4518 get_ages duration4 hard4 idle4
4520 printf "duration: %4s => %4s => %4s => %4s\n" $duration1 $duration2 $duration3 $duration4
4521 printf "hard_age: %4s => %4s => %4s => %4s\n" $hard1 $hard2 $hard3 $hard4
4522 printf "idle_age: %4s => %4s => %4s => %4s\n" $idle1 $idle2 $idle3 $idle4
4524 # Duration should increase steadily over time.
4525 AT_CHECK([test $duration1 -lt $duration2])
4526 AT_CHECK([test $duration2 -lt $duration3])
4527 AT_CHECK([test $duration3 -lt $duration4])
4529 # Hard age should be "none" initially because it's the same as flow_duration,
4530 # then it should increase.
4531 AT_CHECK([test $hard1 = none])
4532 AT_CHECK([test $hard2 = none])
4533 AT_CHECK([test $hard3 != none])
4534 AT_CHECK([test $hard4 != none])
4535 AT_CHECK([test $hard3 -lt $hard4])
4537 # Idle age should increase from 1 to 2 to 3, then decrease.
4538 AT_CHECK([test $idle1 -lt $idle2])
4539 AT_CHECK([test $idle2 -lt $idle3])
4540 AT_CHECK([test $idle3 -gt $idle4])
4542 # Check some invariant relationships.
4543 AT_CHECK([test $duration1 = $idle1])
4544 AT_CHECK([test $duration2 = $idle2])
4545 AT_CHECK([test $duration3 = $idle3])
4546 AT_CHECK([test $idle3 -gt $hard3])
4547 AT_CHECK([test $idle4 -lt $hard4])
4548 AT_CHECK([test $hard4 -lt $duration4])
4553 AT_SETUP([ofproto-dpif - fin_timeout])
4555 ovs-appctl time/stop
4556 AT_CHECK([ovs-ofctl add-flow br0 'idle_timeout=60,actions=fin_timeout(idle_timeout=5)'])
4557 AT_CHECK([ovs-ofctl dump-flows br0 | ofctl_strip], [0],
4559 idle_timeout=60, actions=fin_timeout(idle_timeout=5)
4562 # Check that a TCP SYN packet does not change the timeout. (Because
4563 # flow stats updates are mainly what implements the fin_timeout
4564 # feature, we warp forward a couple of times to ensure that flow stats
4565 # run before re-checking the flow table.)
4566 AT_CHECK([ovs-appctl netdev-dummy/receive br0 0021853763af0026b98cb0f908004500003c2e2440004006465dac11370dac11370b828b0016751e267b00000000a00216d017360000020405b40402080a2d25085f0000000001030307])
4567 AT_CHECK([ovs-appctl time/warp 1000 && ovs-appctl time/warp 1000], [0], [warped
4570 ovs-appctl revalidator/wait
4571 AT_CHECK([ovs-ofctl dump-flows br0 | ofctl_strip], [0],
4573 n_packets=1, n_bytes=74, idle_timeout=60, actions=fin_timeout(idle_timeout=5)
4575 # Check that a TCP FIN packet does change the timeout.
4576 AT_CHECK([ovs-appctl netdev-dummy/receive br0 0021853763af0026b98cb0f90800451000342e3e40004006463bac11370dac11370b828b0016751e319dfc96399b801100717ae800000101080a2d250a9408579588])
4577 AT_CHECK([ovs-appctl time/warp 1000 && ovs-appctl time/warp 1000], [0], [warped
4580 AT_CHECK([ovs-ofctl dump-flows br0 | ofctl_strip], [0],
4582 n_packets=2, n_bytes=140, idle_timeout=5, actions=fin_timeout(idle_timeout=5)
4587 AT_SETUP([ofproto-dpif - ovs-appctl dpif/dump-dps])
4588 OVS_VSWITCHD_START([add-br br1 -- set bridge br1 datapath-type=dummy])
4589 ADD_OF_PORTS([br0], [1], [2])
4590 ADD_OF_PORTS([br1], [3])
4592 AT_CHECK([ovs-appctl dpif/dump-dps], [0], [dnl
4599 AT_SETUP([ofproto-dpif - ovs-appctl dpif/show])
4600 OVS_VSWITCHD_START([add-br br1 -- set bridge br1 datapath-type=dummy])
4601 ADD_OF_PORTS([br0], [1], [2])
4602 ADD_OF_PORTS([br1], [3])
4604 AT_CHECK([ovs-appctl dpif/show], [0], [dnl
4605 dummy@ovs-dummy: hit:0 missed:0
4607 br0 65534/100: (dummy)
4611 br1 65534/101: (dummy)
4617 AT_SETUP([ofproto-dpif - ovs-appctl dpif/dump-flows])
4618 # bump max-idle to avoid the flows being reclaimed behind us
4619 OVS_VSWITCHD_START([add-br br1 -- \
4620 set bridge br1 datapath-type=dummy fail-mode=secure -- \
4621 set Open_vSwitch . other_config:max-idle=10000])
4622 ADD_OF_PORTS([br0], [1], [2])
4623 ADD_OF_PORTS([br1], [3])
4625 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
4626 AT_CHECK([ovs-appctl netdev-dummy/receive p2 'in_port(2),eth(src=50:54:00:00:00:07,dst=50:54:00:00:00:05),eth_type(0x0800),ipv4(src=192.168.0.2,dst=192.168.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=0,code=0)'])
4627 AT_CHECK([ovs-appctl netdev-dummy/receive p3 'in_port(3),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
4628 ovs-appctl revalidator/wait
4629 AT_CHECK([ovs-appctl dpif/dump-flows br0 | sort | STRIP_USED], [0], [dnl
4630 recirc_id(0),in_port(1),eth_type(0x0800),ipv4(frag=no), packets:0, bytes:0, used:never, actions:drop
4631 recirc_id(0),in_port(2),eth_type(0x0800),ipv4(frag=no), packets:0, bytes:0, used:never, actions:drop
4634 AT_CHECK([ovs-appctl dpif/dump-flows br1 | sort | STRIP_USED], [0], [dnl
4635 recirc_id(0),in_port(3),eth_type(0x0800),ipv4(frag=no), packets:0, bytes:0, used:never, actions:drop
4638 AT_CHECK([ovs-appctl dpif/dump-flows -m br0 | sort | STRIP_USED], [0], [dnl
4639 skb_priority(0/0),skb_mark(0/0),recirc_id(0),dp_hash(0/0),in_port(p1),eth(src=50:54:00:00:00:05/00:00:00:00:00:00,dst=50:54:00:00:00:07/00:00:00:00:00:00),eth_type(0x0800),ipv4(src=192.168.0.1/0.0.0.0,dst=192.168.0.2/0.0.0.0,proto=1/0,tos=0/0,ttl=64/0,frag=no),icmp(type=8/0,code=0/0), packets:0, bytes:0, used:never, actions:drop
4640 skb_priority(0/0),skb_mark(0/0),recirc_id(0),dp_hash(0/0),in_port(p2),eth(src=50:54:00:00:00:07/00:00:00:00:00:00,dst=50:54:00:00:00:05/00:00:00:00:00:00),eth_type(0x0800),ipv4(src=192.168.0.2/0.0.0.0,dst=192.168.0.1/0.0.0.0,proto=1/0,tos=0/0,ttl=64/0,frag=no),icmp(type=0/0,code=0/0), packets:0, bytes:0, used:never, actions:drop
4643 AT_CHECK([ovs-appctl dpif/dump-flows -m br1 | sort | STRIP_USED], [0], [dnl
4644 skb_priority(0/0),skb_mark(0/0),recirc_id(0),dp_hash(0/0),in_port(p3),eth(src=50:54:00:00:00:09/00:00:00:00:00:00,dst=50:54:00:00:00:0a/00:00:00:00:00:00),eth_type(0x0800),ipv4(src=10.0.0.2/0.0.0.0,dst=10.0.0.1/0.0.0.0,proto=1/0,tos=0/0,ttl=64/0,frag=no),icmp(type=8/0,code=0/0), packets:0, bytes:0, used:never, actions:drop
4650 AT_SETUP([ofproto-dpif - MPLS actions that result in a userspace action])
4651 OVS_VSWITCHD_START([dnl
4652 add-port br0 p1 -- set Interface p1 type=dummy
4654 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
4655 ON_EXIT([kill `cat ovs-ofctl.pid`])
4657 AT_CAPTURE_FILE([ofctl_monitor.log])
4658 AT_DATA([flows.txt], [dnl
4659 dl_src=60:66:66:66:66:00 actions=push_mpls:0x8847,controller
4660 dl_src=60:66:66:66:66:01 actions=pop_mpls:0x8849,controller
4662 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
4664 dnl Packet is sent to userspace because a MPLS push or pop action is applied to
4665 dnl a packet with 2 MPLS LSEs but dpif-netdev can't handle any labels.
4667 dnl The input is a frame with two MPLS labels which tcpdump -vve shows as:
4668 dnl 60:66:66:66:66:00 > 50:54:00:00:00:07, ethertype MPLS unicast (0x8847), length 74: MPLS (label 20, exp 0, ttl 32)
4669 dnl (label 20, exp 0, [S], ttl 32)
4670 dnl (tos 0x0, ttl 64, id 0, offset 0, flags [none], proto TCP (6), length 44, bad cksum 3b78 (->f978)!)
4671 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x7744 (correct), seq 42:46, win 10000, length 4
4673 for dl_src in 00 01; do
4674 AT_CHECK([ovs-appctl netdev-dummy/receive p1 "505400000007 6066666666$dl_src 8847 00014020 00014120 45 00 00 2c 00 00 00 00 40 06 3b 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45"])
4676 sleep 1 # wait for the datapath flow installed
4677 for dl_src in 00 01; do
4678 AT_CHECK_UNQUOTED([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | grep "$dl_src," | STRIP_USED], [0], [dnl
4679 recirc_id=0,mpls,in_port=1,dl_src=60:66:66:66:66:$dl_src,mpls_label=20,mpls_tc=0,mpls_ttl=32,mpls_bos=0,mpls_lse1=82208,mpls_lse2=0, actions:userspace(pid=0,slow_path(controller))
4687 AT_SETUP([ofproto-dpif - MPLS actions that result in a drop])
4688 OVS_VSWITCHD_START([dnl
4689 add-port br0 p1 -- set Interface p1 type=dummy
4691 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
4692 ON_EXIT([kill `cat ovs-ofctl.pid`])
4694 AT_CAPTURE_FILE([ofctl_monitor.log])
4695 AT_DATA([flows.txt], [dnl
4696 dl_src=60:66:66:66:66:00 actions=push_mpls:0x8847,controller
4697 dl_src=60:66:66:66:66:01 actions=pop_mpls:0x8849,controller
4699 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
4701 dnl Packet is dropped because an MPLS PUSH action is applied to a packet with
4702 dnl 4 MPLS LSEs but ovs-vswtichd can only handle up to 3 MPLS LSEs and thus
4703 dnl can't determine the resulting MPLS label after MPLS push/pop actions.
4705 dnl The input is a frame with two MPLS headers which tcpdump -vve shows as:
4706 dnl 60:66:66:66:66:01 > 50:54:00:00:00:07, ethertype MPLS unicast (0x8847), length 74: MPLS (label 20, exp 0, ttl 32)
4707 dnl (label 20, exp 0, ttl 32)
4708 dnl (label 20, exp 0, ttl 32)
4709 dnl (label 20, exp 0, [S], ttl 32)
4710 dnl (tos 0x0, ttl 64, id 0, offset 0, flags [none], proto TCP (6), length 44, bad cksum 3b78 (->f978)!)
4711 dnl 192.168.0.1.80 > 192.168.0.2.0: Flags [none], cksum 0x7744 (correct), seq 42:46, win 10000, length 4
4713 for dl_src in 00 01; do
4714 AT_CHECK([ovs-appctl netdev-dummy/receive p1 "505400000007 6066666666$dl_src 8847 00014020 00014120 45 00 00 2c 00 00 00 00 40 06 3b 78 c0 a8 00 01 c0 a8 00 02 00 50 00 00 00 00 00 2a 00 00 00 2a 50 00 27 10 77 44 00 00 48 4f 47 45"])
4716 sleep 1 # wait for the datapath flow installed
4717 for dl_src in 00 01; do
4718 AT_CHECK_UNQUOTED([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | grep "$dl_src," | STRIP_USED], [0], [dnl
4719 recirc_id=0,mpls,in_port=1,dl_src=60:66:66:66:66:$dl_src,mpls_label=20,mpls_tc=0,mpls_ttl=32,mpls_bos=0,mpls_lse1=82208,mpls_lse2=0, actions:userspace(pid=0,slow_path(controller))
4726 AT_SETUP([ofproto-dpif - patch ports])
4727 OVS_VSWITCHD_START([add-br br1 \
4728 -- set bridge br1 datapath-type=dummy fail-mode=secure \
4729 -- add-port br1 pbr1 -- set int pbr1 type=patch options:peer=pbr0 \
4730 -- add-port br0 pbr0 -- set int pbr0 type=patch options:peer=pbr1])
4732 ADD_OF_PORTS([br0], [2])
4733 ADD_OF_PORTS([br1], [3])
4735 AT_CHECK([ovs-appctl time/stop])
4736 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
4738 AT_CHECK([ovs-ofctl add-flow br0 actions=LOCAL,output:1,output:2])
4739 AT_CHECK([ovs-ofctl add-flow br1 actions=LOCAL,output:1,output:3])
4741 for i in $(seq 1 10); do
4742 ovs-appctl netdev-dummy/receive br0 'in_port(100),eth(src=50:54:00:00:00:05,dst=50:54:00:00:00:07),eth_type(0x0800),ipv4(src=192.168.0.1,dst=192.168.0.2,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'
4743 if [[ $i -eq 1 ]]; then
4748 for i in $(seq 1 5); do
4749 ovs-appctl netdev-dummy/receive br1 'in_port(101),eth(src=50:54:00:00:00:07,dst=50:54:00:00:00:05),eth_type(0x0800),ipv4(src=192.168.0.2,dst=192.168.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'
4750 if [[ $i -eq 1 ]]; then
4755 AT_CHECK([ovs-appctl time/warp 500], [0],
4758 sleep 1 # wait for log writer
4760 AT_CHECK([ovs-appctl dpif/show], [0], [dnl
4761 dummy@ovs-dummy: hit:13 missed:2
4763 br0 65534/100: (dummy)
4765 pbr0 1/none: (patch: peer=pbr1)
4767 br1 65534/101: (dummy)
4769 pbr1 1/none: (patch: peer=pbr0)
4772 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_USED], [0], [dnl
4773 recirc_id=0,ip,in_port=100,nw_frag=no, actions:101,3,2
4774 recirc_id=0,ip,in_port=101,nw_frag=no, actions:100,2,3
4777 AT_CHECK([cat ovs-vswitchd.log | grep -e 'in_port(100).*packets:9' | FILTER_FLOW_DUMP], [0], [dnl
4778 skb_priority(0/0),skb_mark(0/0),recirc_id(0),dp_hash(0/0),in_port(100),eth(src=50:54:00:00:00:05/00:00:00:00:00:00,dst=50:54:00:00:00:07/00:00:00:00:00:00),eth_type(0x0800),ipv4(src=192.168.0.1/0.0.0.0,dst=192.168.0.2/0.0.0.0,proto=1/0,tos=0/0,ttl=64/0,frag=no),icmp(type=8/0,code=0/0), packets:9, bytes:540, used:0.0s, actions:101,3,2
4780 AT_CHECK([cat ovs-vswitchd.log | grep -e 'in_port(101).*packets:4' | FILTER_FLOW_DUMP], [0], [dnl
4781 skb_priority(0/0),skb_mark(0/0),recirc_id(0),dp_hash(0/0),in_port(101),eth(src=50:54:00:00:00:07/00:00:00:00:00:00,dst=50:54:00:00:00:05/00:00:00:00:00:00),eth_type(0x0800),ipv4(src=192.168.0.2/0.0.0.0,dst=192.168.0.1/0.0.0.0,proto=1/0,tos=0/0,ttl=64/0,frag=no),icmp(type=8/0,code=0/0), packets:4, bytes:240, used:0.0s, actions:100,2,3
4784 AT_CHECK([ovs-ofctl dump-ports br0 pbr0], [0], [dnl
4785 OFPST_PORT reply (xid=0x4): 1 ports
4786 port 1: rx pkts=5, bytes=300, drop=0, errs=0, frame=0, over=0, crc=0
4787 tx pkts=10, bytes=600, drop=0, errs=0, coll=0
4790 AT_CHECK([ovs-ofctl dump-ports br1 pbr1], [0], [dnl
4791 OFPST_PORT reply (xid=0x4): 1 ports
4792 port 1: rx pkts=10, bytes=600, drop=0, errs=0, frame=0, over=0, crc=0
4793 tx pkts=5, bytes=300, drop=0, errs=0, coll=0
4799 AT_SETUP([ofproto-dpif - port duration])
4800 OVS_VSWITCHD_START([set Bridge br0 protocols=OpenFlow13])
4801 ADD_OF_PORTS([br0], 1, 2)
4803 ovs-appctl time/stop
4804 ovs-appctl time/warp 10000
4806 AT_CHECK([ovs-ofctl -O openflow13 dump-ports br0], [0], [stdout])
4807 AT_CHECK([sed -n 's/=[[0-9]][[0-9]]\(\.[[0-9]][[0-9]]*\)\{0,1\}s/=?s/p' stdout], [0],
4816 dnl ----------------------------------------------------------------------
4817 AT_BANNER([ofproto-dpif -- megaflows])
4819 AT_SETUP([ofproto-dpif megaflow - port classification])
4821 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
4822 ADD_OF_PORTS([br0], [1], [2])
4823 AT_DATA([flows.txt], [dnl
4824 table=0 in_port=1 actions=output(2)
4826 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
4827 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
4829 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
4831 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
4832 recirc_id=0,ip,in_port=1,nw_frag=no, actions: <del>
4837 AT_SETUP([ofproto-dpif megaflow - L2 classification])
4839 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
4840 ADD_OF_PORTS([br0], [1], [2])
4841 AT_DATA([flows.txt], [dnl
4842 table=0 in_port=1,dl_src=50:54:00:00:00:09 actions=output(2)
4844 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
4845 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
4846 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
4848 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
4849 recirc_id=0,ip,in_port=1,dl_src=50:54:00:00:00:09,nw_frag=no, actions: <del>
4850 recirc_id=0,ip,in_port=1,dl_src=50:54:00:00:00:0b/ff:ff:00:00:00:02,nw_frag=no, actions: <del>
4855 AT_SETUP([ofproto-dpif megaflow - L3 classification])
4857 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
4858 ADD_OF_PORTS([br0], [1], [2])
4859 AT_CHECK([ovs-vsctl set Bridge br0 flow_tables:0=@N1 -- --id=@N1 create Flow_Table name=t0 prefixes=nw_dst,nw_src], [0], [ignore], [])
4860 AT_DATA([flows.txt], [dnl
4861 table=0 in_port=1,icmp,nw_src=10.0.0.4 actions=output(2)
4863 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
4864 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
4865 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
4867 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
4868 recirc_id=0,icmp,in_port=1,nw_src=10.0.0.4,nw_frag=no, actions: <del>
4869 recirc_id=0,ip,in_port=1,nw_src=10.0.0.2/0.0.0.2,nw_frag=no, actions: <del>
4874 AT_SETUP([ofproto-dpif megaflow - IPv6 classification])
4876 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
4877 ADD_OF_PORTS([br0], [1], [2])
4878 AT_CHECK([ovs-vsctl set Bridge br0 flow_tables:0=@N1 -- --id=@N1 create Flow_Table name=t0 prefixes=ipv6_dst,ipv6_src], [0], [ignore], [])
4879 AT_DATA([flows.txt], [dnl
4880 table=0 in_port=1,ipv6,ipv6_src=2001:db8:3c4d:1:2:3:4:5 actions=output(2)
4882 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
4883 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:07,dst=50:54:00:00:00:05),eth_type(0x86dd),ipv6(src=2001:db8:3c4d:1:2:3:4:5,dst=fe80::2,label=0,proto=10,tclass=0x70,hlimit=128,frag=no)'])
4884 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x86dd),ipv6(src=2001:db8:3c4d:5:4:3:2:1,dst=2001:db8:3c4d:1:2:3:4:1,label=0,proto=99,tclass=0x70,hlimit=64,frag=no)'])
4886 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
4887 recirc_id=0,ipv6,in_port=1,ipv6_src=2001:db8:3c4d:1:2:3:4:5,nw_frag=no, actions: <del>
4888 recirc_id=0,ipv6,in_port=1,ipv6_src=2001:db8:3c4d:5:4:3:2:1/ffff:ffff:0:4::,nw_frag=no, actions: <del>
4893 AT_SETUP([ofproto-dpif megaflow - L4 classification])
4895 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
4896 ADD_OF_PORTS([br0], [1], [2])
4897 AT_DATA([flows.txt], [dnl
4898 table=0 in_port=1,icmp,icmp_type=8 actions=output(2)
4900 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
4901 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
4903 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
4905 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
4906 recirc_id=0,icmp,in_port=1,nw_frag=no,icmp_type=0x8/0xff, actions: <del>
4911 AT_SETUP([ofproto-dpif megaflow - normal])
4913 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
4914 ADD_OF_PORTS([br0], [1], [2])
4915 AT_CHECK([ovs-ofctl add-flow br0 action=normal])
4916 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
4917 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
4919 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
4920 recirc_id=0,ip,in_port=1,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,nw_frag=no, actions: <del>
4921 recirc_id=0,ip,in_port=1,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:0b,dl_dst=50:54:00:00:00:0c,nw_frag=no, actions: <del>
4926 AT_SETUP([ofproto-dpif megaflow - mpls])
4928 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
4929 ADD_OF_PORTS([br0], [1], [2])
4930 AT_DATA([flows.txt], [dnl
4931 table=0 dl_src=50:54:00:00:00:09 actions=push_mpls:0x8847,2
4932 table=0 dl_src=50:54:00:00:00:0b actions=pop_mpls:0x0800,2
4934 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
4935 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x8847),mpls(label=11,tc=3,ttl=64,bos=1)'])
4936 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0a),eth_type(0x8847),mpls(label=11,tc=3,ttl=64,bos=1)'])
4938 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
4939 recirc_id=0,mpls,in_port=1,dl_src=50:54:00:00:00:09,mpls_label=11,mpls_tc=3,mpls_ttl=64,mpls_bos=1,mpls_lse1=0,mpls_lse2=0, actions: <del>
4940 recirc_id=0,mpls,in_port=1,dl_src=50:54:00:00:00:0b,mpls_label=11,mpls_tc=3,mpls_ttl=64,mpls_bos=1,mpls_lse1=0,mpls_lse2=0, actions: <del>
4945 # CHECK_MEGAFLOW_NETFLOW(LOOPBACK_ADDR, IP_VERSION_TYPE)
4947 # IP_VERSION_TYPE is used in AT_SETUP
4948 m4_define([CHECK_MEGAFLOW_NETFLOW],
4949 [AT_SETUP([ofproto-dpif megaflow - netflow - $2 collector])
4951 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
4952 ADD_OF_PORTS([br0], [1], [2])
4954 dnl NetFlow configuration disables wildcarding relevant fields
4955 ON_EXIT([kill `cat test-netflow.pid`])
4956 AT_CHECK([ovstest test-netflow --log-file --detach --no-chdir --pidfile 0:$1 > netflow.log], [0], [], [ignore])
4957 AT_CAPTURE_FILE([netflow.log])
4958 NETFLOW_PORT=`parse_listening_port < test-netflow.log`
4960 set Bridge br0 netflow=@nf -- \
4961 --id=@nf create NetFlow targets=\"$1:$NETFLOW_PORT\" \
4962 engine_id=1 engine_type=2 active_timeout=30 add-id-to-interface=false
4964 AT_CHECK([ovs-ofctl add-flow br0 action=normal])
4965 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
4966 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
4968 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
4969 recirc_id=0,icmp,in_port=1,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,nw_src=10.0.0.2,nw_dst=10.0.0.1,nw_tos=0,nw_frag=no,icmp_type=0x8/0xff,icmp_code=0x0/0xff, actions: <del>
4970 recirc_id=0,icmp,in_port=1,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:0b,dl_dst=50:54:00:00:00:0c,nw_src=10.0.0.4,nw_dst=10.0.0.3,nw_tos=0,nw_frag=no,icmp_type=0x8/0xff,icmp_code=0x0/0xff, actions: <del>
4975 CHECK_MEGAFLOW_NETFLOW([127.0.0.1], [IPv4])
4976 CHECK_MEGAFLOW_NETFLOW([[[::1]]], [IPv6])
4978 AT_SETUP([ofproto-dpif megaflow - normal, active-backup bonding])
4980 [add-port br0 p1 -- set Interface p1 type=dummy ofport_request=1 -- \
4981 add-bond br0 bond0 p2 p3 bond_mode=active-backup -- \
4982 set interface p2 type=dummy ofport_request=2 -- \
4983 set interface p3 type=dummy ofport_request=3])
4984 AT_CHECK([ovs-appctl netdev-dummy/set-admin-state up], 0, [OK
4986 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
4988 AT_CHECK([ovs-ofctl add-flow br0 action=normal])
4989 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
4990 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
4992 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
4993 recirc_id=0,ip,in_port=1,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,nw_frag=no, actions: <del>
4994 recirc_id=0,ip,in_port=1,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:0b,dl_dst=50:54:00:00:00:0c,nw_frag=no, actions: <del>
4999 AT_SETUP([ofproto-dpif megaflow - normal, balance-slb bonding])
5001 [add-port br0 p1 -- set Interface p1 type=dummy ofport_request=1 -- \
5002 add-bond br0 bond0 p2 p3 bond_mode=balance-slb -- \
5003 set interface p2 type=dummy ofport_request=2 -- \
5004 set interface p3 type=dummy ofport_request=3])
5005 AT_CHECK([ovs-appctl netdev-dummy/set-admin-state up], 0, [OK
5007 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
5009 AT_CHECK([ovs-ofctl add-flow br0 action=normal])
5010 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5011 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5013 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
5014 recirc_id=0,ip,in_port=1,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,nw_frag=no, actions: <del>
5015 recirc_id=0,ip,in_port=1,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:0b,dl_dst=50:54:00:00:00:0c,nw_frag=no, actions: <del>
5020 AT_SETUP([ofproto-dpif megaflow - normal, balance-tcp bonding])
5021 # Create bond0 on br0 with interfaces p0 and p1
5022 # and bond1 on br1 with interfaces p2 and p3
5023 # with p0 patched to p2 and p1 patched to p3.
5025 [add-bond br0 bond0 p0 p1 bond_mode=balance-tcp lacp=active \
5026 other-config:lacp-time=fast \
5027 other-config:bond-rebalance-interval=0 -- \
5028 set interface p0 type=patch options:peer=p2 ofport_request=1 -- \
5029 set interface p1 type=patch options:peer=p3 ofport_request=2 -- \
5031 set bridge br1 other-config:hwaddr=aa:66:aa:66:00:00 -- \
5032 set bridge br1 datapath-type=dummy other-config:datapath-id=1234 \
5033 fail-mode=secure -- \
5034 add-bond br1 bond1 p2 p3 bond_mode=balance-tcp lacp=active \
5035 other-config:lacp-time=fast \
5036 other-config:bond-rebalance-interval=0 -- \
5037 set interface p2 type=patch options:peer=p0 ofport_request=3 -- \
5038 set interface p3 type=patch options:peer=p1 ofport_request=4 --])
5040 AT_CHECK([ovs-appctl netdev-dummy/set-admin-state up], 0, [OK
5042 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
5043 ADD_OF_PORTS([br0], [7])
5044 AT_CHECK([ovs-ofctl add-flow br0 action=normal])
5045 AT_CHECK([ovs-ofctl add-flow br1 action=normal])
5046 ovs-appctl time/stop
5047 ovs-appctl time/warp 5000
5048 AT_CHECK([ovs-appctl netdev-dummy/receive p7 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5049 AT_CHECK([ovs-appctl netdev-dummy/receive p7 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5051 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
5052 recirc_id=0,ip,in_port=7,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,nw_frag=no, actions: <del>
5053 recirc_id=0,ip,in_port=7,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:0b,dl_dst=50:54:00:00:00:0c,nw_frag=no, actions: <del>
5058 AT_SETUP([ofproto-dpif megaflow - resubmit port action])
5060 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
5061 ADD_OF_PORTS([br0], [1], [2])
5062 AT_DATA([flows.txt], [dnl
5063 table=0 in_port=1,ip actions=resubmit(90)
5064 table=0 in_port=90,dl_src=50:54:00:00:00:09 actions=output(2)
5066 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
5067 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5068 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5070 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
5071 recirc_id=0,ip,in_port=1,dl_src=50:54:00:00:00:09,nw_frag=no, actions: <del>
5072 recirc_id=0,ip,in_port=1,dl_src=50:54:00:00:00:0b/ff:ff:00:00:00:02,nw_frag=no, actions: <del>
5077 AT_SETUP([ofproto-dpif megaflow - resubmit table action])
5079 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
5080 ADD_OF_PORTS([br0], [1], [2])
5081 AT_DATA([flows.txt], [dnl
5082 table=0 in_port=1,ip actions=resubmit(,1)
5083 table=1 dl_src=50:54:00:00:00:09 actions=output(2)
5085 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
5086 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5087 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=
5088 1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5090 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
5091 recirc_id=0,ip,in_port=1,dl_src=50:54:00:00:00:09,nw_frag=no, actions: <del>
5092 recirc_id=0,ip,in_port=1,dl_src=50:54:00:00:00:0b,nw_frag=no, actions: <del>
5097 AT_SETUP([ofproto-dpif megaflow - goto_table action])
5099 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
5100 ADD_OF_PORTS([br0], [1], [2])
5101 AT_DATA([flows.txt], [dnl
5102 table=0 in_port=1,ip actions=goto_table(1)
5103 table=1 dl_src=50:54:00:00:00:09 actions=output(2)
5105 AT_CHECK([ovs-ofctl -O OpenFlow12 add-flows br0 flows.txt])
5106 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5107 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5109 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
5110 recirc_id=0,ip,in_port=1,dl_src=50:54:00:00:00:09,nw_frag=no, actions: <del>
5111 recirc_id=0,ip,in_port=1,dl_src=50:54:00:00:00:0b,nw_frag=no, actions: <del>
5116 AT_SETUP([ofproto-dpif megaflow - mirroring, select_all])
5118 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
5119 ADD_OF_PORTS([br0], [1], [2], [3])
5121 set Bridge br0 mirrors=@m --\
5122 --id=@p3 get Port p3 --\
5123 --id=@m create Mirror name=mymirror select_all=true output_port=@p3
5125 AT_DATA([flows.txt], [dnl
5126 in_port=1 actions=output:2
5128 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
5129 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5131 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5133 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
5134 recirc_id=0,ip,in_port=1,nw_frag=no, actions: <del>
5139 AT_SETUP([ofproto-dpif megaflow - mirroring, select_vlan])
5141 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
5142 ADD_OF_PORTS([br0], [1], [2], [3])
5144 set Bridge br0 mirrors=@m --\
5145 --id=@p2 get Port p2 -- --id=@p3 get Port p3 --\
5146 --id=@m create Mirror name=mymirror select_all=true select_vlan=11 output_port=@p3
5148 AT_DATA([flows.txt], [dnl
5149 in_port=1 actions=output:2
5151 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
5152 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x8100),vlan(vid=11,pcp=7),encap(eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0))'])
5153 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5155 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
5156 recirc_id=0,ip,in_port=1,dl_vlan=11,nw_frag=no, actions: <del>
5157 recirc_id=0,ip,in_port=1,vlan_tci=0x0000/0x1fff,nw_frag=no, actions: <del>
5162 AT_SETUP([ofproto-dpif megaflow - move action])
5164 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
5165 ADD_OF_PORTS([br0], [1], [2])
5166 AT_DATA([flows.txt], [dnl
5167 table=0 in_port=1 ip,actions=move:NXM_OF_IP_SRC[[]]->NXM_NX_REG0[[]],resubmit(90)
5168 table=0 in_port=90 ip,actions=move:NXM_NX_REG0[[]]->NXM_NX_REG1[[]],resubmit(91)
5169 table=0 in_port=91 reg0=0x0a000002,actions=output(2)
5171 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
5172 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5173 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5175 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
5176 recirc_id=0,ip,in_port=1,nw_src=10.0.0.2,nw_frag=no, actions: <del>
5177 recirc_id=0,ip,in_port=1,nw_src=10.0.0.4,nw_frag=no, actions: <del>
5182 AT_SETUP([ofproto-dpif megaflow - push action])
5184 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
5185 ADD_OF_PORTS([br0], [1], [2])
5186 AT_DATA([flows.txt], [dnl
5187 table=0 in_port=1 ip,actions=push:NXM_OF_IP_SRC[[]],output(2)
5189 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
5190 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5191 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5193 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
5194 recirc_id=0,ip,in_port=1,nw_src=10.0.0.2,nw_frag=no, actions: <del>
5195 recirc_id=0,ip,in_port=1,nw_src=10.0.0.4,nw_frag=no, actions: <del>
5200 AT_SETUP([ofproto-dpif megaflow - learning])
5202 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
5203 ADD_OF_PORTS([br0], [1], [2])
5204 AT_DATA([flows.txt], [dnl
5205 table=0 in_port=1 actions=load:2->NXM_NX_REG0[[0..15]],learn(table=1,priority=65535,NXM_OF_ETH_SRC[[]],NXM_OF_VLAN_TCI[[0..11]],output:NXM_NX_REG0[[0..15]]),output:2
5207 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
5208 ovs-appctl time/stop
5209 # We send each packet twice because the first packet in each flow causes the
5210 # flow table to change and thus revalidations, which (depending on timing)
5211 # can keep a megaflow from being installed. The revalidations are done by
5212 # the second iteration, allowing the flows to be installed.
5214 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5215 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5216 ovs-appctl time/warp 100
5219 dnl The original flow is missing due to a revalidation.
5220 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
5221 recirc_id=0,ip,in_port=1,vlan_tci=0x0000/0x0fff,dl_src=50:54:00:00:00:09,nw_frag=no, actions: <del>
5222 recirc_id=0,ip,in_port=1,vlan_tci=0x0000/0x0fff,dl_src=50:54:00:00:00:0b,nw_frag=no, actions: <del>
5227 AT_SETUP([ofproto-dpif megaflow - tunnels])
5229 [add-port br0 p1 -- set Interface p1 type=dummy ofport_request=1])
5230 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
5231 AT_CHECK([ovs-vsctl add-port br0 p2 -- set Interface p2 type=gre \
5232 options:remote_ip=1.1.1.1 ofport_request=2 options:key=flow])
5233 AT_CHECK([ovs-vsctl add-port br0 p3 -- set Interface p3 type=dummy \
5235 AT_CHECK([ovs-vsctl add-port br0 p4 -- set Interface p4 type=gre \
5236 options:remote_ip=1.1.1.2 options:tos=inherit options:ttl=inherit \
5237 ofport_request=4 options:key=flow])
5238 AT_DATA([flows.txt], [dnl
5239 in_port=1,actions=output(2)
5240 in_port=3,actions=output(4)
5242 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
5243 dnl ECN bits are always copied out, but don't use 0x3 (CE), since that
5244 dnl will cause the packet to be dropped.
5245 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0xfd,ttl=128,frag=no),icmp(type=8,code=0)'])
5247 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0x1,ttl=64,frag=no),icmp(type=8,code=0)'])
5248 AT_CHECK([ovs-appctl netdev-dummy/receive p3 'in_port(3),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0xfd,ttl=128,frag=no),icmp(type=8,code=0)'])
5250 AT_CHECK([ovs-appctl netdev-dummy/receive p3 'in_port(3),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0x1,ttl=64,frag=no),icmp(type=8,code=0)'])
5252 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
5253 recirc_id=0,ip,in_port=1,nw_ecn=1,nw_frag=no, actions: <del>
5254 recirc_id=0,ip,in_port=3,nw_tos=0,nw_ecn=1,nw_ttl=64,nw_frag=no, actions: <del>
5255 recirc_id=0,ip,in_port=3,nw_tos=252,nw_ecn=1,nw_ttl=128,nw_frag=no, actions: <del>
5260 AT_SETUP([ofproto-dpif megaflow - dec_ttl])
5262 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
5263 ADD_OF_PORTS([br0], [1], [2])
5264 AT_CHECK([ovs-vsctl set Bridge br0 flow_tables:0=@N1 -- --id=@N1 create Flow_Table name=t0 prefixes=nw_dst,nw_src], [0], [ignore], [])
5265 AT_DATA([flows.txt], [dnl
5266 table=0 in_port=1,icmp,nw_src=10.0.0.4 actions=dec_ttl,output(2)
5268 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
5269 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5270 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5272 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_XOUT], [0], [dnl
5273 recirc_id=0,icmp,in_port=1,nw_src=10.0.0.4,nw_ttl=64,nw_frag=no, actions: <del>
5274 recirc_id=0,ip,in_port=1,nw_src=10.0.0.2/0.0.0.2,nw_frag=no, actions: <del>
5279 AT_SETUP([ofproto-dpif megaflow - set dl_dst])
5281 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
5282 ADD_OF_PORTS([br0], [1], [2])
5283 AT_DATA([flows.txt], [dnl
5284 table=0 in_port=1 actions=mod_dl_dst(50:54:00:00:00:0a),output(2)
5286 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
5287 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5288 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5290 dnl The first packet is essentially a no-op, as the new destination MAC is the
5291 dnl same as the original. The second entry actually updates the destination
5293 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_USED], [0], [dnl
5294 recirc_id=0,ip,in_port=1,dl_dst=50:54:00:00:00:0a,nw_frag=no, actions:2
5295 recirc_id=0,ip,in_port=1,dl_dst=50:54:00:00:00:0c,nw_frag=no, actions:set(eth(dst=50:54:00:00:00:0a)),2
5300 AT_SETUP([ofproto-dpif megaflow - disabled])
5302 AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg])
5303 ADD_OF_PORTS([br0], [1], [2])
5304 AT_DATA([flows.txt], [dnl
5305 table=0 in_port=1,ip,nw_dst=10.0.0.1 actions=output(2)
5306 table=0 in_port=1,ip,nw_dst=10.0.0.3 actions=drop
5308 AT_CHECK([ovs-appctl upcall/disable-megaflows], [0], [megaflows disabled
5310 AT_CHECK([ovs-appctl vlog/set dpif_netdev:dbg], [0], [], [])
5311 AT_CHECK([ovs-ofctl add-flows br0 flows.txt])
5312 for i in 1 2 3 4; do
5313 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5314 AT_CHECK([ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0)'])
5315 if [[ $i -eq 1 ]]; then
5320 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_INSTALL | STRIP_USED], [0], [dnl
5321 pkt_mark=0,recirc_id=0,skb_priority=0,icmp,tun_id=0,tun_src=0.0.0.0,tun_dst=0.0.0.0,tun_tos=0,tun_ttl=0,,in_port=1,vlan_tci=0x0000,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,nw_src=10.0.0.2,nw_dst=10.0.0.1,nw_tos=0,nw_ecn=0,nw_ttl=64,mpls_label=0,mpls_tc=0,mpls_ttl=0,mpls_bos=0,mpls_lse1=0,mpls_lse2=0,icmp_type=8,icmp_code=0, actions:2
5322 pkt_mark=0,recirc_id=0,skb_priority=0,icmp,tun_id=0,tun_src=0.0.0.0,tun_dst=0.0.0.0,tun_tos=0,tun_ttl=0,,in_port=1,vlan_tci=0x0000,dl_src=50:54:00:00:00:0b,dl_dst=50:54:00:00:00:0c,nw_src=10.0.0.4,nw_dst=10.0.0.3,nw_tos=0,nw_ecn=0,nw_ttl=64,mpls_label=0,mpls_tc=0,mpls_ttl=0,mpls_bos=0,mpls_lse1=0,mpls_lse2=0,icmp_type=8,icmp_code=0, actions:drop
5324 AT_CHECK([cat ovs-vswitchd.log | FILTER_FLOW_DUMP | grep 'packets:3'], [0], [dnl
5325 skb_priority(0),skb_mark(0),recirc_id(0),dp_hash(0),in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x0800),ipv4(src=10.0.0.2,dst=10.0.0.1,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0), packets:3, bytes:180, used:0.0s, actions:2
5326 skb_priority(0),skb_mark(0),recirc_id(0),dp_hash(0),in_port(1),eth(src=50:54:00:00:00:0b,dst=50:54:00:00:00:0c),eth_type(0x0800),ipv4(src=10.0.0.4,dst=10.0.0.3,proto=1,tos=0,ttl=64,frag=no),icmp(type=8,code=0), packets:3, bytes:180, used:0.0s, actions:drop
5331 AT_SETUP([ofproto-dpif - datapath port number change])
5332 OVS_VSWITCHD_START([set Bridge br0 fail-mode=standalone])
5333 ADD_OF_PORTS([br0], 1)
5335 # Trace a flow that should output to p1.
5336 AT_CHECK([ovs-appctl ofproto/trace br0 in_port=LOCAL,dl_src=10:20:30:40:50:60],
5338 AT_CHECK([tail -1 stdout], [0], [Datapath actions: 1
5341 # Change p1's port number to 5.
5342 AT_CHECK([ovs-appctl dpif-dummy/change-port-number ovs-dummy p1 5])
5344 # Trace a flow that should output to p1 in its new location.
5345 AT_CHECK([ovs-appctl ofproto/trace br0 in_port=LOCAL,dl_src=10:20:30:40:50:60],
5347 AT_CHECK([tail -1 stdout], [0], [Datapath actions: 5
5352 # Tests the bundling with various bfd and cfm configurations.
5353 AT_SETUP([ofproto - bundle with variable bfd/cfm config])
5354 OVS_VSWITCHD_START([add-br br1 -- set bridge br1 datapath-type=dummy -- \
5355 add-bond br0 br0bond p0 p2 bond-mode=active-backup -- \
5356 add-bond br1 br1bond p1 p3 bond-mode=active-backup -- \
5357 set Interface p1 type=patch options:peer=p0 ofport_request=2 -- \
5358 set Interface p3 type=patch options:peer=p2 ofport_request=4 -- \
5359 set Interface p0 type=patch options:peer=p1 ofport_request=1 -- \
5360 set Interface p2 type=patch options:peer=p3 ofport_request=3 -- \
5361 set Interface p0 bfd:enable=true bfd:min_tx=300 bfd:min_rx=300 -- \
5362 set Interface p0 cfm_mpid=1 -- \
5363 set Interface p1 bfd:enable=true bfd:min_tx=500 bfd:min_rx=500])
5365 ovs-appctl time/stop
5366 # advance the clock to stablize everything.
5367 ovs-appctl time/warp 5000 100
5368 # cfm/show should show 'recv' fault.
5369 AT_CHECK([ovs-appctl cfm/show | sed -n '/^.*fault:.*/p'], [0], [dnl
5372 # bfd/show should show 'up'.
5373 AT_CHECK([ovs-appctl bfd/show | sed -n '/^.*Session State:.*/p'], [0], [dnl
5374 Local Session State: up
5375 Remote Session State: up
5376 Local Session State: up
5377 Remote Session State: up
5379 # bond/show should show 'may-enable: true' for all slaves.
5380 AT_CHECK([ovs-appctl bond/show | sed -n '/^.*may_enable:.*/p'], [0], [dnl
5387 # now disable the bfd on p1.
5388 AT_CHECK([ovs-vsctl set Interface p1 bfd:enable=false])
5389 # advance the clock to stablize everything.
5390 ovs-appctl time/warp 5000 100
5391 # cfm/show should show 'recv' fault.
5392 AT_CHECK([ovs-appctl cfm/show | sed -n '/^.*fault:.*/p'], [0], [dnl
5395 # bfd/show should show 'down'.
5396 AT_CHECK([ovs-appctl bfd/show | sed -n '/^.*Session State:.*/p'], [0], [dnl
5397 Local Session State: down
5398 Remote Session State: down
5400 # bond/show should show 'may-enable: false' for p0.
5401 AT_CHECK([ovs-appctl bond/show br0bond | sed -n '/^.*may_enable:.*/p'], [0], [dnl
5406 # now enable the bfd on p1 and disable bfd on p0.
5407 AT_CHECK([ovs-vsctl set Interface p1 bfd:enable=true])
5408 AT_CHECK([ovs-vsctl set Interface p0 bfd:enable=false])
5409 # advance the clock to stablize everything.
5410 ovs-appctl time/warp 5000 100
5411 # cfm/show should show 'recv' fault.
5412 AT_CHECK([ovs-appctl cfm/show | sed -n '/^.*fault:.*/p'], [0], [dnl
5415 # bfd/show should show 'down'.
5416 AT_CHECK([ovs-appctl bfd/show | sed -n '/^.*Session State:.*/p'], [0], [dnl
5417 Local Session State: down
5418 Remote Session State: down
5420 # bond/show should show 'may-enable: false' for p0 and p1.
5421 AT_CHECK([ovs-appctl bond/show | sed -n '/^.*may_enable:.*/p'], [0], [dnl
5431 AT_SETUP([ofproto-dpif - ofproto-dpif-monitor 1])
5432 OVS_VSWITCHD_START([add-port br0 p0 -- set interface p0 type=gre options:remote_ip=1.2.3.4])
5435 AT_CHECK([ovs-vsctl set interface p0 bfd:enable=true])
5437 OVS_WAIT_UNTIL([grep "monitor thread created" ovs-vswitchd.log])
5438 # disable bfd on p0.
5439 AT_CHECK([ovs-vsctl set interface p0 bfd:enable=false])
5441 OVS_WAIT_UNTIL([grep "monitor thread terminated" ovs-vswitchd.log])
5442 AT_CHECK([cat ovs-vswitchd.log | sed -e '/^.*ofproto_dpif_monitor.*$/d' > ovs-vswitchd.log])
5445 AT_CHECK([ovs-vsctl set interface p0 cfm_mpid=10])
5447 OVS_WAIT_UNTIL([grep "monitor thread created" ovs-vswitchd.log])
5448 # disable cfm on p0.
5449 AT_CHECK([ovs-vsctl remove interface p0 cfm_mpid 10])
5451 OVS_WAIT_UNTIL([grep "monitor thread terminated" ovs-vswitchd.log])
5452 AT_CHECK([cat ovs-vswitchd.log | sed -e '/^.*ofproto_dpif_monitor.*$/d' > ovs-vswitchd.log])
5454 # enable both bfd and cfm on p0.
5455 AT_CHECK([ovs-vsctl set interface p0 bfd:enable=true cfm_mpid=10])
5457 OVS_WAIT_UNTIL([grep "monitor thread created" ovs-vswitchd.log])
5458 # disable bfd on p0.
5459 AT_CHECK([ovs-vsctl set interface p0 bfd:enable=false])
5460 # check log, there should not be the log of thread terminated.
5461 AT_CHECK([sed -n "s/^.*|ofproto_dpif_monitor(monitor[[0-9]]*)|INFO|\(.* terminated\)$/\1/p" ovs-vswitchd.log], [0], [dnl
5463 # reenable bfd on p0.
5464 AT_CHECK([ovs-vsctl set interface p0 bfd:enable=true])
5465 # check log, should still be on log of thread created.
5466 AT_CHECK([sed -n "s/^.*|ofproto_dpif_monitor(monitor[[0-9]]*)|INFO|\(.* created\)$/\1/p" ovs-vswitchd.log], [0], [dnl
5467 monitor thread created
5469 # disable bfd and cfm together.
5470 AT_CHECK([ovs-vsctl set interface p0 bfd:enable=false -- remove interface p0 cfm_mpid 10])
5472 OVS_WAIT_UNTIL([grep "monitor thread terminated" ovs-vswitchd.log])
5477 # this test helps avoid the deadlock between the main thread and monitor thread.
5478 AT_SETUP([ofproto-dpif - ofproto-dpif-monitor 2])
5481 for i in `seq 1 199`
5483 AT_CHECK([ovs-vsctl add-port br0 p$i -- set interface p$i type=gre options:remote_ip=1.2.3.4 options:key=$i bfd:enable=true])
5489 AT_BANNER([ofproto-dpif - flow translation resource limits])
5491 AT_SETUP([ofproto-dpif - infinite resubmit])
5493 AT_CHECK([ovs-ofctl add-flow br0 actions=resubmit:1,resubmit:2,output:3])
5494 AT_CHECK([ovs-appctl -vpoll_loop:off ofproto/trace br0 'eth_dst=ff:ff:ff:ff:ff:ff'],
5496 AT_CHECK([tail -1 stdout], [0], [Datapath actions: drop
5498 AT_CHECK([grep -c 'resubmit actions recursed over 64 times' ovs-vswitchd.log],
5501 OVS_VSWITCHD_STOP(["/resubmit actions recursed/d"])
5504 AT_SETUP([ofproto-dpif - exponential resubmit chain])
5506 ADD_OF_PORTS([br0], 1)
5507 (for i in `seq 1 64`; do
5509 echo "in_port=$i, actions=resubmit:$j, resubmit:$j, local"
5511 echo "in_port=65, actions=local") > flows
5512 AT_CHECK([ovs-ofctl add-flows br0 flows])
5513 AT_CHECK([ovs-appctl -vpoll_loop:off ofproto/trace br0 'in_port=1'], [0], [stdout])
5514 AT_CHECK([grep -c 'over 4096 resubmit actions' ovs-vswitchd.log], [0], [1
5516 OVS_VSWITCHD_STOP(["/over.*resubmit actions/d"])
5519 AT_SETUP([ofproto-dpif - too many output actions])
5521 ADD_OF_PORTS([br0], 1)
5522 (for i in `seq 1 12`; do
5524 echo "in_port=$i, actions=resubmit:$j, resubmit:$j, local"
5526 echo "in_port=13, actions=local,local,local,local,local,local,local,local") > flows
5527 AT_CHECK([ovs-ofctl add-flows br0 flows])
5528 AT_CHECK([ovs-appctl -vpoll_loop:off ofproto/trace br0 'in_port=1'], [0], [stdout])
5529 AT_CHECK([grep -c -e '- Uses action(s) not supported by datapath' stdout],
5532 AT_CHECK([grep -c 'resubmits yielded over 64 kB of actions' ovs-vswitchd.log], [0], [1
5534 OVS_VSWITCHD_STOP(["/resubmits yielded over 64 kB of actions/d"])
5537 AT_SETUP([ofproto-dpif - stack too deep])
5539 ADD_OF_PORTS([br0], 1)
5540 (for i in `seq 1 12`; do
5542 echo "in_port=$i, actions=resubmit:$j, resubmit:$j, local"
5544 push="push:NXM_NX_REG0[[]]"
5545 echo "in_port=13, actions=$push,$push,$push,$push,$push,$push,$push,$push") > flows
5546 AT_CHECK([ovs-ofctl add-flows br0 flows])
5547 AT_CHECK([ovs-appctl -vpoll_loop:off ofproto/trace br0 'in_port=1'], [0], [stdout])
5548 AT_CHECK([grep -c 'resubmits yielded over 64 kB of stack' ovs-vswitchd.log], [0], [1
5550 OVS_VSWITCHD_STOP(["/resubmits yielded over 64 kB of stack/d"])
5554 AT_SETUP([ofproto-dpif packet-out controller])
5556 ADD_OF_PORTS([br0], 1, 2)
5558 AT_CHECK([ovs-ofctl add-flow br0 'dl_dst=50:54:00:00:00:0a actions=controller'])
5560 AT_CAPTURE_FILE([ofctl_monitor.log])
5561 AT_CHECK([ovs-ofctl monitor br0 65534 invalid_ttl --detach --no-chdir --pidfile 2> ofctl_monitor.log])
5564 AT_CHECK([ovs-ofctl -O OpenFlow13 packet-out br0 CONTROLLER controller '50540000000a5054000000091234'])
5567 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
5568 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
5569 NXT_PACKET_IN (xid=0x0): total_len=14 in_port=CONTROLLER (via action) data_len=14 (unbuffered)
5570 metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,dl_type=0x1234
5572 NXT_PACKET_IN (xid=0x0): total_len=14 in_port=CONTROLLER (via action) data_len=14 (unbuffered)
5573 metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,dl_type=0x1234
5575 NXT_PACKET_IN (xid=0x0): total_len=14 in_port=CONTROLLER (via action) data_len=14 (unbuffered)
5576 metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,dl_type=0x1234
5579 AT_CHECK([ovs-ofctl dump-flows br0 | ofctl_strip | sort], [0], [dnl
5580 dl_dst=50:54:00:00:00:0a actions=CONTROLLER:65535
5584 (echo "OFPST_TABLE reply (OF1.3) (xid=0x2):
5586 active=1, lookup=0, matched=0"
5588 while test $x -lt 254; do
5591 active=0, lookup=0, matched=0"
5594 AT_CHECK([ovs-ofctl -O OpenFlow13 dump-tables br0 ], [0], [expout])
5599 AT_SETUP([ofproto-dpif packet-out controller (patch port)])
5602 add-port br0 p1 -- \
5603 set interface p1 type=patch options:peer=p2 -- \
5605 set bridge br1 datapath-type=dummy -- \
5606 set bridge br1 fail-mode=secure -- \
5607 set bridge br1 protocols='[OpenFlow10,OpenFlow11,OpenFlow12,OpenFlow13]' -- \
5608 add-port br1 p2 -- \
5609 set interface p2 type=patch options:peer=p1 --])
5611 AT_CAPTURE_FILE([ofctl_monitor.log])
5612 AT_CHECK([ovs-ofctl monitor br1 65534 invalid_ttl --detach --no-chdir --pidfile 2> ofctl_monitor.log])
5615 AT_CHECK([ovs-ofctl -O OpenFlow13 packet-out br0 CONTROLLER output:1 '50540000000a5054000000091234'])
5618 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
5619 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
5620 NXT_PACKET_IN (xid=0x0): cookie=0x0 total_len=14 in_port=1 (via no_match) data_len=14 (unbuffered)
5621 metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,dl_type=0x1234
5623 NXT_PACKET_IN (xid=0x0): cookie=0x0 total_len=14 in_port=1 (via no_match) data_len=14 (unbuffered)
5624 metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,dl_type=0x1234
5626 NXT_PACKET_IN (xid=0x0): cookie=0x0 total_len=14 in_port=1 (via no_match) data_len=14 (unbuffered)
5627 metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,dl_type=0x1234
5630 (printf "OFPST_TABLE reply (OF1.3) (xid=0x2):"
5632 while test $x -lt 254; do
5635 active=0, lookup=0, matched=0"
5638 AT_CHECK([ovs-ofctl -O OpenFlow13 dump-tables br0 ], [0], [expout])
5640 (echo "OFPST_TABLE reply (OF1.3) (xid=0x2):
5642 active=0, lookup=3, matched=0"
5644 while test $x -lt 254; do
5647 active=0, lookup=0, matched=0"
5650 AT_CHECK([ovs-ofctl -O OpenFlow13 dump-tables br1 ], [0], [expout])
5656 AT_SETUP([ofproto-dpif packet-out goto_table])
5658 ADD_OF_PORTS([br0], 1, 2)
5660 AT_DATA([flows.txt], [dnl
5661 table=0 dl_dst=50:54:00:00:00:0a actions=goto_table(1)
5662 table=1 dl_dst=50:54:00:00:00:0a actions=controller
5664 AT_CHECK([ovs-ofctl -O OpenFlow13 add-flows br0 flows.txt])
5666 AT_CAPTURE_FILE([ofctl_monitor.log])
5667 AT_CHECK([ovs-ofctl monitor br0 65534 invalid_ttl --detach --no-chdir --pidfile 2> ofctl_monitor.log])
5670 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x1234)'
5673 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
5674 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
5675 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
5676 NXT_PACKET_IN (xid=0x0): table_id=1 cookie=0x0 total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
5677 metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,dl_type=0x1234
5679 NXT_PACKET_IN (xid=0x0): table_id=1 cookie=0x0 total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
5680 metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,dl_type=0x1234
5682 NXT_PACKET_IN (xid=0x0): table_id=1 cookie=0x0 total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
5683 metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,dl_type=0x1234
5686 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
5687 AT_CHECK([ovs-appctl revalidator/wait], [0], [ignore])
5689 AT_CHECK([ovs-ofctl -O OpenFlow13 dump-flows br0 | ofctl_strip | sort], [0], [dnl
5690 n_packets=3, n_bytes=180, dl_dst=50:54:00:00:00:0a actions=goto_table:1
5691 table=1, n_packets=3, n_bytes=180, dl_dst=50:54:00:00:00:0a actions=CONTROLLER:65535
5692 OFPST_FLOW reply (OF1.3):
5695 (echo "OFPST_TABLE reply (OF1.3) (xid=0x2):
5697 active=1, lookup=3, matched=3
5700 active=1, lookup=3, matched=3"
5702 while test $x -lt 254; do
5705 active=0, lookup=0, matched=0"
5708 AT_CHECK([ovs-ofctl -O OpenFlow13 dump-tables br0 ], [0], [expout])
5714 AT_SETUP([ofproto-dpif packet-out table-miss (continue)])
5716 ADD_OF_PORTS([br0], 1, 2)
5718 AT_CHECK([ovs-ofctl -O OpenFlow11 add-flow br0 'table=1 dl_dst=50:54:00:00:00:0a actions=controller'])
5719 AT_CHECK([ovs-ofctl -O OpenFlow11 mod-table br0 all continue])
5721 AT_CAPTURE_FILE([ofctl_monitor.log])
5722 AT_CHECK([ovs-ofctl monitor br0 65534 invalid_ttl --detach --no-chdir --pidfile 2> ofctl_monitor.log])
5725 ovs-appctl netdev-dummy/receive p1 'in_port(1),eth(src=50:54:00:00:00:09,dst=50:54:00:00:00:0a),eth_type(0x1234)'
5728 OVS_WAIT_UNTIL([test `wc -l < ofctl_monitor.log` -ge 6])
5729 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
5730 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
5731 NXT_PACKET_IN (xid=0x0): table_id=1 cookie=0x0 total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
5732 metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,dl_type=0x1234
5734 NXT_PACKET_IN (xid=0x0): table_id=1 cookie=0x0 total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
5735 metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,dl_type=0x1234
5737 NXT_PACKET_IN (xid=0x0): table_id=1 cookie=0x0 total_len=60 in_port=1 (via action) data_len=60 (unbuffered)
5738 metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:09,dl_dst=50:54:00:00:00:0a,dl_type=0x1234
5741 AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
5742 AT_CHECK([ovs-appctl revalidator/wait], [0], [ignore])
5744 AT_CHECK([ovs-ofctl -O OpenFlow11 dump-flows br0 | ofctl_strip | sort], [0], [dnl
5745 table=1, n_packets=3, n_bytes=180, dl_dst=50:54:00:00:00:0a actions=CONTROLLER:65535
5746 OFPST_FLOW reply (OF1.1):
5749 (echo "OFPST_TABLE reply (OF1.3) (xid=0x2):
5751 active=0, lookup=3, matched=0
5754 active=1, lookup=3, matched=3"
5756 while test $x -lt 254; do
5759 active=0, lookup=0, matched=0"
5762 AT_CHECK([ovs-ofctl -O OpenFlow13 dump-tables br0 ], [0], [expout])
5767 AT_SETUP([ofproto-dpif - ICMPv6])
5769 ADD_OF_PORTS([br0], 1)
5771 AT_CAPTURE_FILE([ofctl_monitor.log])
5773 AT_CHECK([ovs-ofctl monitor br0 65534 --detach --no-chdir --pidfile 2> ofctl_monitor.log])
5775 ovs-appctl netdev-dummy/receive p1 '0060970769ea0000860580da86dd6000000000203afffe80000000000000020086fffe0580dafe80000000000000026097fffe0769ea870068bd00000000fe80000000000000026097fffe0769ea01010000860580da'
5777 OVS_WAIT_UNTIL([ovs-appctl -t ovs-ofctl exit])
5779 AT_CHECK([cat ofctl_monitor.log], [0], [dnl
5780 NXT_PACKET_IN (xid=0x0): cookie=0x0 total_len=86 in_port=1 (via no_match) data_len=86 (unbuffered)
5781 icmp6,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=00:00:86:05:80:da,dl_dst=00:60:97:07:69:ea,ipv6_src=fe80::200:86ff:fe05:80da,ipv6_dst=fe80::260:97ff:fe07:69ea,ipv6_label=0x00000,nw_tos=0,nw_ecn=0,nw_ttl=255,icmp_type=135,icmp_code=0,nd_target=fe80::260:97ff:fe07:69ea,nd_sll=00:00:86:05:80:da,nd_tll=00:00:00:00:00:00