blob: 6b6d4e1df948ba5b4501bc6a72ad97fde455313a [file] [log] [blame]
Matus Fabiana6110b62018-06-13 05:39:07 -07001create packet-generator interface pg0
2create packet-generator interface pg1
3
4packet-generator new {
5 name f1
6 limit 1000000
7 node ip4-input
8 size 64-64
Matus Fabiana6110b62018-06-13 05:39:07 -07009 worker 0
10 interface pg1
11 data {
12 UDP: 172.16.1.11 -> 172.16.1.3
13 UDP: 3001 -> 3000
14 length 128 checksum 0 incrementing 1
15 }
16}
17
18
19packet-generator new {
20 name f2
21 limit 1000000
22 node ip4-input
23 size 64-64
Matus Fabiana6110b62018-06-13 05:39:07 -070024 worker 1
25 interface pg1
26 data {
27 UDP: 172.16.1.10 -> 172.16.1.3
28 UDP: 3001 -> 3000
29 length 128 checksum 0 incrementing 1
30 }
31}
32
33nat44 add address 172.16.1.3
34nat44 add load-balancing static mapping protocol udp external 172.16.1.3:3000 local 10.0.0.10:30000 probability 25 local 10.0.0.11:30000 probability 25 local 10.0.0.12:30000 probability 25 local 10.0.0.13:30000 probability 25
35set int ip address pg0 10.0.0.1/24
36set int ip address pg1 172.16.1.1/24
37set int state pg0 up
38set int state pg1 up
ShivaShankarKb0f956c2020-03-18 15:34:11 +053039set ip neighbor static pg0 10.0.0.10 abcd.abcd.abcd
40set ip neighbor static pg0 10.0.0.11 abcd.abcd.abce
41set ip neighbor static pg0 10.0.0.12 abce.abcd.abcd
42set ip neighbor static pg0 10.0.0.13 abce.abcd.abce
43set ip neighbor static pg1 172.16.1.10 cdef.abcd.abcd
44set ip neighbor static pg1 172.16.1.11 cdef.abcd.abce
Matus Fabiana6110b62018-06-13 05:39:07 -070045set int nat44 in pg0 out pg1
46trace add pg-input 10