forked from pktgen/Pktgen-DPDK
-
Notifications
You must be signed in to change notification settings - Fork 0
/
lb-fwd
402 lines (339 loc) · 8.11 KB
/
lb-fwd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
#
# Pktgen 23.03.1 (DPDK 23.07.0-rc0)
# Copyright(c) <2010-2024>, Intel Corporation. All rights reserved., Powered by DPDK
# Command line arguments: (DPDK args are defaults)
# ./usr/local/bin/pktgen -c 3ffc004 -n 3 -m 512 --proc-type primary -- -v -T -P -G -m [14-15:16-17].0 -m [18-19:20-21].1 -m [22-23:24-25].2 -f themes/black-yellow.theme -f lb-fwd
#######################################################################
# Pktgen Configuration script information:
# Flags 00000834
# Number of ports: 3
# Number ports per page: 4
# Number descriptors: RX 1024 TX: 2048
# Promiscuous mode is Enabled
# Global configuration:
disable mac_from_arp
######################### Port 0 ##################################
#
# Port: 0, Burst (Rx/Tx): 64/ 64, Rate:100%, Flags:00002014, TX Count:Forever
# Sequence count:0, Prime:1 VLAN ID:0001, Link: <UP-100000-FD>
#
# Set up the primary port information:
set 0 count 0
set 0 size 64
set 0 rate 100
set 0 rxburst 64
set 0 txburst 64
set 0 sport 1234
set 0 dport 80
set 0 prime 1
set 0 type ipv4
set 0 proto udp
set 0 dst ip 1.1.1.1
set 0 src ip 1.1.1.2/8
set 0 tcp flag clr all
set 0 tcp flag set ack
set 0 tcp seq 74616
set 0 tcp ack 74640
set 0 dst mac 5a:83:ca:8c:23:5d
set 0 src mac 00:11:22:33:44:01
set 0 vlan 1
set 0 pattern abc
set 0 jitter 50
disable 0 mpls
range 0 mpls entry 0x0
disable 0 qinq
set 0 qinqids 0 0
disable 0 gre
disable 0 gre_eth
disable 0 vxlan
set 0 vxlan 0x0 0 0
#
# Port flag values:
enable 0 icmp
disable 0 pcap
enable 0 range
disable 0 latency
enable 0 process
disable 0 capture
disable 0 rx_tap
disable 0 tx_tap
disable 0 vlan
#
# Range packet information:
range 0 src mac start 00:11:22:33:44:01
range 0 src mac min 00:00:00:00:00:00
range 0 src mac max 00:00:00:00:00:00
range 0 src mac inc 00:00:00:00:00:00
range 0 dst mac start 5a:83:ca:8c:23:5d
range 0 dst mac min 00:00:00:00:00:00
range 0 dst mac max 00:00:00:00:00:00
range 0 dst mac inc 00:00:00:00:00:00
range 0 src ip start 1.1.1.2
range 0 src ip min 0.0.0.0
range 0 src ip max 0.0.0.0
range 0 src ip inc 0.0.0.0
range 0 dst ip start 1.1.1.1
range 0 dst ip min 0.0.0.0
range 0 dst ip max 0.0.0.0
range 0 dst ip inc 0.0.0.0
range 0 proto udp
range 0 src port start 1000
range 0 src port min 1000
range 0 src port max 1010
range 0 src port inc 1
range 0 dst port start 80
range 0 dst port min 0
range 0 dst port max 0
range 0 dst port inc 0
range 0 tcp flag clr all
range 0 tcp flag set ack
range 0 tcp seq start 74616
range 0 tcp seq min 0
range 0 tcp seq max 536870911
range 0 tcp seq inc 0
range 0 tcp ack start 74640
range 0 tcp ack min 0
range 0 tcp ack max 536870911
range 0 tcp ack inc 0
range 0 ttl start 64
range 0 ttl min 0
range 0 ttl max 255
range 0 ttl inc 0
range 0 vlan start 1
range 0 vlan min 1
range 0 vlan max 4095
range 0 vlan inc 0
range 0 cos start 0
range 0 cos min 0
range 0 cos max 7
range 0 cos inc 0
range 0 tos start 0
range 0 tos min 0
range 0 tos max 255
range 0 tos inc 0
range 0 gre key 0
range 0 size start 64
range 0 size min 64
range 0 size max 1518
range 0 size inc 0
#
# Set up the sequence data for the port.
set 0 seq_cnt 0
######################### Port 1 ##################################
#
# Port: 1, Burst (Rx/Tx): 64/ 64, Rate:100%, Flags:00000014, TX Count:Forever
# Sequence count:0, Prime:1 VLAN ID:0001, Link: <UP-100000-FD>
#
# Set up the primary port information:
set 1 count 0
set 1 size 64
set 1 rate 100
set 1 rxburst 64
set 1 txburst 64
set 1 sport 1111
set 1 dport 2222
set 1 prime 1
set 1 type ipv4
set 1 proto udp
set 1 dst ip 198.18.0.5
set 1 src ip 198.18.0.2/24
set 1 tcp flag clr all
set 1 tcp flag set ack
set 1 tcp seq 74616
set 1 tcp ack 74640
set 1 dst mac 96:fd:bc:9d:f7:da
set 1 src mac 00:11:22:33:44:02
set 1 vlan 1
set 1 pattern abc
set 1 jitter 50
disable 1 mpls
range 1 mpls entry 0x0
disable 1 qinq
set 1 qinqids 0 0
disable 1 gre
disable 1 gre_eth
disable 1 vxlan
set 1 vxlan 0x0 0 0
#
# Port flag values:
enable 1 icmp
disable 1 pcap
disable 1 range
disable 1 latency
enable 1 process
disable 1 capture
disable 1 rx_tap
disable 1 tx_tap
disable 1 vlan
#
# Range packet information:
range 1 src mac start 3c:fd:fe:e4:38:41
range 1 src mac min 00:00:00:00:00:00
range 1 src mac max 00:00:00:00:00:00
range 1 src mac inc 00:00:00:00:00:00
range 1 dst mac start 3c:fd:fe:e4:38:40
range 1 dst mac min 00:00:00:00:00:00
range 1 dst mac max 00:00:00:00:00:00
range 1 dst mac inc 00:00:00:00:00:00
range 1 src ip start 192.168.1.1
range 1 src ip min 192.168.1.1
range 1 src ip max 192.168.1.254
range 1 src ip inc 0.0.0.0
range 1 dst ip start 192.168.2.1
range 1 dst ip min 192.168.2.1
range 1 dst ip max 192.168.2.254
range 1 dst ip inc 0.0.0.1
range 1 proto tcp
range 1 src port start 1234
range 1 src port min 0
range 1 src port max 65535
range 1 src port inc 1
range 1 dst port start 5678
range 1 dst port min 0
range 1 dst port max 65535
range 1 dst port inc 1
range 1 tcp flag clr all
range 1 tcp flag set ack
range 1 tcp seq start 74616
range 1 tcp seq min 0
range 1 tcp seq max 536870911
range 1 tcp seq inc 0
range 1 tcp ack start 74640
range 1 tcp ack min 0
range 1 tcp ack max 536870911
range 1 tcp ack inc 0
range 1 ttl start 64
range 1 ttl min 0
range 1 ttl max 255
range 1 ttl inc 0
range 1 vlan start 1
range 1 vlan min 1
range 1 vlan max 4095
range 1 vlan inc 0
range 1 cos start 0
range 1 cos min 0
range 1 cos max 7
range 1 cos inc 0
range 1 tos start 0
range 1 tos min 0
range 1 tos max 255
range 1 tos inc 0
range 1 gre key 0
range 1 size start 64
range 1 size min 64
range 1 size max 1518
range 1 size inc 0
#
# Set up the sequence data for the port.
set 1 seq_cnt 0
######################### Port 2 ##################################
#
# Port: 2, Burst (Rx/Tx): 64/ 64, Rate:100%, Flags:00000014, TX Count:Forever
# Sequence count:0, Prime:1 VLAN ID:0001, Link: <UP-100000-FD>
#
# Set up the primary port information:
set 2 count 0
set 2 size 64
set 2 rate 100
set 2 rxburst 64
set 2 txburst 64
set 2 sport 2222
set 2 dport 3333
set 2 prime 1
set 2 type ipv4
set 2 proto udp
set 2 dst ip 198.18.0.5
set 2 src ip 198.18.0.3/24
set 2 tcp flag clr all
set 2 tcp flag set ack
set 2 tcp seq 74616
set 2 tcp ack 74640
set 2 dst mac 96:fd:bc:9d:f7:da
set 2 src mac 00:11:22:33:44:03
set 2 vlan 1
set 2 pattern abc
set 2 jitter 50
disable 2 mpls
range 2 mpls entry 0x0
disable 2 qinq
set 2 qinqids 0 0
disable 2 gre
disable 2 gre_eth
disable 2 vxlan
set 2 vxlan 0x0 0 0
#
# Port flag values:
enable 2 icmp
disable 2 pcap
disable 2 range
disable 2 latency
enable 2 process
disable 2 capture
disable 2 rx_tap
disable 2 tx_tap
disable 2 vlan
#
# Range packet information:
range 2 src mac start 3c:fd:fe:e6:a5:70
range 2 src mac min 00:00:00:00:00:00
range 2 src mac max 00:00:00:00:00:00
range 2 src mac inc 00:00:00:00:00:00
range 2 dst mac start 3c:fd:fe:e6:a5:71
range 2 dst mac min 00:00:00:00:00:00
range 2 dst mac max 00:00:00:00:00:00
range 2 dst mac inc 00:00:00:00:00:00
range 2 src ip start 192.168.2.1
range 2 src ip min 192.168.2.1
range 2 src ip max 192.168.2.254
range 2 src ip inc 0.0.0.0
range 2 dst ip start 192.168.3.1
range 2 dst ip min 192.168.3.1
range 2 dst ip max 192.168.3.254
range 2 dst ip inc 0.0.0.1
range 2 proto tcp
range 2 src port start 1234
range 2 src port min 0
range 2 src port max 65535
range 2 src port inc 1
range 2 dst port start 5678
range 2 dst port min 0
range 2 dst port max 65535
range 2 dst port inc 1
range 2 tcp flag clr all
range 2 tcp flag set ack
range 2 tcp seq start 74616
range 2 tcp seq min 0
range 2 tcp seq max 536870911
range 2 tcp seq inc 0
range 2 tcp ack start 74640
range 2 tcp ack min 0
range 2 tcp ack max 536870911
range 2 tcp ack inc 0
range 2 ttl start 64
range 2 ttl min 0
range 2 ttl max 255
range 2 ttl inc 0
range 2 vlan start 1
range 2 vlan min 1
range 2 vlan max 4095
range 2 vlan inc 0
range 2 cos start 0
range 2 cos min 0
range 2 cos max 7
range 2 cos inc 0
range 2 tos start 0
range 2 tos min 0
range 2 tos max 255
range 2 tos inc 0
range 2 gre key 0
range 2 size start 64
range 2 size min 64
range 2 size max 1518
range 2 size inc 0
#
# Set up the sequence data for the port.
set 2 seq_cnt 0
# Enable screen updates and cleanup
on
cls
################################ Done #################################