]> git.proxmox.com Git - mirror_ovs.git/blame - tests/ofp-print.at
flow: use rule priority in match_format() function
[mirror_ovs.git] / tests / ofp-print.at
CommitLineData
fec00620
BP
1AT_BANNER([ofp-print])
2
3AT_SETUP([empty])
4AT_KEYWORDS([ofp-print])
5AT_CHECK([ovs-ofctl ofp-print ''], [0], [OpenFlow message is empty
6])
7AT_CLEANUP
8
9AT_SETUP([too short])
10AT_KEYWORDS([ofp-print])
11AT_CHECK([ovs-ofctl ofp-print aabb], [0], [dnl
12OpenFlow packet too short (only 2 bytes):
1300000000 aa bb |.. |
14])
15AT_CLEANUP
16
17AT_SETUP([wrong OpenFlow version])
18AT_KEYWORDS([ofp-print])
90bf1e07
BP
19AT_CHECK([ovs-ofctl '-vPATTERN:console:%c|%p|%m' ofp-print 00bb0008eeff0011],
20 [0], [dnl
21***decode error: OFPBRC_BAD_TYPE***
2200000000 00 bb 00 08 ee ff 00 11- |........ |
982697a4 23], [ofp_msgs|WARN|unknown OpenFlow message (version 0, type 187)
fec00620
BP
24])
25AT_CLEANUP
26
27AT_SETUP([truncated message])
28AT_KEYWORDS([ofp-print])
f25b4a81 29AT_CHECK([ovs-ofctl ofp-print 0110ccddeeff0011], [0], [dnl
fec00620 30(***truncated to 8 bytes from 52445***)
f25b4a81 3100000000 01 10 cc dd ee ff 00 11- |........ |
fec00620
BP
32])
33AT_CLEANUP
34
35AT_SETUP([message only uses part of buffer])
36AT_KEYWORDS([ofp-print])
f25b4a81 37AT_CHECK([ovs-ofctl ofp-print 01100009eeff00112233], [0], [dnl
fec00620 38(***only uses 9 bytes out of 10***)
f25b4a81 3900000000 01 10 00 09 ee ff 00 11-22 33 |........"3 |
fec00620
BP
40])
41# "
42AT_CLEANUP
43
44AT_SETUP([OFPT_HELLO - ordinary])
45AT_KEYWORDS([ofp-print])
46AT_CHECK([ovs-ofctl ofp-print 0100000800000000], [0], [dnl
47OFPT_HELLO (xid=0x0):
de6c85b0 48 version bitmap: 0x01
fec00620
BP
49])
50AT_CLEANUP
51
52AT_SETUP([OFPT_HELLO with extra data])
53AT_KEYWORDS([ofp-print])
54AT_CHECK([ovs-ofctl ofp-print 0100001300000000657874726120646174610a], [0],
55[dnl
56OFPT_HELLO (xid=0x0):
de6c85b0
SH
57 version bitmap: 0x01
58 unknown data in hello:
5900000000 01 00 00 13 00 00 00 00-65 78 74 72 61 20 64 61 |........extra da|
6000000010 74 61 0a |ta. |
61])
62AT_CLEANUP
63
64AT_SETUP([OFPT_HELLO with version bitmap])
65AT_KEYWORDS([ofp-print])
66AT_CHECK([ovs-ofctl ofp-print "01 00 00 10 00 00 00 00 00 01 00 08 00 00 00 f0"], [0],
67[dnl
68OFPT_HELLO (xid=0x0):
69 version bitmap: 0x04, 0x05, 0x06, 0x07
70])
71AT_CLEANUP
72
73AT_SETUP([OFPT_HELLO with version bitmap and extra data])
74AT_KEYWORDS([ofp-print])
75AT_CHECK([ovs-ofctl ofp-print "\
7601 00 00 1b 00 00 00 00 ff ff 00 06 01 02 00 00 \
7700 01 00 08 00 00 00 f0 61 62 63"], [0],
78[dnl
79OFPT_HELLO (xid=0x0):
80 version bitmap: 0x04, 0x05, 0x06, 0x07
81 unknown data in hello:
8200000000 01 00 00 1b 00 00 00 00-ff ff 00 06 01 02 00 00 |................|
8300000010 00 01 00 08 00 00 00 f0-61 62 63 |........abc |
fec00620
BP
84])
85AT_CLEANUP
86
681ea7a0
BP
87AT_SETUP([OFPT_HELLO with higher than supported version])
88AT_KEYWORDS([ofp-print])
89AT_CHECK([ovs-ofctl ofp-print "0f 00 00 08 00 00 00 00"], [0],
90[dnl
91OFPT_HELLO (OF 0x0f) (xid=0x0):
92 version bitmap: 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f
93])
94AT_CHECK([ovs-ofctl ofp-print "40 00 00 08 00 00 00 00"], [0],
95[dnl
96OFPT_HELLO (OF 0x40) (xid=0x0):
97 version bitmap: 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f
98])
99AT_CHECK([ovs-ofctl ofp-print "3f 00 00 18 00 00 00 00 00 01 00 0c aa aa aa aa aa aa aa aa 00 00 00 00"], [0],
100[dnl
101OFPT_HELLO (OF 0x3f) (xid=0x0):
102 version bitmap: 0x01, 0x03, 0x05, 0x07, 0x09, 0x0b, 0x0d, 0x0f, 0x11, 0x13, 0x15, 0x17, 0x19, 0x1b, 0x1d, 0x1f
103])
104AT_CLEANUP
105
106AT_SETUP([OFPT_HELLO with contradictory version bitmaps])
107AT_KEYWORDS([ofp-print])
108dnl Bitmap claims support for no versions at all.
109AT_CHECK([ovs-ofctl '-vPATTERN:console:%c|%p|%m' ofp-print "01 00 00 10 00 00 00 00 00 01 00 08 00 00 00 00"], [0],
110[OFPT_HELLO (xid=0x0):
111 version bitmap: 0x01
112 unknown data in hello:
11300000000 01 00 00 10 00 00 00 00-00 01 00 08 00 00 00 00 |................|
114], [dnl
115ofp_util|WARN|peer does not support any OpenFlow version (between 0x01 and 0x1f)
116])
117dnl Bitmap claims support for only versions above 0x1f.
118AT_CHECK([ovs-ofctl '-vPATTERN:console:%c|%p|%m' ofp-print "3f 00 00 18 00 00 00 00 00 01 00 0c 00 00 00 00 aa aa aa aa 00 00 00 00"], [0],
119[OFPT_HELLO (OF 0x3f) (xid=0x0):
120 version bitmap: 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f
121 unknown data in hello:
12200000000 3f 00 00 18 00 00 00 00-00 01 00 0c 00 00 00 00 |?...............|
12300000010 aa aa aa aa 00 00 00 00- |........ |
124], [dnl
125ofp_util|WARN|peer does not support any OpenFlow version (between 0x01 and 0x1f)
126])
127dnl Bitmap claims support for nonexistent version 0x00.
128AT_CHECK([ovs-ofctl '-vPATTERN:console:%c|%p|%m' ofp-print "01 00 00 10 00 00 00 00 00 01 00 08 00 00 00 f1"], [0], [dnl
129OFPT_HELLO (xid=0x0):
130 version bitmap: 0x04, 0x05, 0x06, 0x07
131], [dnl
132ofp_util|WARN|peer claims to support invalid OpenFlow version 0x00
133])
134dnl Bitmap claims support for only nonexistent version 0x00.
135AT_CHECK([ovs-ofctl '-vPATTERN:console:%c|%p|%m' ofp-print "01 00 00 10 00 00 00 00 00 01 00 08 00 00 00 01"], [0], [dnl
136OFPT_HELLO (xid=0x0):
137 version bitmap: 0x01
138 unknown data in hello:
13900000000 01 00 00 10 00 00 00 00-00 01 00 08 00 00 00 01 |................|
140], [dnl
141ofp_util|WARN|peer claims to support invalid OpenFlow version 0x00
142ofp_util|WARN|peer does not support any OpenFlow version (between 0x01 and 0x1f)
143])
144AT_CLEANUP
145
2e0525bc 146dnl OFPT_ERROR tests are in ofp-errors.at.
90bf1e07 147
fec00620
BP
148AT_SETUP([OFPT_ECHO_REQUEST, empty payload])
149AT_KEYWORDS([ofp-print])
150AT_CHECK([ovs-ofctl ofp-print '01 02 00 08 00 00 00 01'], [0], [dnl
151OFPT_ECHO_REQUEST (xid=0x1): 0 bytes of payload
152])
153AT_CLEANUP
154
155AT_SETUP([OFPT_ECHO_REQUEST, 5-byte payload])
156AT_KEYWORDS([ofp-print])
157AT_CHECK([ovs-ofctl ofp-print '0102000d00000001 25 53 54 1a 9d'], [0], [dnl
158OFPT_ECHO_REQUEST (xid=0x1): 5 bytes of payload
15900000000 25 53 54 1a 9d |%ST.. |
160])
161AT_CLEANUP
162
163AT_SETUP([OFPT_ECHO_REPLY, empty payload])
164AT_KEYWORDS([ofp-print])
165AT_CHECK([ovs-ofctl ofp-print '01 03 00 08 00 00 00 01'], [0], [dnl
166OFPT_ECHO_REPLY (xid=0x1): 0 bytes of payload
167])
168AT_CLEANUP
169
170AT_SETUP([OFPT_ECHO_REPLY, 5-byte payload])
171AT_KEYWORDS([ofp-print])
172AT_CHECK([ovs-ofctl ofp-print '0103000d0000000ba330efaf9e'], [0], [dnl
173OFPT_ECHO_REPLY (xid=0xb): 5 bytes of payload
17400000000 a3 30 ef af 9e |.0... |
175])
176AT_CLEANUP
177
178AT_SETUP([OFPT_FEATURES_REQUEST])
179AT_KEYWORDS([ofp-print])
180AT_CHECK([ovs-ofctl ofp-print '0105000800000001'], [0], [dnl
181OFPT_FEATURES_REQUEST (xid=0x1):
182])
183AT_CLEANUP
184
9e1fd49b 185AT_SETUP([OFPT_FEATURES_REPLY - OF1.0])
fec00620
BP
186AT_KEYWORDS([ofp-print])
187AT_CHECK([ovs-ofctl ofp-print "\
18801 06 00 e0 00 00 00 01 00 00 50 54 00 00 00 01 \
18900 00 01 00 02 00 00 00 00 00 00 87 00 00 0f ff \
190ff fe 50 54 00 00 00 01 62 72 30 00 00 00 00 00 \
19100 00 00 00 00 00 00 00 00 00 00 01 00 00 00 01 \
19200 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
19300 03 50 54 00 00 00 01 65 74 68 30 00 00 00 00 \
19400 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
19500 00 02 08 00 00 02 8f 00 00 02 8f 00 00 00 00 \
19600 02 50 54 00 00 00 03 65 74 68 32 00 00 00 00 \
19700 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
19800 00 02 08 00 00 02 8f 00 00 02 8f 00 00 00 00 \
19900 01 50 54 00 00 00 02 65 74 68 31 00 00 00 00 \
20000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
20100 00 02 08 00 00 02 8f 00 00 02 8f 00 00 00 00 \
202"], [0], [dnl
9e1fd49b 203OFPT_FEATURES_REPLY (xid=0x1): dpid:0000505400000001
fec00620 204n_tables:2, n_buffers:256
9e1fd49b
BP
205capabilities: FLOW_STATS TABLE_STATS PORT_STATS ARP_MATCH_IP
206actions: OUTPUT SET_VLAN_VID SET_VLAN_PCP STRIP_VLAN SET_DL_SRC SET_DL_DST SET_NW_SRC SET_NW_DST SET_NW_TOS SET_TP_SRC SET_TP_DST ENQUEUE
0ab14c8e
BP
207 1(eth1): addr:50:54:00:00:00:02
208 config: 0
209 state: 0
210 current: 100MB-FD AUTO_NEG
211 advertised: 10MB-HD 10MB-FD 100MB-HD 100MB-FD COPPER AUTO_NEG
212 supported: 10MB-HD 10MB-FD 100MB-HD 100MB-FD COPPER AUTO_NEG
9e1fd49b 213 speed: 100 Mbps now, 100 Mbps max
0ab14c8e
BP
214 2(eth2): addr:50:54:00:00:00:03
215 config: 0
216 state: 0
217 current: 100MB-FD AUTO_NEG
218 advertised: 10MB-HD 10MB-FD 100MB-HD 100MB-FD COPPER AUTO_NEG
219 supported: 10MB-HD 10MB-FD 100MB-HD 100MB-FD COPPER AUTO_NEG
9e1fd49b 220 speed: 100 Mbps now, 100 Mbps max
0ab14c8e
BP
221 3(eth0): addr:50:54:00:00:00:01
222 config: 0
223 state: 0
224 current: 100MB-FD AUTO_NEG
225 advertised: 10MB-HD 10MB-FD 100MB-HD 100MB-FD COPPER AUTO_NEG
226 supported: 10MB-HD 10MB-FD 100MB-HD 100MB-FD COPPER AUTO_NEG
9e1fd49b 227 speed: 100 Mbps now, 100 Mbps max
0ab14c8e
BP
228 LOCAL(br0): addr:50:54:00:00:00:01
229 config: PORT_DOWN
230 state: LINK_DOWN
d02a5f8e 231 speed: 0 Mbps now, 0 Mbps max
fec00620
BP
232])
233AT_CLEANUP
234
9e1fd49b 235AT_SETUP([OFPT_FEATURES_REPLY cut off mid-port - OF1.0])
fec00620
BP
236AT_KEYWORDS([ofp-print])
237AT_CHECK([ovs-ofctl ofp-print "\
23801 06 00 dc 00 00 00 01 00 00 50 54 00 00 00 01 \
23900 00 01 00 02 00 00 00 00 00 00 87 00 00 0f ff \
240ff fe 50 54 00 00 00 01 62 72 30 00 00 00 00 00 \
24100 00 00 00 00 00 00 00 00 00 00 01 00 00 00 01 \
24200 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
24300 03 50 54 00 00 00 01 65 74 68 30 00 00 00 00 \
24400 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
24500 00 02 08 00 00 02 8f 00 00 02 8f 00 00 00 00 \
24600 02 50 54 00 00 00 03 65 74 68 32 00 00 00 00 \
24700 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
24800 00 02 08 00 00 02 8f 00 00 02 8f 00 00 00 00 \
24900 01 50 54 00 00 00 02 65 74 68 31 00 00 00 00 \
25000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
25100 00 02 08 00 00 02 8f 00 00 02 8f \
252"], [0], [dnl
90bf1e07 253***decode error: OFPBRC_BAD_LEN***
fec00620
BP
25400000000 01 06 00 dc 00 00 00 01-00 00 50 54 00 00 00 01 |..........PT....|
25500000010 00 00 01 00 02 00 00 00-00 00 00 87 00 00 0f ff |................|
25600000020 ff fe 50 54 00 00 00 01-62 72 30 00 00 00 00 00 |..PT....br0.....|
25700000030 00 00 00 00 00 00 00 00-00 00 00 01 00 00 00 01 |................|
25800000040 00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00 |................|
25900000050 00 03 50 54 00 00 00 01-65 74 68 30 00 00 00 00 |..PT....eth0....|
26000000060 00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00 |................|
26100000070 00 00 02 08 00 00 02 8f-00 00 02 8f 00 00 00 00 |................|
26200000080 00 02 50 54 00 00 00 03-65 74 68 32 00 00 00 00 |..PT....eth2....|
26300000090 00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00 |................|
264000000a0 00 00 02 08 00 00 02 8f-00 00 02 8f 00 00 00 00 |................|
265000000b0 00 01 50 54 00 00 00 02-65 74 68 31 00 00 00 00 |..PT....eth1....|
266000000c0 00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00 |................|
267000000d0 00 00 02 08 00 00 02 8f-00 00 02 8f |............ |
268], [stderr])
269AT_CHECK([sed 's/.*|//' stderr], [0], [dnl
5a020ef3 270received OFPT_FEATURES_REPLY with incorrect length 220 (must be exactly 32 bytes or longer by an integer multiple of 48 bytes)
fec00620
BP
271])
272AT_CLEANUP
273
9e1fd49b
BP
274AT_SETUP([OFPT_FEATURES_REPLY - OF1.1])
275AT_KEYWORDS([ofp-print])
276AT_CHECK([ovs-ofctl ofp-print "\
27702 06 00 a0 00 00 00 01 00 00 50 54 00 00 00 01 \
2e1ae200 27800 00 01 00 02 00 00 00 00 00 00 87 00 00 00 00 \
9e1fd49b
BP
279ff ff ff fe 00 00 00 00 50 54 00 00 00 01 00 00 \
28062 72 30 00 00 00 00 00 00 00 00 00 00 00 00 00 \
28100 00 00 01 00 00 00 01 00 00 00 00 00 00 00 00 \
28200 00 00 00 00 00 00 00 00 01 86 a0 00 01 86 a0 \
28300 00 00 03 00 00 00 00 50 54 00 00 00 01 00 00 \
28465 74 68 30 00 00 00 00 00 00 00 00 00 00 00 00 \
28500 00 00 00 00 00 00 00 00 00 20 08 00 00 28 0f \
28600 00 28 0f 00 00 00 00 00 01 86 a0 00 01 86 a0 \
287"], [0], [dnl
288OFPT_FEATURES_REPLY (OF1.1) (xid=0x1): dpid:0000505400000001
289n_tables:2, n_buffers:256
290capabilities: FLOW_STATS TABLE_STATS PORT_STATS ARP_MATCH_IP
9e1fd49b
BP
291 3(eth0): addr:50:54:00:00:00:01
292 config: 0
293 state: 0
294 current: 100MB-FD AUTO_NEG
295 advertised: 10MB-HD 10MB-FD 100MB-HD 100MB-FD COPPER AUTO_NEG
296 supported: 10MB-HD 10MB-FD 100MB-HD 100MB-FD COPPER AUTO_NEG
297 speed: 100 Mbps now, 100 Mbps max
298 LOCAL(br0): addr:50:54:00:00:00:01
299 config: PORT_DOWN
300 state: LINK_DOWN
301 speed: 100 Mbps now, 100 Mbps max
302])
303AT_CLEANUP
304
305AT_SETUP([OFPT_FEATURES_REPLY cut off mid-port - OF1.1])
306AT_KEYWORDS([ofp-print])
307AT_CHECK([ovs-ofctl ofp-print "\
30802 06 00 90 00 00 00 01 00 00 50 54 00 00 00 01 \
2e1ae200 30900 00 01 00 02 00 00 00 00 00 00 87 00 00 00 00 \
9e1fd49b
BP
310ff ff ff fe 00 00 00 00 50 54 00 00 00 01 00 00 \
31162 72 30 00 00 00 00 00 00 00 00 00 00 00 00 00 \
31200 00 00 01 00 00 00 01 00 00 00 00 00 00 00 00 \
31300 00 00 00 00 00 00 00 00 01 86 a0 00 01 86 a0 \
31400 00 00 03 00 00 00 00 50 54 00 00 00 01 00 00 \
31565 74 68 30 00 00 00 00 00 00 00 00 00 00 00 00 \
31600 00 00 00 00 00 00 00 00 00 20 08 00 00 28 0f \
317"], [0], [dnl
318***decode error: OFPBRC_BAD_LEN***
31900000000 02 06 00 90 00 00 00 01-00 00 50 54 00 00 00 01 |..........PT....|
2e1ae200 32000000010 00 00 01 00 02 00 00 00-00 00 00 87 00 00 00 00 |................|
9e1fd49b
BP
32100000020 ff ff ff fe 00 00 00 00-50 54 00 00 00 01 00 00 |........PT......|
32200000030 62 72 30 00 00 00 00 00-00 00 00 00 00 00 00 00 |br0.............|
32300000040 00 00 00 01 00 00 00 01-00 00 00 00 00 00 00 00 |................|
32400000050 00 00 00 00 00 00 00 00-00 01 86 a0 00 01 86 a0 |................|
32500000060 00 00 00 03 00 00 00 00-50 54 00 00 00 01 00 00 |........PT......|
32600000070 65 74 68 30 00 00 00 00-00 00 00 00 00 00 00 00 |eth0............|
32700000080 00 00 00 00 00 00 00 00-00 00 20 08 00 00 28 0f |.......... ...@{:@.|
328], [stderr])
329AT_CHECK([sed 's/.*|//' stderr], [0], [dnl
330received OFPT_FEATURES_REPLY with incorrect length 144 (must be exactly 32 bytes or longer by an integer multiple of 64 bytes)
331])
332AT_CLEANUP
333
60202987
SH
334AT_SETUP([OFPT_FEATURES_REPLY - OF1.2])
335AT_KEYWORDS([ofp-print])
336AT_CHECK([ovs-ofctl ofp-print "\
33703 06 00 a0 00 00 00 01 00 00 50 54 00 00 00 01 \
2e1ae200 33800 00 01 00 ff 00 00 00 00 00 01 77 00 00 00 00 \
60202987
SH
339ff ff ff fe 00 00 00 00 50 54 00 00 00 01 00 00 \
34062 72 30 0a 00 00 00 00 00 00 00 00 00 00 00 00 \
34100 00 00 01 00 00 00 01 00 00 00 00 00 00 00 00 \
34200 00 00 00 00 00 00 00 00 01 86 a0 00 01 86 a0 \
34300 00 00 03 00 00 00 00 50 54 00 00 00 01 00 00 \
34465 74 68 30 00 00 00 00 00 00 00 00 00 00 00 00 \
34500 00 00 00 00 00 00 00 00 00 20 08 00 00 28 0f \
34600 00 28 0f 00 00 00 00 00 01 86 a0 00 01 86 a0 \
347"], [0], [dnl
348OFPT_FEATURES_REPLY (OF1.2) (xid=0x1): dpid:0000505400000001
349n_tables:255, n_buffers:256
350capabilities: FLOW_STATS TABLE_STATS PORT_STATS IP_REASM QUEUE_STATS PORT_BLOCKED
351 3(eth0): addr:50:54:00:00:00:01
352 config: 0
353 state: 0
354 current: 100MB-FD AUTO_NEG
355 advertised: 10MB-HD 10MB-FD 100MB-HD 100MB-FD COPPER AUTO_NEG
356 supported: 10MB-HD 10MB-FD 100MB-HD 100MB-FD COPPER AUTO_NEG
357 speed: 100 Mbps now, 100 Mbps max
358 LOCAL(br0): addr:50:54:00:00:00:01
359 config: PORT_DOWN
360 state: LINK_DOWN
361 speed: 100 Mbps now, 100 Mbps max
362])
363AT_CLEANUP
364
365AT_SETUP([OFPT_FEATURES_REPLY cut off mid-port - OF1.2])
366AT_KEYWORDS([ofp-print])
367AT_CHECK([ovs-ofctl ofp-print "\
36803 06 00 a0 00 00 00 01 00 00 50 54 00 00 00 01 \
2e1ae200 36900 00 01 00 ff 00 00 00 00 00 01 77 00 00 00 00 \
60202987
SH
370ff ff ff fe 00 00 00 00 50 54 00 00 00 01 00 00 \
37162 72 30 0a 00 00 00 00 00 00 00 00 00 00 00 00 \
37200 00 00 01 00 00 00 01 00 00 00 00 00 00 00 00 \
37300 00 00 00 00 00 00 00 00 01 86 a0 00 01 86 a0 \
37400 00 00 03 00 00 00 00 50 54 00 00 00 01 00 00 \
37565 74 68 30 00 00 00 00 00 00 00 00 00 00 00 00 \
37600 00 00 00 00 00 00 00 00 00 20 08 00 00 28 0f \
377"], [0], [dnl
378OFPT_FEATURES_REPLY (OF1.2) (xid=0x1):
379(***truncated to 144 bytes from 160***)
38000000000 03 06 00 a0 00 00 00 01-00 00 50 54 00 00 00 01 |..........PT....|
2e1ae200 38100000010 00 00 01 00 ff 00 00 00-00 00 01 77 00 00 00 00 |...........w....|
60202987
SH
38200000020 ff ff ff fe 00 00 00 00-50 54 00 00 00 01 00 00 |........PT......|
38300000030 62 72 30 0a 00 00 00 00-00 00 00 00 00 00 00 00 |br0.............|
38400000040 00 00 00 01 00 00 00 01-00 00 00 00 00 00 00 00 |................|
38500000050 00 00 00 00 00 00 00 00-00 01 86 a0 00 01 86 a0 |................|
38600000060 00 00 00 03 00 00 00 00-50 54 00 00 00 01 00 00 |........PT......|
38700000070 65 74 68 30 00 00 00 00-00 00 00 00 00 00 00 00 |eth0............|
38800000080 00 00 00 00 00 00 00 00-00 00 20 08 00 00 28 0f |.......... ...@{:@.|
389], [stderr])
390AT_CHECK([sed 's/.*|//' stderr], [0], [dnl
391])
392AT_CLEANUP
393
2e1ae200
JR
394AT_SETUP([OFPT_FEATURES_REPLY - OF1.3])
395AT_KEYWORDS([ofp-print])
396AT_CHECK([ovs-ofctl ofp-print "\
39704 06 00 20 00 00 00 01 00 00 50 54 00 00 00 01 \
39800 00 01 00 ff 00 00 00 00 00 01 77 00 00 00 00 \
399"], [0], [dnl
400OFPT_FEATURES_REPLY (OF1.3) (xid=0x1): dpid:0000505400000001
401n_tables:255, n_buffers:256
402capabilities: FLOW_STATS TABLE_STATS PORT_STATS IP_REASM QUEUE_STATS PORT_BLOCKED
403])
404AT_CLEANUP
405
406AT_SETUP([OFPT_FEATURES_REPLY - with auxiliary_id - OF1.3])
407AT_KEYWORDS([ofp-print])
408AT_CHECK([ovs-ofctl ofp-print "\
40904 06 00 20 00 00 00 01 00 00 50 54 00 00 00 01 \
41000 00 01 00 ff 01 00 00 00 00 01 77 00 00 00 00 \
411"], [0], [dnl
412OFPT_FEATURES_REPLY (OF1.3) (xid=0x1): dpid:0000505400000001
413n_tables:255, n_buffers:256, auxiliary_id:1
414capabilities: FLOW_STATS TABLE_STATS PORT_STATS IP_REASM QUEUE_STATS PORT_BLOCKED
415])
416AT_CLEANUP
417
fec00620
BP
418AT_SETUP([OFPT_GET_CONFIG_REQUEST])
419AT_KEYWORDS([ofp-print])
420AT_CHECK([ovs-ofctl ofp-print '0107000800000001'], [0], [dnl
421OFPT_GET_CONFIG_REQUEST (xid=0x1):
422])
423AT_CLEANUP
424
425AT_SETUP([OFPT_GET_CONFIG_REPLY, most common form])
426AT_KEYWORDS([ofp-print])
427AT_CHECK([ovs-ofctl ofp-print '01 08 00 0c 00 00 00 03 00 00 00 00'], [0], [dnl
428OFPT_GET_CONFIG_REPLY (xid=0x3): frags=normal miss_send_len=0
429])
430AT_CLEANUP
431
432
433AT_SETUP([OFPT_GET_CONFIG_REPLY, frags and miss_send_len])
434AT_KEYWORDS([ofp-print])
435AT_CHECK([ovs-ofctl ofp-print '01 08 00 0c 00 00 00 03 00 02 00 ff'], [0], [dnl
436OFPT_GET_CONFIG_REPLY (xid=0x3): frags=reassemble miss_send_len=255
437])
438AT_CLEANUP
439
7cfb9651 440AT_SETUP([OFPT_PACKET_IN - OF1.0])
fec00620 441AT_KEYWORDS([ofp-print])
fec00620
BP
442AT_CHECK([ovs-ofctl ofp-print "\
44301 0a 00 4e 00 00 00 00 00 00 01 11 00 3c 00 03 \
44400 00 50 54 00 00 00 06 50 54 00 00 00 05 08 00 \
44545 00 00 28 bd 12 00 00 40 06 3c 6a c0 a8 00 01 \
446c0 a8 00 02 27 2f 00 00 78 50 cc 5b 57 af 42 1e \
44750 00 02 00 26 e8 00 00 00 00 00 00 00 00 \
897a8e07 448"], [0], [dnl
f0fd1a17 449OFPT_PACKET_IN (xid=0x0): total_len=60 in_port=3 (via no_match) data_len=60 buffer=0x00000111
3f78c3cc 450tcp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:06,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=64,tp_src=10031,tp_dst=0 tcp_csum:26e8
fec00620
BP
451])
452AT_CLEANUP
453
7cfb9651
SH
454AT_SETUP([OFPT_PACKET_IN - OF1.2])
455AT_KEYWORDS([ofp-print])
456AT_CHECK([ovs-ofctl ofp-print "\
45703 0a 00 4c 00 00 00 00 ff ff ff 00 00 2a 00 00 \
45800 01 00 0c 80 00 00 04 ff ff ff fe 00 00 00 00 \
45900 00 ff ff ff ff ff ff 00 23 20 83 c1 5f 80 35 \
46000 01 08 00 06 04 00 03 00 23 20 83 c1 5f 00 00 \
46100 00 00 23 20 83 c1 5f 00 00 00 00 \
462"], [0], [dnl
463OFPT_PACKET_IN (OF1.2) (xid=0x0): total_len=42 in_port=LOCAL (via no_match) data_len=42 buffer=0xffffff00
3f78c3cc 464rarp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=00:23:20:83:c1:5f,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=0.0.0.0,arp_tpa=0.0.0.0,arp_op=3,arp_sha=00:23:20:83:c1:5f,arp_tha=00:23:20:83:c1:5f
7cfb9651
SH
465])
466AT_CLEANUP
467
2e1ae200
JR
468AT_SETUP([OFPT_PACKET_IN - OF1.3])
469AT_KEYWORDS([ofp-print])
470AT_CHECK([ovs-ofctl ofp-print "\
47104 0a 00 54 00 00 00 00 ff ff ff 00 00 2a 00 00 \
47201 02 03 04 05 06 07 08 00 01 00 0c 80 00 00 04 \
473ff ff ff fe 00 00 00 00 00 00 ff ff ff ff ff ff \
47400 23 20 83 c1 5f 80 35 00 01 08 00 06 04 00 03 \
47500 23 20 83 c1 5f 00 00 00 00 00 23 20 83 c1 5f \
47600 00 00 00 \
477"], [0], [dnl
478OFPT_PACKET_IN (OF1.3) (xid=0x0): cookie=0x102030405060708 total_len=42 in_port=LOCAL (via no_match) data_len=42 buffer=0xffffff00
3f78c3cc 479rarp,metadata=0,in_port=0,vlan_tci=0x0000,dl_src=00:23:20:83:c1:5f,dl_dst=ff:ff:ff:ff:ff:ff,arp_spa=0.0.0.0,arp_tpa=0.0.0.0,arp_op=3,arp_sha=00:23:20:83:c1:5f,arp_tha=00:23:20:83:c1:5f
2e1ae200
JR
480])
481AT_CLEANUP
482
eefbf181 483AT_SETUP([OFPT_FLOW_REMOVED - OF1.0])
fec00620
BP
484AT_KEYWORDS([ofp-print])
485AT_CHECK([ovs-ofctl ofp-print "\
48601 0b 00 58 00 00 00 00 00 00 00 00 00 03 50 54 \
48700 00 00 05 50 54 00 00 00 06 ff ff 00 00 08 06 \
48800 02 00 00 c0 a8 00 01 c0 a8 00 02 00 00 00 00 \
48900 00 00 00 00 00 00 00 ff ff 00 00 00 00 00 05 \
49030 e0 35 00 00 05 00 00 00 00 00 00 00 00 00 01 \
49100 00 00 00 00 00 00 3c \
492"], [0], [dnl
666d0863 493OFPT_FLOW_REMOVED (xid=0x0): priority=65535,arp,in_port=3,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:06,arp_spa=192.168.0.1,arp_tpa=192.168.0.2,arp_op=2,nw_tos=0,tp_src=0,tp_dst=0 reason=idle duration5.82s idle5 pkts1 bytes60
fec00620
BP
494])
495AT_CLEANUP
496
eefbf181
SH
497AT_SETUP([OFPT_FLOW_REMOVED - OF1.2])
498AT_KEYWORDS([ofp-print])
499AT_CHECK([ovs-ofctl ofp-print "\
50003 0b 00 40 00 00 00 00 fe dc ba 98 76 54 32 10 \
50180 00 01 05 00 00 00 01 00 98 96 80 00 3c 00 78 \
50200 00 00 00 00 12 d6 87 00 00 00 00 6f 68 ba 66 \
50300 01 00 0a 80 00 0c 02 10 09 00 00 00 00 00 00"], [0], [dnl
95216219 504OFPT_FLOW_REMOVED (OF1.2) (xid=0x0): dl_vlan=9 reason=hard table_id=5 cookie:0xfedcba9876543210 duration1.01s idle60 hard120 pkts1234567 bytes1869134438
eefbf181
SH
505])
506AT_CLEANUP
507
2e1ae200
JR
508AT_SETUP([OFPT_FLOW_REMOVED - OF1.3])
509AT_KEYWORDS([ofp-print])
510AT_CHECK([ovs-ofctl ofp-print "\
51104 0b 00 40 00 00 00 00 fe dc ba 98 76 54 32 10 \
51280 00 01 05 00 00 00 01 00 98 96 80 00 3c 00 78 \
51300 00 00 00 00 12 d6 87 00 00 00 00 6f 68 ba 66 \
51400 01 00 0a 80 00 0c 02 10 09 00 00 00 00 00 00"], [0], [dnl
515OFPT_FLOW_REMOVED (OF1.3) (xid=0x0): dl_vlan=9 reason=hard table_id=5 cookie:0xfedcba9876543210 duration1.01s idle60 hard120 pkts1234567 bytes1869134438
516])
517AT_CLEANUP
518
9e1fd49b 519AT_SETUP([OFPT_PORT_STATUS - OF1.0])
fec00620
BP
520AT_KEYWORDS([ofp-print])
521AT_CHECK([ovs-ofctl ofp-print "\
52201 0c 00 40 00 00 00 00 02 00 00 00 00 00 00 00 \
52300 03 50 54 00 00 00 01 65 74 68 30 00 00 00 00 \
52400 00 00 00 00 00 00 00 00 00 00 01 00 00 00 01 \
52500 00 02 08 00 00 02 8f 00 00 02 8f 00 00 00 00 \
526"], [0], [dnl
0ab14c8e
BP
527OFPT_PORT_STATUS (xid=0x0): MOD: 3(eth0): addr:50:54:00:00:00:01
528 config: PORT_DOWN
529 state: LINK_DOWN
530 current: 100MB-FD AUTO_NEG
531 advertised: 10MB-HD 10MB-FD 100MB-HD 100MB-FD COPPER AUTO_NEG
532 supported: 10MB-HD 10MB-FD 100MB-HD 100MB-FD COPPER AUTO_NEG
9e1fd49b
BP
533 speed: 100 Mbps now, 100 Mbps max
534])
535AT_CLEANUP
536
537AT_SETUP([OFPT_PORT_STATUS - OF1.1])
538AT_KEYWORDS([ofp-print])
539AT_CHECK([ovs-ofctl ofp-print "\
54002 0c 00 50 00 00 00 00 02 00 00 00 00 00 00 00 \
54100 00 00 03 00 00 00 00 50 54 00 00 00 01 00 00 \
54265 74 68 30 00 00 00 00 00 00 00 00 00 00 00 00 \
54300 00 00 00 00 00 00 00 00 00 20 08 00 00 28 0f \
54400 00 28 0f 00 00 00 00 00 01 86 a0 00 01 86 a0 \
545"], [0], [dnl
546OFPT_PORT_STATUS (OF1.1) (xid=0x0): MOD: 3(eth0): addr:50:54:00:00:00:01
547 config: 0
548 state: 0
549 current: 100MB-FD AUTO_NEG
550 advertised: 10MB-HD 10MB-FD 100MB-HD 100MB-FD COPPER AUTO_NEG
551 supported: 10MB-HD 10MB-FD 100MB-HD 100MB-FD COPPER AUTO_NEG
552 speed: 100 Mbps now, 100 Mbps max
fec00620
BP
553])
554AT_CLEANUP
555
eb5ee596 556AT_SETUP([OFPT_PACKET_OUT - OF1.0])
fec00620
BP
557AT_KEYWORDS([ofp-print])
558AT_CHECK([ovs-ofctl ofp-print "\
55901 0d 00 54 00 00 00 00 00 00 01 14 00 01 00 08 \
56000 00 00 08 00 03 00 00 50 54 00 00 00 05 50 54 \
56100 00 00 06 08 00 45 00 00 28 00 00 40 00 40 06 \
562b9 7c c0 a8 00 02 c0 a8 00 01 00 00 2b 60 00 00 \
56300 00 6a 4f 2b 58 50 14 00 00 6d 75 00 00 00 00 \
56400 00 00 00 \
565"], [0], [dnl
c6a93eb7 566OFPT_PACKET_OUT (xid=0x0): in_port=1 actions=output:3 buffer=0x00000114
fec00620
BP
567])
568AT_CLEANUP
569
eb5ee596
SH
570AT_SETUP([OFPT_PACKET_OUT - OF1.1])
571AT_KEYWORDS([ofp-print])
572AT_CHECK([ovs-ofctl ofp-print "\
57303 0d 00 28 88 58 df c5 ff ff ff 00 ff ff ff fe \
57400 10 00 00 00 00 00 00 00 00 00 10 ff ff ff fb \
57505 dc 00 00 00 00 00 00 \
576"], [0], [dnl
577OFPT_PACKET_OUT (OF1.2) (xid=0x8858dfc5): in_port=LOCAL actions=FLOOD buffer=0xffffff00
578])
579AT_CLEANUP
580
fec00620 581# The flow is formatted with cls_rule_format() for the low-verbosity case.
1bf6eeb0 582AT_SETUP([OFPT_FLOW_MOD - OF1.0 - low verbosity])
fec00620 583AT_KEYWORDS([ofp-print])
1c0b7503 584AT_CHECK([ovs-ofctl '-vPATTERN:console:%c|%p|%m' ofp-print "\
fec00620
BP
58501 0e 00 50 00 00 00 00 00 00 00 00 00 01 50 54 \
58600 00 00 06 50 54 00 00 00 05 ff ff 00 00 08 06 \
58700 02 00 00 c0 a8 00 02 c0 a8 00 01 00 00 00 00 \
58800 00 00 00 00 00 00 00 00 00 00 05 00 00 00 00 \
58900 00 01 0e 00 00 00 00 00 00 00 08 00 03 00 00 \
590" 2], [0], [dnl
666d0863 591OFPT_FLOW_MOD (xid=0x0): ADD priority=65535,arp,in_port=1,vlan_tci=0x0000,dl_src=50:54:00:00:00:06,dl_dst=50:54:00:00:00:05,arp_spa=192.168.0.2,arp_tpa=192.168.0.1,arp_op=2 idle:5 buf:0x10e out_port:0 actions=output:3
1c0b7503
BP
592], [dnl
593ofp_util|INFO|normalization changed ofp_match, details:
666d0863
MM
594ofp_util|INFO| pre: arp,in_port=1,vlan_tci=0x0000,dl_src=50:54:00:00:00:06,dl_dst=50:54:00:00:00:05,arp_spa=192.168.0.2,arp_tpa=192.168.0.1,arp_op=2,nw_tos=0,tp_src=0,tp_dst=0
595ofp_util|INFO|post: arp,in_port=1,vlan_tci=0x0000,dl_src=50:54:00:00:00:06,dl_dst=50:54:00:00:00:05,arp_spa=192.168.0.2,arp_tpa=192.168.0.1,arp_op=2
fec00620
BP
596])
597AT_CLEANUP
598
1bf6eeb0
SH
599# The flow is formatted with cls_rule_format() for the low-verbosity case.
600AT_SETUP([OFPT_FLOW_MOD - OF1.2 - low verbosity])
601AT_KEYWORDS([ofp-print])
602AT_CHECK([ovs-ofctl '-vPATTERN:console:%c|%p|%m' ofp-print "\
60303 0e 00 90 00 00 00 02 00 00 00 00 00 00 00 00 \
60400 00 00 00 00 00 00 00 ff 00 00 00 00 00 ff ff \
605ff ff ff ff ff ff ff ff ff ff ff ff 00 00 00 00 \
60600 01 00 42 80 00 00 04 00 00 00 01 80 00 08 06 \
60750 54 00 00 00 06 80 00 06 06 50 54 00 00 00 05 \
60880 00 0a 02 08 06 80 00 0c 02 00 00 80 00 2a 02 \
60900 02 80 00 2c 04 c0 a8 00 02 80 00 2e 04 c0 a8 \
61000 01 00 00 00 00 00 00 00 04 00 18 00 00 00 00 \
61100 00 00 10 00 00 00 03 00 00 00 00 00 00 00 00 \
612" 2], [0], [dnl
666d0863 613OFPT_FLOW_MOD (OF1.2) (xid=0x2): ADD table:255 priority=65535,arp,in_port=1,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:06,dl_dst=50:54:00:00:00:05,arp_spa=192.168.0.2,arp_tpa=192.168.0.1,arp_op=2 actions=output:3
1bf6eeb0
SH
614], [dnl
615])
616AT_CLEANUP
617
eec25dc1
BP
618# The flow is formatted with ofp10_match_to_string() for the
619# high-verbosity case.
1bf6eeb0 620AT_SETUP([OFPT_FLOW_MOD - OF1.0 - high verbosity])
fec00620 621AT_KEYWORDS([ofp-print])
1c0b7503 622AT_CHECK([ovs-ofctl '-vPATTERN:console:%c|%p|%m' ofp-print "\
fec00620
BP
62301 0e 00 50 00 00 00 00 00 00 00 00 00 01 50 54 \
62400 00 00 06 50 54 00 00 00 05 ff ff 00 00 08 06 \
62500 02 00 00 c0 a8 00 02 c0 a8 00 01 00 00 00 00 \
62600 00 00 00 00 00 00 00 00 00 00 05 00 00 00 00 \
62700 00 01 0e 00 00 00 00 00 00 00 08 00 03 00 00 \
628" 3], [0], [dnl
de0f16bc 629OFPT_FLOW_MOD (xid=0x0): ADD arp,in_port=1,dl_vlan=65535,dl_vlan_pcp=0,dl_src=50:54:00:00:00:06,dl_dst=50:54:00:00:00:05,nw_src=192.168.0.2,nw_dst=192.168.0.1,arp_op=2,nw_tos=0,tp_src=0,tp_dst=0 idle:5 pri:65535 buf:0x10e out_port:0 actions=output:3
1c0b7503
BP
630], [dnl
631ofp_util|INFO|normalization changed ofp_match, details:
666d0863
MM
632ofp_util|INFO| pre: arp,in_port=1,vlan_tci=0x0000,dl_src=50:54:00:00:00:06,dl_dst=50:54:00:00:00:05,arp_spa=192.168.0.2,arp_tpa=192.168.0.1,arp_op=2,nw_tos=0,tp_src=0,tp_dst=0
633ofp_util|INFO|post: arp,in_port=1,vlan_tci=0x0000,dl_src=50:54:00:00:00:06,dl_dst=50:54:00:00:00:05,arp_spa=192.168.0.2,arp_tpa=192.168.0.1,arp_op=2
fec00620
BP
634])
635AT_CLEANUP
636
1bf6eeb0
SH
637# The flow is formatted with cls_rule_format() for the low-verbosity case.
638AT_SETUP([OFPT_FLOW_MOD - OF1.2 - low verbosity])
639AT_KEYWORDS([ofp-print])
640AT_CHECK([ovs-ofctl '-vPATTERN:console:%c|%p|%m' ofp-print "\
64103 0e 00 90 00 00 00 02 00 00 00 00 00 00 00 00 \
64200 00 00 00 00 00 00 00 ff 00 00 00 00 00 ff ff \
643ff ff ff ff ff ff ff ff ff ff ff ff 00 00 00 00 \
64400 01 00 42 80 00 00 04 00 00 00 01 80 00 08 06 \
64550 54 00 00 00 06 80 00 06 06 50 54 00 00 00 05 \
64680 00 0a 02 08 06 80 00 0c 02 00 00 80 00 2a 02 \
64700 02 80 00 2c 04 c0 a8 00 02 80 00 2e 04 c0 a8 \
64800 01 00 00 00 00 00 00 00 04 00 18 00 00 00 00 \
64900 00 00 10 00 00 00 03 00 00 00 00 00 00 00 00 \
650" 2], [0], [dnl
666d0863 651OFPT_FLOW_MOD (OF1.2) (xid=0x2): ADD table:255 priority=65535,arp,in_port=1,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:06,dl_dst=50:54:00:00:00:05,arp_spa=192.168.0.2,arp_tpa=192.168.0.1,arp_op=2 actions=output:3
1bf6eeb0
SH
652], [dnl
653])
654AT_CLEANUP
655
2e1ae200
JR
656# The flow is formatted with cls_rule_format() for the low-verbosity case.
657AT_SETUP([OFPT_FLOW_MOD - OF1.3 - flags - low verbosity])
658AT_KEYWORDS([ofp-print])
659AT_CHECK([ovs-ofctl '-vPATTERN:console:%c|%p|%m' ofp-print "\
66004 0e 00 90 00 00 00 02 00 00 00 00 00 00 00 00 \
66100 00 00 00 00 00 00 00 ff 00 00 00 00 00 ff ff \
662ff ff ff ff ff ff ff ff ff ff ff ff 00 1f 00 00 \
66300 01 00 42 80 00 00 04 00 00 00 01 80 00 08 06 \
66450 54 00 00 00 06 80 00 06 06 50 54 00 00 00 05 \
66580 00 0a 02 08 06 80 00 0c 02 00 00 80 00 2a 02 \
66600 02 80 00 2c 04 c0 a8 00 02 80 00 2e 04 c0 a8 \
66700 01 00 00 00 00 00 00 00 04 00 18 00 00 00 00 \
66800 00 00 10 00 00 00 03 00 00 00 00 00 00 00 00 \
669" 2], [0], [dnl
670OFPT_FLOW_MOD (OF1.3) (xid=0x2): ADD table:255 priority=65535,arp,in_port=1,vlan_tci=0x0000/0x1fff,dl_src=50:54:00:00:00:06,dl_dst=50:54:00:00:00:05,arp_spa=192.168.0.2,arp_tpa=192.168.0.1,arp_op=2 send_flow_rem check_overlap reset_counts no_packet_counts no_byte_counts actions=output:3
671], [dnl
672])
673AT_CLEANUP
674
d55b18c8
IY
675AT_SETUP([OFPT_FLOW_MOD - OF1.2 - set-field ip_src])
676AT_KEYWORDS([ofp-print])
677AT_CHECK([ovs-ofctl '-vPATTERN:console:%c|%p|%m' ofp-print "\
67803 0e 00 58 52 33 45 02 00 00 00 00 00 00 00 00 \
67900 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ff \
680ff ff ff ff ff ff ff ff ff ff ff ff 00 00 00 00 \
68100 01 00 0a 80 00 0a 02 08 00 00 00 00 00 00 00 \
68200 04 00 18 00 00 00 00 00 19 00 10 80 00 16 04 \
683c0 a8 03 5c 00 00 00 00 \
684" 2], [0], [dnl
685OFPT_FLOW_MOD (OF1.2) (xid=0x52334502): ADD priority=255,ip actions=set_field:192.168.3.92->ip_src
686], [dnl
687])
688AT_CLEANUP
689
690AT_SETUP([OFPT_FLOW_MOD - OF1.2 - set-field ip_dst])
691AT_KEYWORDS([ofp-print])
692AT_CHECK([ovs-ofctl '-vPATTERN:console:%c|%p|%m' ofp-print "\
69303 0e 00 58 52 33 45 07 00 00 00 00 00 00 00 00 \
69400 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ff \
695ff ff ff ff ff ff ff ff ff ff ff ff 00 00 00 00 \
69600 01 00 0a 80 00 0a 02 08 00 00 00 00 00 00 00 \
69700 04 00 18 00 00 00 00 00 19 00 10 80 00 18 04 \
698c0 a8 4a 7a 00 00 00 00 \
699" 2], [0], [dnl
700OFPT_FLOW_MOD (OF1.2) (xid=0x52334507): ADD priority=255,ip actions=set_field:192.168.74.122->ip_dst
701], [dnl
702])
703AT_CLEANUP
704
705AT_SETUP([OFPT_FLOW reply - OF1.2 - set-field ip_src])
706AT_KEYWORDS([ofp-print])
707AT_CHECK([ovs-ofctl '-vPATTERN:console:%c|%p|%m' ofp-print "\
70803 13 00 68 52 33 45 04 00 01 00 00 00 00 00 00 \
70900 58 00 00 00 00 00 00 00 00 00 00 00 ff 00 00 \
71000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
71100 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
71200 01 00 0a 80 00 0a 02 08 00 00 00 00 00 00 00 \
71300 04 00 18 00 00 00 00 00 19 00 10 80 00 16 04 \
714c0 a8 03 5c 00 00 00 00 \
715" 2], [0], [dnl
716OFPST_FLOW reply (OF1.2) (xid=0x52334504):
717 cookie=0x0, duration=0s, table=0, n_packets=0, n_bytes=0, priority=255,ip actions=set_field:192.168.3.92->ip_src
718], [dnl
719])
720AT_CLEANUP
721
722AT_SETUP([OFPT_FLOW reply - OF1.2 - set-field ip_dst])
723AT_KEYWORDS([ofp-print])
724AT_CHECK([ovs-ofctl '-vPATTERN:console:%c|%p|%m' ofp-print "\
72503 13 00 68 52 33 45 09 00 01 00 00 00 00 00 00 \
72600 58 00 00 00 00 00 00 00 00 00 00 00 ff 00 00 \
72700 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
72800 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
72900 01 00 0a 80 00 0a 02 08 00 00 00 00 00 00 00 \
73000 04 00 18 00 00 00 00 00 19 00 10 80 00 18 04 \
731c0 a8 4a 7a 00 00 00 00 \
732" 2], [0], [dnl
733OFPST_FLOW reply (OF1.2) (xid=0x52334509):
734 cookie=0x0, duration=0s, table=0, n_packets=0, n_bytes=0, priority=255,ip actions=set_field:192.168.74.122->ip_dst
735], [dnl
736])
737AT_CLEANUP
738
9e1fd49b 739AT_SETUP([OFPT_PORT_MOD - OF1.0])
fec00620
BP
740AT_KEYWORDS([ofp-print])
741AT_CHECK([ovs-ofctl ofp-print "\
74201 0f 00 20 00 00 00 03 00 03 50 54 00 00 00 01 \
74300 00 00 01 00 00 00 01 00 00 00 00 00 00 00 00 \
744" 3], [0], [dnl
9e1fd49b
BP
745OFPT_PORT_MOD (xid=0x3):port: 3: addr:50:54:00:00:00:01
746 config: PORT_DOWN
747 mask: PORT_DOWN
748 advertise: UNCHANGED
749])
750AT_CLEANUP
751
752AT_SETUP([OFPT_PORT_MOD - OF1.1])
753AT_KEYWORDS([ofp-print])
754AT_CHECK([ovs-ofctl ofp-print "\
75502 10 00 28 00 00 00 03 00 00 00 03 00 00 00 00 \
75650 54 00 00 00 01 00 00 00 00 00 01 00 00 00 01 \
75700 00 00 00 00 00 00 00 \
758" 3], [0], [dnl
759OFPT_PORT_MOD (OF1.1) (xid=0x3):port: 3: addr:50:54:00:00:00:01
760 config: PORT_DOWN
761 mask: PORT_DOWN
fec00620
BP
762 advertise: UNCHANGED
763])
764AT_CLEANUP
765
bb2bc3c1
SH
766AT_SETUP([OFPT_PORT_MOD - OF1.2])
767AT_KEYWORDS([ofp-print])
768AT_CHECK([ovs-ofctl ofp-print "\
76903 10 00 28 00 00 00 03 00 00 00 03 00 00 00 00 \
77050 54 00 00 00 01 00 00 00 00 00 01 00 00 00 01 \
77100 00 00 00 00 00 00 00 \
772" 3], [0], [dnl
773OFPT_PORT_MOD (OF1.2) (xid=0x3):port: 3: addr:50:54:00:00:00:01
774 config: PORT_DOWN
775 mask: PORT_DOWN
776 advertise: UNCHANGED
777])
778AT_CLEANUP
779
2e1ae200
JR
780AT_SETUP([OFPT_PORT_MOD - OF1.3])
781AT_KEYWORDS([ofp-print])
782AT_CHECK([ovs-ofctl ofp-print "\
78304 10 00 28 00 00 00 03 00 00 00 03 00 00 00 00 \
78450 54 00 00 00 01 00 00 00 00 00 01 00 00 00 01 \
78500 00 00 00 00 00 00 00 \
786" 3], [0], [dnl
787OFPT_PORT_MOD (OF1.3) (xid=0x3):port: 3: addr:50:54:00:00:00:01
788 config: PORT_DOWN
789 mask: PORT_DOWN
790 advertise: UNCHANGED
791])
792AT_CLEANUP
793
fec00620
BP
794AT_SETUP([OFPST_DESC request])
795AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
796AT_CHECK([ovs-ofctl ofp-print "0110000c0000000100000000"], [0], [dnl
797OFPST_DESC request (xid=0x1):
798])
799AT_CLEANUP
800
801AT_SETUP([OFPST_DESC reply])
802AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
803AT_CHECK([ovs-ofctl ofp-print "\
80401 11 04 2c 00 00 00 01 00 00 00 00 4e 69 63 69 \
e0edde6f
RS
80572 61 2c 20 49 6e 63 2e 00 00 00 00 00 00 00 00 \
80600 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
fec00620
BP
80700 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
80800 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
80900 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
81000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
81100 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
81200 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
81300 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
81400 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
81500 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
81600 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
81700 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
81800 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
81900 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
82000 00 00 00 00 00 00 00 00 00 00 00 4f 70 65 6e \
82120 76 53 77 69 74 63 68 00 00 00 00 00 00 00 00 \
82200 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
82300 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
82400 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
82500 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
82600 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
82700 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
82800 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
82900 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
83000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
83100 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
83200 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
83300 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
83400 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
83500 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
83600 00 00 00 00 00 00 00 00 00 00 00 31 2e 31 2e \
83730 70 72 65 32 00 00 00 00 00 00 00 00 00 00 00 \
83800 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
83900 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
84000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
84100 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
84200 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
84300 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
84400 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
84500 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
84600 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
84700 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
84800 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
84900 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
85000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
85100 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
85200 00 00 00 00 00 00 00 00 00 00 00 4e 6f 6e 65 \
85300 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
85400 00 00 00 00 00 00 00 00 00 00 00 4e 6f 6e 65 \
85500 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
85600 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
85700 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
85800 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
85900 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
86000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
86100 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
86200 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
86300 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
86400 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
86500 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
86600 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
86700 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
86800 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
86900 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
87000 00 00 00 00 00 00 00 00 00 00 00 \
871"], [0], [dnl
872OFPST_DESC reply (xid=0x1):
e0edde6f 873Manufacturer: Nicira, Inc.
fec00620
BP
874Hardware: Open vSwitch
875Software: 1.1.0pre2
876Serial Num: None
877DP Description: None
878])
879AT_CLEANUP
880
0157ad3a 881AT_SETUP([OFPST_FLOW request - OF1.0])
fec00620
BP
882AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
883AT_CHECK([ovs-ofctl ofp-print "\
88401 10 00 38 00 00 00 04 00 01 00 00 00 38 20 ff \
885ff fe 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
88600 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
88700 00 00 00 ff 00 ff ff \
888"], [0], [dnl
54ae6fa8 889OFPST_FLOW request (xid=0x4): @&t@
fec00620
BP
890])
891AT_CLEANUP
892
0157ad3a
SH
893AT_SETUP([OFPST_FLOW request - OF1.2])
894AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
895AT_CHECK([ovs-ofctl ofp-print "\
89603 12 00 38 00 00 00 02 00 01 00 00 00 00 00 00 \
897ff 00 00 00 ff ff ff ff ff ff ff ff 00 00 00 00 \
89800 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
89900 01 00 04 00 00 00 00 \
900"], [0], [dnl
901OFPST_FLOW request (OF1.2) (xid=0x2): @&t@
902])
903AT_CLEANUP
904
2e1ae200
JR
905AT_SETUP([OFPST_FLOW request - OF1.3])
906AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
907AT_CHECK([ovs-ofctl ofp-print "\
90804 12 00 38 00 00 00 02 00 01 00 00 00 00 00 00 \
909ff 00 00 00 ff ff ff ff ff ff ff ff 00 00 00 00 \
91000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
91100 01 00 04 00 00 00 00 \
912"], [0], [dnl
913OFPST_FLOW request (OF1.3) (xid=0x2): @&t@
914])
915AT_CLEANUP
916
6ec5f0c5 917AT_SETUP([OFPST_FLOW reply - OF1.0])
fec00620
BP
918AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
919AT_CHECK([ovs-ofctl ofp-print "\
05b8f1c2 92001 11 01 e4 00 00 00 04 00 01 00 00 00 60 00 00 \
fec00620
BP
92100 00 00 00 00 03 50 54 00 00 00 05 50 54 00 00 \
92200 06 ff ff 00 00 08 06 00 02 00 00 c0 a8 00 01 \
923c0 a8 00 02 00 00 00 00 00 00 00 04 0b eb c2 00 \
924ff ff 00 05 00 00 00 00 00 00 00 00 00 00 00 00 \
92500 00 00 00 00 00 00 00 00 00 00 01 00 00 00 00 \
92600 00 00 3c 00 00 00 08 00 01 00 00 00 60 00 00 \
92700 00 00 00 00 01 50 54 00 00 00 06 50 54 00 00 \
92800 05 ff ff 00 00 08 00 00 01 00 00 c0 a8 00 02 \
929c0 a8 00 01 00 00 00 00 00 00 00 08 35 a4 e9 00 \
930ff ff 00 05 00 00 00 00 00 00 00 00 00 00 00 00 \
93100 00 00 00 00 00 00 00 00 00 00 0d 00 00 00 00 \
93200 00 04 fa 00 00 00 08 00 03 00 00 00 60 00 00 \
93300 00 00 00 00 01 50 54 00 00 00 06 50 54 00 00 \
93400 05 ff ff 00 00 08 06 00 01 00 00 c0 a8 00 02 \
935c0 a8 00 01 00 00 00 00 00 00 00 04 10 b0 76 00 \
936ff ff 00 05 00 00 00 00 00 00 00 00 00 00 00 00 \
93700 00 00 00 00 00 00 00 00 00 00 01 00 00 00 00 \
93800 00 00 3c 00 00 00 08 00 03 00 00 00 60 00 00 \
fbc7ed06 93900 00 00 01 00 03 50 54 00 00 00 05 50 54 00 00 \
fec00620
BP
94000 06 ff ff 00 00 08 00 00 01 00 00 c0 a8 00 01 \
941c0 a8 00 02 00 08 00 00 00 00 00 09 05 b8 d8 00 \
fbc7ed06 94280 00 00 05 00 00 00 00 00 00 00 00 00 00 00 00 \
fec00620
BP
94300 00 00 00 00 00 00 00 00 00 00 0d 00 00 00 00 \
94400 00 04 fa 00 00 00 08 00 01 00 00 \
05b8f1c2
BP
94500 58 02 00 00 3f ff ff 00 00 00 00 00 00 00 00 \
94600 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
94700 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
94800 00 00 00 80 00 00 00 00 00 00 00 00 00 00 00 \
94900 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
95000 00 00 00 00 00 00 00 \
fec00620
BP
951"], [0], [dnl
952OFPST_FLOW reply (xid=0x4):
666d0863 953 cookie=0x0, duration=4.2s, table=0, n_packets=1, n_bytes=60, idle_timeout=5, priority=65535,arp,in_port=3,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:06,arp_spa=192.168.0.1,arp_tpa=192.168.0.2,arp_op=2,nw_tos=0,tp_src=0,tp_dst=0 actions=output:1
b9718b7b 954 cookie=0x0, duration=8.9s, table=0, n_packets=13, n_bytes=1274, idle_timeout=5, priority=65535,icmp,in_port=1,vlan_tci=0x0000,dl_src=50:54:00:00:00:06,dl_dst=50:54:00:00:00:05,nw_src=192.168.0.2,nw_dst=192.168.0.1,nw_tos=0,icmp_type=0,icmp_code=0 actions=output:3
666d0863 955 cookie=0x0, duration=4.28s, table=0, n_packets=1, n_bytes=60, idle_timeout=5, priority=65535,arp,in_port=1,vlan_tci=0x0000,dl_src=50:54:00:00:00:06,dl_dst=50:54:00:00:00:05,arp_spa=192.168.0.2,arp_tpa=192.168.0.1,arp_op=1,nw_tos=0,tp_src=0,tp_dst=0 actions=output:3
b9718b7b 956 cookie=0x0, duration=9.096s, table=0, n_packets=13, n_bytes=1274, idle_timeout=5, icmp,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:06,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,icmp_type=8,icmp_code=0 actions=output:1
05b8f1c2 957 cookie=0x0, duration=0s, table=2, n_packets=0, n_bytes=0, actions=drop
fec00620
BP
958])
959AT_CLEANUP
960
6ec5f0c5
SH
961AT_SETUP([OFPST_FLOW reply - OF1.2])
962AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
963AT_CHECK([ovs-ofctl ofp-print "\
96403 13 01 78 00 00 00 02 00 01 00 00 00 00 00 00 \
96500 78 00 00 00 00 00 03 01 5e f3 c0 80 00 00 00 \
96600 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
96700 00 00 00 00 00 00 01 00 00 00 00 00 00 00 62 \
96800 01 00 2d 80 00 00 04 00 00 00 02 80 00 06 06 \
969ca da ad d6 0d 37 80 00 0a 02 08 00 80 00 10 01 \
97000 80 00 04 08 00 00 00 00 00 00 00 00 00 00 00 \
97100 04 00 18 00 00 00 00 00 00 00 10 00 00 00 02 \
97205 dc 00 00 00 00 00 00 00 78 00 00 00 00 00 04 \
97320 7c 0a 40 80 00 00 00 00 00 00 00 00 00 00 00 \
97400 00 00 00 00 00 00 00 00 00 00 00 00 00 00 02 \
97500 00 00 00 00 00 00 8c 00 01 00 2d 80 00 00 04 \
97600 00 00 02 80 00 06 06 52 54 00 c3 00 89 80 00 \
9770a 02 08 00 80 00 10 01 00 80 00 04 08 00 00 00 \
97800 00 00 00 00 00 00 00 00 04 00 18 00 00 00 00 \
97900 00 00 10 00 00 00 02 05 dc 00 00 00 00 00 00 \
98000 78 00 00 00 00 00 04 20 a9 d1 00 80 00 00 00 \
98100 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
98200 00 00 00 00 00 00 01 00 00 00 00 00 00 00 2a \
98300 01 00 2d 80 00 00 04 00 00 00 02 80 00 06 06 \
98452 54 00 97 00 69 80 00 0a 02 08 00 80 00 10 01 \
98500 80 00 04 08 00 00 00 00 00 00 00 00 00 00 00 \
98600 04 00 18 00 00 00 00 00 00 00 10 00 00 00 02 \
98705 dc 00 00 00 00 00 00 \
988"], [0], [dnl
989OFPST_FLOW reply (OF1.2) (xid=0x2):
990 cookie=0x0, duration=3.023s, table=0, n_packets=1, n_bytes=98, ip,metadata=0,in_port=2,dl_dst=ca:da:ad:d6:0d:37,nw_tos=0 actions=output:2
991 cookie=0x0, duration=4.545s, table=0, n_packets=2, n_bytes=140, ip,metadata=0,in_port=2,dl_dst=52:54:00:c3:00:89,nw_tos=0 actions=output:2
992 cookie=0x0, duration=4.548s, table=0, n_packets=1, n_bytes=42, ip,metadata=0,in_port=2,dl_dst=52:54:00:97:00:69,nw_tos=0 actions=output:2
993])
994AT_CLEANUP
995
617da9cd 996AT_SETUP([OFPST_AGGREGATE request - OF1.0])
fec00620
BP
997AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
998AT_CHECK([ovs-ofctl ofp-print "\
99901 10 00 38 00 00 00 04 00 02 00 00 00 38 20 ff \
1000ff fe 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
100100 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
100200 00 00 00 ff 00 ff ff \
1003"], [0], [dnl
54ae6fa8 1004OFPST_AGGREGATE request (xid=0x4): @&t@
fec00620
BP
1005])
1006AT_CLEANUP
1007
617da9cd
SH
1008AT_SETUP([OFPST_AGGREGATE request - OF1.2])
1009AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
1010AT_CHECK([ovs-ofctl ofp-print "\
101103 12 00 38 00 00 00 02 00 02 00 00 00 00 00 00 \
1012ff 00 00 00 ff ff ff ff ff ff ff ff 00 00 00 00 \
101300 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
101400 01 00 04 00 00 00 00 \
1015"], [0], [dnl
1016OFPST_AGGREGATE request (OF1.2) (xid=0x2): @&t@
1017])
1018AT_CLEANUP
1019
2e1ae200
JR
1020AT_SETUP([OFPST_AGGREGATE request - OF1.3])
1021AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
1022AT_CHECK([ovs-ofctl ofp-print "\
102304 12 00 38 00 00 00 02 00 02 00 00 00 00 00 00 \
1024ff 00 00 00 ff ff ff ff ff ff ff ff 00 00 00 00 \
102500 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
102600 01 00 04 00 00 00 00 \
1027"], [0], [dnl
1028OFPST_AGGREGATE request (OF1.3) (xid=0x2): @&t@
1029])
1030AT_CLEANUP
1031
617da9cd 1032AT_SETUP([OFPST_AGGREGATE reply - OF1.0])
fec00620
BP
1033AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
1034AT_CHECK([ovs-ofctl ofp-print "\
103501 11 00 24 00 00 00 04 00 02 00 00 00 00 00 00 \
103600 00 01 82 00 00 00 00 00 00 93 78 00 00 00 04 \
103700 00 00 00 \
1038"], [0], [dnl
1039OFPST_AGGREGATE reply (xid=0x4): packet_count=386 byte_count=37752 flow_count=4
1040])
1041AT_CLEANUP
1042
617da9cd
SH
1043AT_SETUP([OFPST_AGGREGATE reply - OF1.2])
1044AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
1045AT_CHECK([ovs-ofctl ofp-print "\
104603 13 00 28 00 00 00 02 00 02 00 00 00 00 00 00 \
104700 00 00 00 00 00 00 79 00 00 00 00 00 00 4b 4f \
104800 00 00 03 00 00 00 00 \
1049"], [0], [dnl
1050OFPST_AGGREGATE reply (OF1.2) (xid=0x2): packet_count=121 byte_count=19279 flow_count=3
1051])
1052AT_CLEANUP
1053
2e1ae200
JR
1054AT_SETUP([OFPST_AGGREGATE reply - OF1.3])
1055AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
1056AT_CHECK([ovs-ofctl ofp-print "\
105704 13 00 28 00 00 00 02 00 02 00 00 00 00 00 00 \
105800 00 00 00 00 00 00 79 00 00 00 00 00 00 4b 4f \
105900 00 00 03 00 00 00 00 \
1060"], [0], [dnl
1061OFPST_AGGREGATE reply (OF1.3) (xid=0x2): packet_count=121 byte_count=19279 flow_count=3
1062])
1063AT_CLEANUP
1064
307975da 1065AT_SETUP([OFPST_TABLE request - OF1.0])
fec00620
BP
1066AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
1067AT_CHECK([ovs-ofctl ofp-print "0110000c0000000100030000"], [0], [dnl
1068OFPST_TABLE request (xid=0x1):
1069])
1070AT_CLEANUP
1071
307975da
SH
1072AT_SETUP([OFPST_TABLE request - OF1.1])
1073AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
1074AT_CHECK([ovs-ofctl ofp-print "02120010000000020003000000000000"], [0], [dnl
1075OFPST_TABLE request (OF1.1) (xid=0x2):
1076])
1077AT_CLEANUP
1078
1079AT_SETUP([OFPST_TABLE request - OF1.2])
1080AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
1081AT_CHECK([ovs-ofctl ofp-print "03120010000000020003000000000000"], [0], [dnl
1082OFPST_TABLE request (OF1.2) (xid=0x2):
1083])
1084AT_CLEANUP
1085
2e1ae200
JR
1086AT_SETUP([OFPST_TABLE request - OF1.3])
1087AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
1088AT_CHECK([ovs-ofctl ofp-print "04120010000000020003000000000000"], [0], [dnl
1089OFPST_TABLE request (OF1.3) (xid=0x2):
1090])
1091AT_CLEANUP
1092
26df8b3e 1093AT_SETUP([OFPST_TABLE reply - OF1.0])
fec00620
BP
1094AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
1095AT_CHECK([ovs-ofctl ofp-print "\
109601 11 00 4c 00 00 00 01 00 03 00 00 00 00 00 00 \
109763 6c 61 73 73 69 66 69 65 72 00 00 00 00 00 00 \
109800 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
109900 3f ff ff 00 10 00 00 00 00 00 0b 00 00 00 00 \
110000 00 00 00 00 00 00 00 00 00 00 00 \
1101"], [0], [dnl
1102OFPST_TABLE reply (xid=0x1): 1 tables
1103 0: classifier: wild=0x3fffff, max=1048576, active=11
1104 lookup=0, matched=0
1105])
1106AT_CLEANUP
1107
26df8b3e
SH
1108AT_SETUP([OFPST_TABLE reply - OF1.2])
1109AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
1110(mid="wild=0xfffffffff, max=1000000,"
1111 tail="
1112 match=0xfffffffff, instructions=0x00000007, config=0x00000000
1113 write_actions=0x00000000, apply_actions=0x00000000
1114 write_setfields=0x0000000fffffffff
1115 apply_setfields=0x0000000fffffffff
1116 metadata_match=0x0000000000000000
1117 metadata_write=0x0000000000000000"
1118 echo "OFPST_TABLE reply (OF1.2) (xid=0x2): 255 tables
1119 0: classifier: $mid active=1
1120 lookup=74614, matched=106024$tail"
1121 x=1
1122 while test $x -lt 254; do
1123 printf " %d: %-8s: $mid active=0
1124 lookup=0, matched=0$tail
1125" $x table$x
1126 x=`expr $x + 1`
1127 done
1128 echo " 254: table254: $mid active=2
1129 lookup=0, matched=0$tail") > expout
1130
1131(pad32="\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1132 pad7="00 00 00 00 00 00 00 "
1133 mid="00 00 00 0f ff ff ff ff \
113400 00 00 0f ff ff ff ff 00 00 00 00 00 00 00 00 \
113500 00 00 0f ff ff ff ff 00 00 00 0f ff ff ff ff \
113600 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
113700 00 00 07 00 00 00 00 00 0f 42 40 "
1138 tail="00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00"
1139
1140 echo -n "03 13 7f 90 00 00 00 02 00 03 00 00 00 00 00 00 "
1141
1142 x=0
1143 printf "%02x $pad7" $x
1144 printf "%s$pad32" "classifier" | od -A n -t x1 -v -N 32 | tr '\n' ' '
1145 echo -n "$mid 00 00 00 01 "
1146 echo -n "00 00 00 00 00 01 23 76 00 00 00 00 00 01 9e 28 "
1147
1148 x=1
1149 while test $x -lt 254; do
1150 printf "%02x $pad7" $x
1151 printf "%s$pad32" "table$x" | od -A n -t x1 -v -N 32 | tr '\n' ' '
1152 echo -n "$mid 00 00 00 00 $tail "
1153 x=`expr $x + 1`
1154 done
1155
1156 x=254
1157 printf "%02x $pad7" $x
1158 printf "%s$pad32" "table$x" | od -A n -t x1 -v -N 32 | tr '\n' ' '
1159 echo -n "$mid 00 00 00 02 $tail") > in
1160AT_CHECK([ovs-ofctl ofp-print "$(cat in)"], [0], [expout])
1161AT_CLEANUP
1162
2e1ae200
JR
1163AT_SETUP([OFPST_TABLE reply - OF1.3])
1164AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
1165AT_CHECK([ovs-ofctl ofp-print "\
116604 13 00 40 00 00 00 01 00 03 00 00 00 00 00 00 \
116700 00 00 00 00 00 00 0b 00 00 00 00 00 00 02 00 \
116800 00 00 00 00 00 01 00 01 00 00 00 00 00 00 0c \
116900 00 00 00 00 00 02 01 00 00 00 00 00 00 01 01 \
1170"], [0], [dnl
1171OFPST_TABLE reply (OF1.3) (xid=0x1): 2 tables
1172 0: active=11, lookup=512, matched=256
1173 1: active=12, lookup=513, matched=257
1174])
1175AT_CLEANUP
1176
f8e4867e 1177AT_SETUP([OFPST_PORT request - 1.0])
fec00620
BP
1178AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
1179AT_CHECK([ovs-ofctl ofp-print "\
118001 10 00 14 00 00 00 01 00 04 00 00 ff ff 00 00 \
118100 00 00 00 \
1182"], [0], [dnl
1183OFPST_PORT request (xid=0x1): port_no=65535
1184])
1185AT_CLEANUP
1186
f8e4867e
SH
1187AT_SETUP([OFPST_PORT request - 1.1])
1188AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
1189AT_CHECK([ovs-ofctl ofp-print "\
119002 12 00 18 00 00 00 02 00 04 00 00 00 00 00 00 \
1191ff ff ff ff 00 00 00 00 \
1192"], [0], [dnl
1193OFPST_PORT request (OF1.1) (xid=0x2): port_no=65535
1194])
1195AT_CLEANUP
1196
1197AT_SETUP([OFPST_PORT request - 1.2])
1198AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
1199AT_CHECK([ovs-ofctl ofp-print "\
120003 12 00 18 00 00 00 02 00 04 00 00 00 00 00 00 \
1201ff ff ff ff 00 00 00 00 \
1202"], [0], [dnl
1203OFPST_PORT request (OF1.2) (xid=0x2): port_no=65535
1204])
1205AT_CLEANUP
1206
2e1ae200
JR
1207AT_SETUP([OFPST_PORT request - 1.3])
1208AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
1209AT_CHECK([ovs-ofctl ofp-print "\
121004 12 00 18 00 00 00 02 00 04 00 00 00 00 00 00 \
1211ff ff ff ff 00 00 00 00 \
1212"], [0], [dnl
1213OFPST_PORT request (OF1.3) (xid=0x2): port_no=65535
1214])
1215AT_CLEANUP
1216
f8e4867e 1217AT_SETUP([OFPST_PORT reply - OF1.0])
fec00620
BP
1218AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
1219AT_CHECK([ovs-ofctl ofp-print "\
122001 11 01 ac 00 00 00 01 00 04 00 00 00 03 00 00 \
122100 00 00 00 00 00 00 00 00 00 4d 20 00 00 00 00 \
122200 00 14 32 00 00 00 00 00 0f 60 4e 00 00 00 00 \
122300 05 71 bc 00 00 00 00 00 00 00 00 00 00 00 00 \
122400 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
122500 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
122600 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
122700 00 00 00 ff fe 00 00 00 00 00 00 00 00 00 00 \
122800 00 02 ac 00 00 00 00 00 00 01 f5 00 00 00 00 \
122900 01 0c 8c 00 00 00 00 00 00 db 1c 00 00 00 00 \
123000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
123100 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
123200 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
123300 00 00 00 00 00 00 00 00 00 00 00 00 02 00 00 \
123400 00 00 00 00 00 00 00 00 00 06 be 00 00 00 00 \
123500 00 05 84 00 00 00 00 00 02 34 b4 00 00 00 00 \
123600 02 23 d4 00 00 00 00 00 00 00 00 00 00 00 00 \
123700 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
123800 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
123900 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
124000 00 00 00 00 01 00 00 00 00 00 00 00 00 00 00 \
124100 00 14 12 00 00 00 00 00 00 14 66 00 00 00 00 \
124200 04 a2 54 00 00 00 00 00 05 8a 1e 00 00 00 00 \
124300 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
124400 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
124500 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
124600 00 00 00 00 00 00 00 00 00 00 00 \
1247"], [0], [dnl
1248OFPST_PORT reply (xid=0x1): 4 ports
1249 port 3: rx pkts=19744, bytes=1007694, drop=0, errs=0, frame=0, over=0, crc=0
1250 tx pkts=5170, bytes=356796, drop=0, errs=0, coll=0
1251 port 65534: rx pkts=684, bytes=68748, drop=0, errs=0, frame=0, over=0, crc=0
1252 tx pkts=501, bytes=56092, drop=0, errs=0, coll=0
1253 port 2: rx pkts=1726, bytes=144564, drop=0, errs=0, frame=0, over=0, crc=0
1254 tx pkts=1412, bytes=140244, drop=0, errs=0, coll=0
1255 port 1: rx pkts=5138, bytes=303700, drop=0, errs=0, frame=0, over=0, crc=0
1256 tx pkts=5222, bytes=363038, drop=0, errs=0, coll=0
1257])
1258AT_CLEANUP
1259
f8e4867e
SH
1260AT_SETUP([OFPST_PORT reply - OF1.2])
1261AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
1262AT_CHECK([ovs-ofctl ofp-print "\
126303 13 01 48 00 00 00 02 00 04 00 00 00 00 00 00 \
126400 00 00 02 00 00 00 00 00 00 00 00 00 01 95 56 \
126500 00 00 00 00 00 00 88 00 00 00 00 02 5d 08 98 \
126600 00 00 00 00 00 2c f8 00 00 00 00 00 00 00 00 \
126700 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
126800 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
126900 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
127000 00 00 00 00 00 00 00 ff ff ff fe 00 00 00 00 \
127100 00 00 00 00 00 00 44 00 00 00 00 00 00 9d 2c \
127200 00 00 00 00 00 16 7c 00 00 00 00 01 1e 36 44 \
127300 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
127400 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
127500 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
127600 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
127700 00 00 01 00 00 00 00 00 00 00 00 00 00 00 44 \
127800 00 00 00 00 00 9d 2c 00 00 00 00 00 00 16 7c \
127900 00 00 00 01 1e 36 44 00 00 00 00 00 00 00 00 \
128000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
128100 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
128200 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
128300 00 00 00 00 00 00 00 \
1284"], [0], [dnl
1285OFPST_PORT reply (OF1.2) (xid=0x2): 3 ports
1286 port 2: rx pkts=103766, bytes=39651480, drop=0, errs=0, frame=0, over=0, crc=0
1287 tx pkts=136, bytes=11512, drop=0, errs=0, coll=0
1288 port 65534: rx pkts=68, bytes=5756, drop=0, errs=0, frame=0, over=0, crc=0
1289 tx pkts=40236, bytes=18757188, drop=0, errs=0, coll=0
1290 port 1: rx pkts=68, bytes=5756, drop=0, errs=0, frame=0, over=0, crc=0
1291 tx pkts=40236, bytes=18757188, drop=0, errs=0, coll=0
1292])
1293AT_CLEANUP
1294
64626975 1295AT_SETUP([OFPST_QUEUE request - OF1.0])
fec00620
BP
1296AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
1297AT_CHECK([ovs-ofctl ofp-print "\
129801 10 00 14 00 00 00 01 00 05 00 00 ff fc 00 00 \
1299ff ff ff ff \
1300"], [0], [dnl
7f05e7ab 1301OFPST_QUEUE request (xid=0x1):port=ANY queue=ALL
fec00620
BP
1302])
1303AT_CLEANUP
1304
64626975
SH
1305AT_SETUP([OFPST_QUEUE request - OF1.1])
1306AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
1307AT_CHECK([ovs-ofctl ofp-print "\
130802 12 00 18 00 00 00 02 00 05 00 00 00 00 00 00 \
7f05e7ab 1309ff ff ff ff ff ff ff ff \
64626975 1310"], [0], [dnl
7f05e7ab 1311OFPST_QUEUE request (OF1.1) (xid=0x2):port=ANY queue=ALL
64626975
SH
1312])
1313AT_CLEANUP
1314
1315AT_SETUP([OFPST_QUEUE request - OF1.2])
1316AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
1317AT_CHECK([ovs-ofctl ofp-print "\
131803 12 00 18 00 00 00 02 00 05 00 00 00 00 00 00 \
7f05e7ab 1319ff ff ff ff ff ff ff ff \
64626975 1320"], [0], [dnl
7f05e7ab 1321OFPST_QUEUE request (OF1.2) (xid=0x2):port=ANY queue=ALL
64626975
SH
1322])
1323AT_CLEANUP
1324
2e1ae200
JR
1325AT_SETUP([OFPST_QUEUE request - OF1.3])
1326AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
1327AT_CHECK([ovs-ofctl ofp-print "\
132804 12 00 18 00 00 00 02 00 05 00 00 00 00 00 00 \
1329ff ff ff ff ff ff ff ff \
1330"], [0], [dnl
1331OFPST_QUEUE request (OF1.3) (xid=0x2):port=ANY queue=ALL
1332])
1333AT_CLEANUP
1334
64626975 1335AT_SETUP([OFPST_QUEUE reply - OF1.0])
fec00620
BP
1336AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
1337AT_CHECK([ovs-ofctl ofp-print "\
133801 11 00 cc 00 00 00 01 00 05 00 00 00 03 00 00 \
133900 00 00 01 00 00 00 00 00 00 01 2e 00 00 00 00 \
134000 00 00 01 00 00 00 00 00 00 00 00 00 03 00 00 \
134100 00 00 02 00 00 00 00 00 00 00 00 00 00 00 00 \
134200 00 00 00 00 00 00 00 00 00 00 00 00 02 00 00 \
134300 00 00 01 00 00 00 00 00 00 08 34 00 00 00 00 \
134400 00 00 14 00 00 00 00 00 00 00 00 00 02 00 00 \
134500 00 00 02 00 00 00 00 00 00 00 00 00 00 00 00 \
134600 00 00 00 00 00 00 00 00 00 00 00 00 01 00 00 \
134700 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 \
134800 00 00 00 00 00 00 00 00 00 00 00 00 01 00 00 \
134900 00 00 02 00 00 00 00 00 00 00 00 00 00 00 00 \
135000 00 00 00 00 00 00 00 00 00 00 00 \
1351"], [0], [dnl
1352OFPST_QUEUE reply (xid=0x1): 6 queues
1353 port 3 queue 1: bytes=302, pkts=1, errors=0
1354 port 3 queue 2: bytes=0, pkts=0, errors=0
1355 port 2 queue 1: bytes=2100, pkts=20, errors=0
1356 port 2 queue 2: bytes=0, pkts=0, errors=0
1357 port 1 queue 1: bytes=0, pkts=0, errors=0
1358 port 1 queue 2: bytes=0, pkts=0, errors=0
1359])
1360AT_CLEANUP
1361
2be393ed
JP
1362AT_SETUP([OFPST_PORT_DESC request - OF1.0])
1363AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
1364AT_CHECK([ovs-ofctl ofp-print "0110000c00000001000d0000"], [0], [dnl
1365OFPST_PORT_DESC request (xid=0x1):
1366])
1367AT_CLEANUP
1368
64626975
SH
1369AT_SETUP([OFPST_QUEUE reply - OF1.1])
1370AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
1371AT_CHECK([ovs-ofctl ofp-print "\
137202 13 00 d0 00 00 00 01 00 05 00 00 00 00 00 00 \
137300 00 00 03 00 00 00 01 00 00 00 00 00 00 01 2e \
137400 00 00 00 00 00 00 01 00 00 00 00 00 00 00 00 \
137500 00 00 03 00 00 00 02 00 00 00 00 00 00 00 00 \
137600 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
137700 00 00 02 00 00 00 01 00 00 00 00 00 00 08 34 \
137800 00 00 00 00 00 00 14 00 00 00 00 00 00 00 00 \
137900 00 00 02 00 00 00 02 00 00 00 00 00 00 00 00 \
138000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
138100 00 00 01 00 00 00 01 00 00 00 00 00 00 00 00 \
138200 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
138300 00 00 01 00 00 00 02 00 00 00 00 00 00 00 00 \
138400 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
1385"], [0], [dnl
1386OFPST_QUEUE reply (OF1.1) (xid=0x1): 6 queues
1387 port 3 queue 1: bytes=302, pkts=1, errors=0
1388 port 3 queue 2: bytes=0, pkts=0, errors=0
1389 port 2 queue 1: bytes=2100, pkts=20, errors=0
1390 port 2 queue 2: bytes=0, pkts=0, errors=0
1391 port 1 queue 1: bytes=0, pkts=0, errors=0
1392 port 1 queue 2: bytes=0, pkts=0, errors=0
1393])
1394AT_CLEANUP
1395
1396AT_SETUP([OFPST_QUEUE reply - OF1.2])
1397AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
1398AT_CHECK([ovs-ofctl ofp-print "\
139903 13 00 d0 00 00 00 01 00 05 00 00 00 00 00 00 \
140000 00 00 03 00 00 00 01 00 00 00 00 00 00 01 2e \
140100 00 00 00 00 00 00 01 00 00 00 00 00 00 00 00 \
140200 00 00 03 00 00 00 02 00 00 00 00 00 00 00 00 \
140300 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
140400 00 00 02 00 00 00 01 00 00 00 00 00 00 08 34 \
140500 00 00 00 00 00 00 14 00 00 00 00 00 00 00 00 \
140600 00 00 02 00 00 00 02 00 00 00 00 00 00 00 00 \
140700 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
140800 00 00 01 00 00 00 01 00 00 00 00 00 00 00 00 \
140900 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
141000 00 00 01 00 00 00 02 00 00 00 00 00 00 00 00 \
141100 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
1412"], [0], [dnl
1413OFPST_QUEUE reply (OF1.2) (xid=0x1): 6 queues
1414 port 3 queue 1: bytes=302, pkts=1, errors=0
1415 port 3 queue 2: bytes=0, pkts=0, errors=0
1416 port 2 queue 1: bytes=2100, pkts=20, errors=0
1417 port 2 queue 2: bytes=0, pkts=0, errors=0
1418 port 1 queue 1: bytes=0, pkts=0, errors=0
1419 port 1 queue 2: bytes=0, pkts=0, errors=0
1420])
1421AT_CLEANUP
1422
2be393ed
JP
1423AT_SETUP([OFPST_PORT_DESC reply - OF1.0])
1424AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
1425AT_CHECK([ovs-ofctl ofp-print "\
142601 11 00 3c 00 00 00 00 00 0d 00 00 00 03 50 54 \
142700 00 00 01 65 74 68 30 00 00 00 00 00 00 00 00 \
142800 00 00 00 00 00 00 01 00 00 00 01 00 00 02 08 \
142900 00 02 8f 00 00 02 8f 00 00 00 00 \
1430"], [0], [dnl
1431OFPST_PORT_DESC reply (xid=0x0):
1432 3(eth0): addr:50:54:00:00:00:01
1433 config: PORT_DOWN
1434 state: LINK_DOWN
1435 current: 100MB-FD AUTO_NEG
1436 advertised: 10MB-HD 10MB-FD 100MB-HD 100MB-FD COPPER AUTO_NEG
1437 supported: 10MB-HD 10MB-FD 100MB-HD 100MB-FD COPPER AUTO_NEG
1438 speed: 100 Mbps now, 100 Mbps max
1439])
1440AT_CLEANUP
1441
58cf43df 1442AT_SETUP([OFPT_BARRIER_REQUEST - OF1.0])
fec00620
BP
1443AT_KEYWORDS([ofp-print])
1444AT_CHECK([ovs-ofctl ofp-print '01 12 00 08 00 00 00 01'], [0], [dnl
1445OFPT_BARRIER_REQUEST (xid=0x1):
1446])
1447AT_CLEANUP
1448
58cf43df
SH
1449AT_SETUP([OFPT_BARRIER_REQUEST - OF1.1])
1450AT_KEYWORDS([ofp-print])
1451AT_CHECK([ovs-ofctl ofp-print '02 14 00 08 00 00 00 01'], [0], [dnl
1452OFPT_BARRIER_REQUEST (OF1.1) (xid=0x1):
1453])
1454AT_CLEANUP
1455
1456AT_SETUP([OFPT_BARRIER_REQUEST - OF1.2])
1457AT_KEYWORDS([ofp-print])
1458AT_CHECK([ovs-ofctl ofp-print '03 14 00 08 00 00 00 01'], [0], [dnl
1459OFPT_BARRIER_REQUEST (OF1.2) (xid=0x1):
1460])
1461AT_CLEANUP
1462
2e1ae200
JR
1463AT_SETUP([OFPT_BARRIER_REQUEST - OF1.3])
1464AT_KEYWORDS([ofp-print])
1465AT_CHECK([ovs-ofctl ofp-print '04 14 00 08 00 00 00 01'], [0], [dnl
1466OFPT_BARRIER_REQUEST (OF1.3) (xid=0x1):
1467])
1468AT_CLEANUP
1469
58cf43df 1470AT_SETUP([OFPT_BARRIER_REPLY - OF1.0])
fec00620
BP
1471AT_KEYWORDS([ofp-print])
1472AT_CHECK([ovs-ofctl ofp-print '01 13 00 08 00 00 00 01'], [0], [dnl
1473OFPT_BARRIER_REPLY (xid=0x1):
1474])
1475AT_CLEANUP
1476
2e1ae200 1477AT_SETUP([OFPT_BARRIER_REPLY - OF1.1])
58cf43df
SH
1478AT_KEYWORDS([ofp-print])
1479AT_CHECK([ovs-ofctl ofp-print '02 15 00 08 00 00 00 01'], [0], [dnl
1480OFPT_BARRIER_REPLY (OF1.1) (xid=0x1):
1481])
1482AT_CLEANUP
1483
2e1ae200 1484AT_SETUP([OFPT_BARRIER_REPLY - OF1.2])
58cf43df
SH
1485AT_KEYWORDS([ofp-print])
1486AT_CHECK([ovs-ofctl ofp-print '03 15 00 08 00 00 00 01'], [0], [dnl
1487OFPT_BARRIER_REPLY (OF1.2) (xid=0x1):
1488])
1489AT_CLEANUP
1490
2e1ae200
JR
1491AT_SETUP([OFPT_BARRIER_REPLY - OF1.3])
1492AT_KEYWORDS([ofp-print])
1493AT_CHECK([ovs-ofctl ofp-print '04 15 00 08 00 00 00 01'], [0], [dnl
1494OFPT_BARRIER_REPLY (OF1.3) (xid=0x1):
1495])
1496AT_CLEANUP
1497
1498
1499AT_SETUP([OFPT_SET_ASYNC - OF1.3])
1500AT_KEYWORDS([ofp-print])
1501AT_CHECK([ovs-ofctl ofp-print "\
150204 1c 00 20 00 00 00 00 00 00 10 05 00 00 10 07 \
150300 00 00 03 00 00 00 07 00 00 00 00 00 00 00 03 \
1504"], [0], [dnl
1505OFPT_SET_ASYNC (OF1.3) (xid=0x0):
1506 master:
1507 PACKET_IN: no_match invalid_ttl 12
1508 PORT_STATUS: add delete
1509 FLOW_REMOVED: (off)
1510
1511 slave:
1512 PACKET_IN: no_match action invalid_ttl 12
1513 PORT_STATUS: add delete modify
1514 FLOW_REMOVED: idle hard
1515])
1516AT_CLEANUP
1517
fec00620
BP
1518AT_SETUP([NXT_ROLE_REQUEST])
1519AT_KEYWORDS([ofp-print])
1520AT_CHECK([ovs-ofctl ofp-print "\
152101 04 00 14 00 00 00 02 00 00 23 20 00 00 00 0a \
152200 00 00 01 \
1523"], [0], [dnl
1524NXT_ROLE_REQUEST (xid=0x2): role=master
1525])
1526AT_CLEANUP
1527
1528AT_SETUP([NXT_ROLE_REPLY])
1529AT_KEYWORDS([ofp-print])
1530AT_CHECK([ovs-ofctl ofp-print "\
153101 04 00 14 00 00 00 02 00 00 23 20 00 00 00 0b \
153200 00 00 02 \
1533"], [0], [dnl
1534NXT_ROLE_REPLY (xid=0x2): role=slave
1535])
1536AT_CLEANUP
1537
54834960
EJ
1538AT_SETUP([NXT_SET_PACKET_IN])
1539AT_KEYWORDS([ofp-print])
1540AT_CHECK([ovs-ofctl ofp-print "\
154101 04 00 14 00 00 00 02 00 00 23 20 00 00 00 10 \
154200 00 00 01 \
1543"], [0], [dnl
1544NXT_SET_PACKET_IN_FORMAT (xid=0x2): format=nxm
1545])
1546AT_CLEANUP
1547
1548AT_SETUP([NXT_PACKET_IN])
1549AT_KEYWORDS([ofp-print])
1550AT_CHECK([ovs-ofctl ofp-print "\
969fc56c 155101 04 00 ba 00 00 00 00 00 00 23 20 00 00 00 11 \
54834960 1552ff ff ff ff 00 40 01 07 00 00 00 00 00 00 00 09 \
969fc56c 155300 4e 00 00 00 00 00 00 00 00 00 02 00 01 00 01 \
54834960
EJ
155420 08 00 00 00 00 00 00 00 06 00 01 00 04 00 00 \
155500 01 00 01 02 04 00 00 00 02 00 01 04 04 00 00 \
155600 03 00 01 06 04 00 00 00 04 00 01 08 04 00 00 \
969fc56c 155700 05 80 00 05 10 5a 5a 5a 5a 5a 5a 5a 5a ff ff \
42edbe39 1558ff ff ff ff ff ff 00 00 00 00 82 82 82 82 82 82 \
54834960
EJ
155980 81 81 81 81 81 81 00 00 50 08 00 45 00 00 28 \
156000 00 00 00 00 06 32 05 53 53 53 53 54 54 54 54 \
156100 55 00 56 00 00 00 00 00 00 00 00 50 00 00 00 \
156231 6d 00 00 00 00 00 00 00 00 \
1563"], [0], [dnl
42edbe39 1564NXT_PACKET_IN (xid=0x0): table_id=7 cookie=0x9 total_len=64 in_port=1 tun_id=0x6 metadata=0x5a5a5a5a5a5a5a5a reg0=0x1 reg1=0x2 reg2=0x3 reg3=0x4 reg4=0x5 (via action) data_len=64 (unbuffered)
3f78c3cc 1565tcp,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 tcp_csum:316d
54834960
EJ
1566])
1567AT_CLEANUP
1568
80d5aefd
BP
1569AT_SETUP([NXT_SET_ASYNC_CONFIG])
1570AT_KEYWORDS([ofp-print])
1571AT_CHECK([ovs-ofctl ofp-print "\
157201 04 00 28 00 00 00 00 00 00 23 20 00 00 00 13 \
157300 00 10 05 00 00 10 07 00 00 00 03 00 00 00 07 \
157400 00 00 00 00 00 00 03 \
1575"], [0], [dnl
1576NXT_SET_ASYNC_CONFIG (xid=0x0):
1577 master:
1578 PACKET_IN: no_match invalid_ttl 12
1579 PORT_STATUS: add delete
1580 FLOW_REMOVED: (off)
1581
1582 slave:
1583 PACKET_IN: no_match action invalid_ttl 12
1584 PORT_STATUS: add delete modify
1585 FLOW_REMOVED: idle hard
1586])
1587AT_CLEANUP
1588
a7349929
BP
1589AT_SETUP([NXT_SET_CONTROLLER_ID])
1590AT_KEYWORDS([ofp-print])
1591AT_CHECK([ovs-ofctl ofp-print "\
159201 04 00 18 00 00 00 03 00 00 23 20 00 00 00 14 \
159300 00 00 00 00 00 00 7b \
1594"], [0], [dnl
1595NXT_SET_CONTROLLER_ID (xid=0x3): id=123
1596])
1597AT_CLEANUP
1598
2b07c8b1
BP
1599AT_SETUP([NXT_FLOW_MONITOR_CANCEL])
1600AT_KEYWORDS([ofp-print])
1601AT_CHECK([ovs-ofctl ofp-print "\
160201 04 00 14 00 00 00 03 00 00 23 20 00 00 00 15 \
160301 02 30 40 \
1604"], [0], [dnl
1605NXT_FLOW_MONITOR_CANCEL (xid=0x3): id=16920640
1606])
1607AT_CLEANUP
1608
1609AT_SETUP([NXT_FLOW_MONITOR_PAUSED])
1610AT_KEYWORDS([ofp-print])
1611AT_CHECK([ovs-ofctl ofp-print "\
161201 04 00 10 00 00 00 03 00 00 23 20 00 00 00 16 \
1613"], [0], [dnl
1614NXT_FLOW_MONITOR_PAUSED (xid=0x3):
1615])
1616AT_CLEANUP
1617
1618AT_SETUP([NXT_FLOW_MONITOR_RESUMED])
1619AT_KEYWORDS([ofp-print])
1620AT_CHECK([ovs-ofctl ofp-print "\
162101 04 00 10 00 00 00 03 00 00 23 20 00 00 00 17 \
1622"], [0], [dnl
1623NXT_FLOW_MONITOR_RESUMED (xid=0x3):
1624])
1625AT_CLEANUP
1626
fec00620
BP
1627AT_SETUP([NXT_SET_FLOW_FORMAT])
1628AT_KEYWORDS([ofp-print])
1629AT_CHECK([ovs-ofctl ofp-print "\
163001 04 00 14 00 00 00 02 00 00 23 20 00 00 00 0c \
163100 00 00 02 \
1632"], [0], [dnl
1633NXT_SET_FLOW_FORMAT (xid=0x2): format=nxm
1634])
1635AT_CLEANUP
1636
1637# The flow is formatted with cls_rule_format() for the low-verbosity case.
1638AT_SETUP([NXT_FLOW_MOD, low verbosity])
1639AT_KEYWORDS([ofp-print])
1640AT_CHECK([ovs-ofctl ofp-print "\
164101 04 00 60 00 00 00 02 00 00 23 20 00 00 00 0d \
164200 00 00 00 00 00 00 00 00 00 00 00 00 00 80 00 \
de0f16bc 1643ff ff ff ff 00 10 00 00 00 14 00 00 00 00 00 00 \
fec00620
BP
164400 01 20 08 00 00 00 00 00 00 01 c8 00 01 00 04 \
164500 00 00 7b 00 00 00 00 ff ff 00 18 00 00 23 20 \
164600 07 00 1f 00 01 00 04 00 00 00 00 00 00 00 05 \
1647" 2], [0], [dnl
de0f16bc 1648NXT_FLOW_MOD (xid=0x2): ADD reg0=0x7b,tun_id=0x1c8 out_port:16 actions=load:0x5->NXM_NX_REG0[[]]
fec00620
BP
1649])
1650AT_CLEANUP
1651
eec25dc1
BP
1652# The flow is formatted with ofp10_match_to_string() for the
1653# low-verbosity case.
fec00620
BP
1654AT_SETUP([NXT_FLOW_MOD, high verbosity])
1655AT_KEYWORDS([ofp-print])
1656AT_CHECK([ovs-ofctl ofp-print "\
165701 04 00 60 00 00 00 02 00 00 23 20 00 00 00 0d \
165800 00 00 00 00 00 00 00 00 00 00 00 00 00 80 00 \
de0f16bc 1659ff ff ff ff 01 00 00 00 00 14 00 00 00 00 00 00 \
fec00620
BP
166000 01 20 08 00 00 00 00 00 00 01 c8 00 01 00 04 \
166100 00 00 7b 00 00 00 00 ff ff 00 18 00 00 23 20 \
166200 07 00 1f 00 01 00 04 00 00 00 00 00 00 00 05 \
1663" 3], [0], [dnl
de0f16bc 1664NXT_FLOW_MOD (xid=0x2): ADD NXM_NX_TUN_ID(00000000000001c8), NXM_NX_REG0(0000007b) out_port:256 actions=load:0x5->NXM_NX_REG0[[]]
fec00620
BP
1665])
1666AT_CLEANUP
1667
1668AT_SETUP([NXT_FLOW_REMOVED])
1669AT_KEYWORDS([ofp-print])
1670AT_CHECK([ovs-ofctl ofp-print "\
167101 04 00 78 00 00 00 00 00 00 23 20 00 00 00 0e \
167200 00 00 00 00 00 00 00 ff ff 00 00 00 00 00 06 \
167301 6e 36 00 00 05 00 3c 00 00 00 00 00 00 00 01 \
167400 00 00 00 00 00 00 3c 00 00 00 02 00 03 00 00 \
167502 06 50 54 00 00 00 06 00 00 04 06 50 54 00 00 \
167600 05 00 00 06 02 08 06 00 00 08 02 00 00 00 00 \
16771e 02 00 02 00 00 20 04 c0 a8 00 01 00 00 22 04 \
1678c0 a8 00 02 00 00 00 00 \
1679"], [0], [dnl
666d0863 1680NXT_FLOW_REMOVED (xid=0x0): priority=65535,arp,in_port=3,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:06,arp_spa=192.168.0.1,arp_tpa=192.168.0.2,arp_op=2 reason=idle duration6.024s idle5 pkts1 bytes60
fec00620
BP
1681])
1682AT_CLEANUP
1683
a1a7d333
BP
1684AT_SETUP([NXT_FLOW_MOD_TABLE_ID])
1685AT_KEYWORDS([ofp-print])
1686AT_CHECK([ovs-ofctl ofp-print "\
168701 04 00 18 01 02 03 04 00 00 23 20 00 00 00 0f \
168801 00 00 00 00 00 00 00 \
1689"], [0], [dnl
1690NXT_FLOW_MOD_TABLE_ID (xid=0x1020304): enable
1691])
1692AT_CLEANUP
1693
fec00620
BP
1694AT_SETUP([NXST_FLOW request])
1695AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
1696AT_CHECK([ovs-ofctl ofp-print "\
169701 10 00 20 00 00 00 04 ff ff 00 00 00 00 23 20 \
169800 00 00 00 00 00 00 00 ff ff 00 00 ff 00 00 00 \
1699"], [0], [dnl
54ae6fa8 1700NXST_FLOW request (xid=0x4): @&t@
fec00620
BP
1701])
1702AT_CLEANUP
1703
1704AT_SETUP([NXST_FLOW reply])
1705AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
1706AT_CHECK([ovs-ofctl ofp-print "\
05b8f1c2 170701 11 08 18 00 00 00 04 ff ff 00 00 00 00 23 20 \
fec00620
BP
170800 00 00 00 00 00 00 00 00 88 00 00 00 00 00 01 \
170902 dc 6c 00 ff ff 00 05 00 00 00 4c 00 00 00 00 \
171000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 \
171100 00 00 00 00 00 00 3c 00 00 00 02 00 03 00 00 \
171202 06 50 54 00 00 00 06 00 00 04 06 50 54 00 00 \
171300 05 00 00 06 02 08 00 00 00 08 02 00 00 00 00 \
17140a 01 00 00 00 0e 04 c0 a8 00 01 00 00 10 04 c0 \
1715a8 00 02 00 00 0c 01 06 00 00 12 02 09 e7 00 00 \
171614 02 00 00 00 00 00 00 00 00 00 08 00 01 00 00 \
171700 88 00 00 00 00 00 03 32 11 62 00 ff ff 00 05 \
f27f2134 171800 00 00 4c 00 03 00 00 00 00 00 00 00 00 00 00 \
fec00620
BP
171900 00 00 00 00 00 00 01 00 00 00 00 00 00 00 3c \
172000 00 00 02 00 03 00 00 02 06 50 54 00 00 00 06 \
172100 00 04 06 50 54 00 00 00 05 00 00 06 02 08 00 \
172200 00 08 02 00 00 00 00 0a 01 00 00 00 0e 04 c0 \
1723a8 00 01 00 00 10 04 c0 a8 00 02 00 00 0c 01 06 \
172400 00 12 02 09 e4 00 00 14 02 00 00 00 00 00 00 \
172500 00 00 08 00 01 00 00 00 88 00 00 00 00 00 02 \
f27f2134 172633 f9 aa 00 ff ff 00 05 00 00 00 4c 00 05 00 00 \
fec00620
BP
172700 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 \
172800 00 00 00 00 00 00 3c 00 00 00 02 00 01 00 00 \
172902 06 50 54 00 00 00 05 00 00 04 06 50 54 00 00 \
173000 06 00 00 06 02 08 00 00 00 08 02 00 00 00 00 \
17310a 01 00 00 00 0e 04 c0 a8 00 02 00 00 10 04 c0 \
1732a8 00 01 00 00 0c 01 06 00 00 12 02 00 00 00 00 \
173314 02 09 e5 00 00 00 00 00 00 00 08 00 03 00 00 \
173400 88 00 00 00 00 00 04 2d 0f a5 00 ff ff 00 05 \
f27f2134 173500 00 00 4c 00 01 00 00 00 00 00 00 00 00 00 00 \
fec00620
BP
173600 00 00 00 00 00 00 01 00 00 00 00 00 00 00 3c \
173700 00 00 02 00 03 00 00 02 06 50 54 00 00 00 06 \
173800 00 04 06 50 54 00 00 00 05 00 00 06 02 08 00 \
173900 00 08 02 00 00 00 00 0a 01 00 00 00 0e 04 c0 \
1740a8 00 01 00 00 10 04 c0 a8 00 02 00 00 0c 01 06 \
174100 00 12 02 09 e3 00 00 14 02 00 00 00 00 00 00 \
174200 00 00 08 00 01 00 00 00 88 00 00 00 00 00 02 \
f27f2134 174334 73 bc 00 ff ff 00 05 00 0a 00 4c 00 03 00 03 \
fec00620
BP
174400 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 \
174500 00 00 00 00 00 00 3c 00 00 00 02 00 03 00 00 \
174602 06 50 54 00 00 00 06 00 00 04 06 50 54 00 00 \
174700 05 00 00 06 02 08 00 00 00 08 02 00 00 00 00 \
17480a 01 00 00 00 0e 04 c0 a8 00 01 00 00 10 04 c0 \
1749a8 00 02 00 00 0c 01 06 00 00 12 02 09 e5 00 00 \
175014 02 00 00 00 00 00 00 00 00 00 08 00 01 00 00 \
175100 88 00 00 00 00 00 05 28 0d e8 00 ff ff 00 05 \
175200 00 00 4c 00 00 00 00 00 00 00 00 00 00 00 00 \
175300 00 00 00 00 00 00 01 00 00 00 00 00 00 00 3c \
175400 00 00 02 00 03 00 00 02 06 50 54 00 00 00 06 \
175500 00 04 06 50 54 00 00 00 05 00 00 06 02 08 00 \
175600 00 08 02 00 00 00 00 0a 01 00 00 00 0e 04 c0 \
1757a8 00 01 00 00 10 04 c0 a8 00 02 00 00 0c 01 06 \
175800 00 12 02 09 e2 00 00 14 02 00 00 00 00 00 00 \
175900 00 00 08 00 01 00 00 00 88 00 00 00 00 00 01 \
176002 62 5a 00 ff ff 00 05 00 00 00 4c 00 00 00 00 \
176100 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 \
176200 00 00 00 00 00 00 3c 00 00 00 02 00 01 00 00 \
176302 06 50 54 00 00 00 05 00 00 04 06 50 54 00 00 \
176400 06 00 00 06 02 08 00 00 00 08 02 00 00 00 00 \
17650a 01 00 00 00 0e 04 c0 a8 00 02 00 00 10 04 c0 \
1766a8 00 01 00 00 0c 01 06 00 00 12 02 00 00 00 00 \
176714 02 09 e7 00 00 00 00 00 00 00 08 00 03 00 00 \
176800 88 00 00 00 00 00 01 38 be 5e 00 ff ff 00 05 \
176900 00 00 4c 00 00 00 00 00 00 00 00 00 00 00 00 \
177000 00 00 00 00 00 00 01 00 00 00 00 00 00 00 3c \
177100 00 00 02 00 01 00 00 02 06 50 54 00 00 00 05 \
177200 00 04 06 50 54 00 00 00 06 00 00 06 02 08 00 \
177300 00 08 02 00 00 00 00 0a 01 00 00 00 0e 04 c0 \
1774a8 00 02 00 00 10 04 c0 a8 00 01 00 00 0c 01 06 \
177500 00 12 02 00 00 00 00 14 02 09 e6 00 00 00 00 \
177600 00 00 08 00 03 00 00 00 88 00 00 00 00 00 04 \
177727 d0 df 00 ff ff 00 05 00 00 00 4c 00 00 00 00 \
177800 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 \
177900 00 00 00 00 00 00 3c 00 00 00 02 00 01 00 00 \
178002 06 50 54 00 00 00 05 00 00 04 06 50 54 00 00 \
178100 06 00 00 06 02 08 00 00 00 08 02 00 00 00 00 \
17820a 01 00 00 00 0e 04 c0 a8 00 02 00 00 10 04 c0 \
1783a8 00 01 00 00 0c 01 06 00 00 12 02 00 00 00 00 \
178414 02 09 e3 00 00 00 00 00 00 00 08 00 03 00 00 \
178500 88 00 00 00 00 00 03 2c d2 9c 00 ff ff 00 05 \
178600 00 00 4c 00 00 00 00 00 00 00 00 00 00 00 00 \
178700 00 00 00 00 00 00 01 00 00 00 00 00 00 00 3c \
178800 00 00 02 00 01 00 00 02 06 50 54 00 00 00 05 \
178900 00 04 06 50 54 00 00 00 06 00 00 06 02 08 00 \
179000 00 08 02 00 00 00 00 0a 01 00 00 00 0e 04 c0 \
1791a8 00 02 00 00 10 04 c0 a8 00 01 00 00 0c 01 06 \
179200 00 12 02 00 00 00 00 14 02 09 e4 00 00 00 00 \
179300 00 00 08 00 03 00 00 00 88 00 00 00 00 00 00 \
17940a 40 83 00 ff ff 00 05 00 00 00 4c 00 00 00 00 \
179500 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 \
179600 00 00 00 00 00 00 3c 00 00 00 02 00 03 00 00 \
179702 06 50 54 00 00 00 06 00 00 04 06 50 54 00 00 \
179800 05 00 00 06 02 08 00 00 00 08 02 00 00 00 00 \
17990a 01 00 00 00 0e 04 c0 a8 00 01 00 00 10 04 c0 \
1800a8 00 02 00 00 0c 01 06 00 00 12 02 09 e8 00 00 \
180114 02 00 00 00 00 00 00 00 00 00 08 00 01 00 00 \
180200 88 00 00 00 00 00 05 25 31 7c 00 ff ff 00 05 \
180300 00 00 4c 00 00 00 00 00 00 00 00 00 00 00 00 \
180400 00 00 00 00 00 00 01 00 00 00 00 00 00 00 3c \
180500 00 00 02 00 01 00 00 02 06 50 54 00 00 00 05 \
180600 00 04 06 50 54 00 00 00 06 00 00 06 02 08 00 \
180700 00 08 02 00 00 00 00 0a 01 00 00 00 0e 04 c0 \
1808a8 00 02 00 00 10 04 c0 a8 00 01 00 00 0c 01 06 \
180900 00 12 02 00 00 00 00 14 02 09 e2 00 00 00 00 \
181000 00 00 08 00 03 00 00 00 88 00 00 00 00 00 00 \
181104 c4 b4 00 ff ff 00 05 00 00 00 4c 00 00 00 00 \
181200 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 \
181300 00 00 00 00 00 00 3c 00 00 00 02 00 01 00 00 \
181402 06 50 54 00 00 00 05 00 00 04 06 50 54 00 00 \
181500 06 00 00 06 02 08 00 00 00 08 02 00 00 00 00 \
18160a 01 00 00 00 0e 04 c0 a8 00 02 00 00 10 04 c0 \
1817a8 00 01 00 00 0c 01 06 00 00 12 02 00 00 00 00 \
181814 02 09 e8 00 00 00 00 00 00 00 08 00 03 00 00 \
181900 88 00 00 00 00 00 01 39 38 70 00 ff ff 00 05 \
182000 00 00 4c 00 00 00 00 00 00 00 00 00 00 00 00 \
182100 00 00 00 00 00 00 01 00 00 00 00 00 00 00 3c \
182200 00 00 02 00 03 00 00 02 06 50 54 00 00 00 06 \
182300 00 04 06 50 54 00 00 00 05 00 00 06 02 08 00 \
182400 00 08 02 00 00 00 00 0a 01 00 00 00 0e 04 c0 \
1825a8 00 01 00 00 10 04 c0 a8 00 02 00 00 0c 01 06 \
182600 00 12 02 09 e6 00 00 14 02 00 00 00 00 00 00 \
182700 00 00 08 00 01 00 00 00 60 00 00 00 00 00 e4 \
18282e 7d db 00 80 00 00 00 00 00 00 14 00 00 00 00 \
182900 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
183000 00 00 00 00 00 00 00 00 01 20 08 00 00 00 00 \
183100 00 01 c8 00 01 00 04 00 00 00 7b 00 00 00 00 \
1832ff ff 00 18 00 00 23 20 00 07 00 1f 00 01 00 04 \
183300 00 00 00 00 00 00 05 \
05b8f1c2
BP
183400 30 01 00 00 00 0e 10 00 07 a1 20 80 00 00 00 \
183500 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 \
183600 00 00 00 00 00 00 64 00 00 00 00 00 00 19 00 \
fec00620
BP
1837"], [0],
1838[[NXST_FLOW reply (xid=0x4):
b9718b7b
BP
1839 cookie=0x0, duration=1.048s, table=0, n_packets=1, n_bytes=60, idle_timeout=5, priority=65535,tcp,in_port=3,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:06,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,tp_src=2535,tp_dst=0 actions=output:1
1840 cookie=0x0, duration=3.84s, table=0, n_packets=1, n_bytes=60, idle_timeout=5, idle_age=2, priority=65535,tcp,in_port=3,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:06,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,tp_src=2532,tp_dst=0 actions=output:1
1841 cookie=0x0, duration=2.872s, table=0, n_packets=1, n_bytes=60, idle_timeout=5, idle_age=4, priority=65535,tcp,in_port=1,vlan_tci=0x0000,dl_src=50:54:00:00:00:06,dl_dst=50:54:00:00:00:05,nw_src=192.168.0.2,nw_dst=192.168.0.1,nw_tos=0,tp_src=0,tp_dst=2533 actions=output:3
1842 cookie=0x0, duration=4.756s, table=0, n_packets=1, n_bytes=60, idle_timeout=5, idle_age=0, priority=65535,tcp,in_port=3,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:06,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,tp_src=2531,tp_dst=0 actions=output:1
1843 cookie=0x0, duration=2.88s, table=0, n_packets=1, n_bytes=60, idle_timeout=5, hard_timeout=10, idle_age=2, priority=65535,tcp,in_port=3,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:06,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,tp_src=2533,tp_dst=0 actions=output:1
1844 cookie=0x0, duration=5.672s, table=0, n_packets=1, n_bytes=60, idle_timeout=5, priority=65535,tcp,in_port=3,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:06,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,tp_src=2530,tp_dst=0 actions=output:1
1845 cookie=0x0, duration=1.04s, table=0, n_packets=1, n_bytes=60, idle_timeout=5, priority=65535,tcp,in_port=1,vlan_tci=0x0000,dl_src=50:54:00:00:00:06,dl_dst=50:54:00:00:00:05,nw_src=192.168.0.2,nw_dst=192.168.0.1,nw_tos=0,tp_src=0,tp_dst=2535 actions=output:3
1846 cookie=0x0, duration=1.952s, table=0, n_packets=1, n_bytes=60, idle_timeout=5, priority=65535,tcp,in_port=1,vlan_tci=0x0000,dl_src=50:54:00:00:00:06,dl_dst=50:54:00:00:00:05,nw_src=192.168.0.2,nw_dst=192.168.0.1,nw_tos=0,tp_src=0,tp_dst=2534 actions=output:3
1847 cookie=0x0, duration=4.668s, table=0, n_packets=1, n_bytes=60, idle_timeout=5, priority=65535,tcp,in_port=1,vlan_tci=0x0000,dl_src=50:54:00:00:00:06,dl_dst=50:54:00:00:00:05,nw_src=192.168.0.2,nw_dst=192.168.0.1,nw_tos=0,tp_src=0,tp_dst=2531 actions=output:3
1848 cookie=0x0, duration=3.752s, table=0, n_packets=1, n_bytes=60, idle_timeout=5, priority=65535,tcp,in_port=1,vlan_tci=0x0000,dl_src=50:54:00:00:00:06,dl_dst=50:54:00:00:00:05,nw_src=192.168.0.2,nw_dst=192.168.0.1,nw_tos=0,tp_src=0,tp_dst=2532 actions=output:3
1849 cookie=0x0, duration=0.172s, table=0, n_packets=1, n_bytes=60, idle_timeout=5, priority=65535,tcp,in_port=3,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:06,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,tp_src=2536,tp_dst=0 actions=output:1
1850 cookie=0x0, duration=5.624s, table=0, n_packets=1, n_bytes=60, idle_timeout=5, priority=65535,tcp,in_port=1,vlan_tci=0x0000,dl_src=50:54:00:00:00:06,dl_dst=50:54:00:00:00:05,nw_src=192.168.0.2,nw_dst=192.168.0.1,nw_tos=0,tp_src=0,tp_dst=2530 actions=output:3
1851 cookie=0x0, duration=0.08s, table=0, n_packets=1, n_bytes=60, idle_timeout=5, priority=65535,tcp,in_port=1,vlan_tci=0x0000,dl_src=50:54:00:00:00:06,dl_dst=50:54:00:00:00:05,nw_src=192.168.0.2,nw_dst=192.168.0.1,nw_tos=0,tp_src=0,tp_dst=2536 actions=output:3
1852 cookie=0x0, duration=1.96s, table=0, n_packets=1, n_bytes=60, idle_timeout=5, priority=65535,tcp,in_port=3,vlan_tci=0x0000,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:06,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,tp_src=2534,tp_dst=0 actions=output:1
e896c2d4 1853 cookie=0x0, duration=228.78s, table=0, n_packets=0, n_bytes=0, reg0=0x7b,tun_id=0x1c8 actions=load:0x5->NXM_NX_REG0[]
05b8f1c2 1854 cookie=0x0, duration=3600.0005s, table=1, n_packets=100, n_bytes=6400, actions=drop
fec00620
BP
1855]])
1856AT_CLEANUP
1857
1858AT_SETUP([NXST_AGGREGATE request])
1859AT_KEYWORDS([ofp-print OFPT_STATS_REQUEST])
1860AT_CHECK([ovs-ofctl ofp-print "\
186101 10 00 20 00 00 00 04 ff ff 00 00 00 00 23 20 \
186200 00 00 01 00 00 00 00 ff ff 00 00 ff 00 00 00 \
1863"], [0], [dnl
54ae6fa8 1864NXST_AGGREGATE request (xid=0x4): @&t@
fec00620
BP
1865])
1866AT_CLEANUP
1867
1868AT_SETUP([NXST_AGGREGATE reply])
1869AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
1870AT_CHECK([ovs-ofctl ofp-print "\
187101 11 00 30 00 00 00 04 ff ff 00 00 00 00 23 20 \
187200 00 00 01 00 00 00 00 00 00 00 00 00 00 00 07 \
187300 00 00 00 00 00 01 a4 00 00 00 07 00 00 00 00 \
1874"], [0], [dnl
1875NXST_AGGREGATE reply (xid=0x4): packet_count=7 byte_count=420 flow_count=7
1876])
1877AT_CLEANUP
2b07c8b1
BP
1878
1879AT_SETUP([NXST_FLOW_MONITOR request])
1880AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
1881AT_CHECK([ovs-ofctl ofp-print "\
188201 10 00 40 00 00 00 04 ff ff 00 00 00 00 23 20 00 00 00 02 00 00 00 00 \
188300 00 40 00 00 3f ff fe 00 00 01 00 00 00 00 00 \
188400 00 20 00 00 04 ff ff 00 06 02 00 00 00 00 00 00 00 00 02 00 01 00 00 \
1885"], [0], [dnl
1886NXST_FLOW_MONITOR request (xid=0x4):
1887 id=16384 flags=initial,add,delete,modify,actions,own out_port=LOCAL table=1
1888 id=8192 flags=delete table=2 in_port=1
1889])
1890AT_CLEANUP
1891
1892AT_SETUP([NXST_FLOW_MONITOR reply])
1893AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
1894AT_CHECK([ovs-ofctl ofp-print "\
189501 11 00 40 00 00 00 04 ff ff 00 00 00 00 23 20 00 00 00 02 00 00 00 00 \
189600 20 00 01 00 04 80 00 00 05 00 10 00 06 01 00 12 34 56 78 9a bc de f0 \
189700 00 00 02 00 01 00 00 \
189800 08 00 03 00 01 86 a0 \
1899"], [0], [dnl
1900NXST_FLOW_MONITOR reply (xid=0x4):
1901 event=DELETED reason=eviction table=1 idle_timeout=5 hard_timeout=16 cookie=0x123456789abcdef0 in_port=1
1902 event=ABBREV xid=0x186a0
1903])
1904AT_CLEANUP