System information
Manual:Tools/Traffic Generator
133
R1 routing and ipsec setup
/ip address
add address=192.168.33.1/30 interface=ether1
add address=1.1.1.2/24 interface=ether2
/ip route
add dst-address=2.2.2.0/24 gateway=192.168.33.2
/ip ipsec proposal
set default enc-algorithms=aes-128
/ip ipsec peer
add address=192.168.33.2 secret=123
/ip ipsec policy
add sa-src-address=192.168.33.1 sa-dst-address=192.168.33.2 \
src-address=1.1.1.0/24 dst-address=2.2.2.0/24 tunnel=yes
R2 routing and ipsec setup
/ip address
add address=192.168.33.2/30 interface=ether1
add address=2.2.2.2/24 interface=ether2
/ip route
add dst-address=1.1.1.0/24 gateway=192.168.33.1
/ip ipsec proposal
set default enc-algorithms=aes-128
/ip ipsec peer
add address=192.168.33.1 secret=123
/ip ipsec policy
add sa-src-address=192.168.33.2 sa-dst-address=192.168.33.1 \
src-address=2.2.2.0/24 dst-address=1.1.1.0/24 tunnel=yes
Traffig generator server setup
/ip address
add address=1.1.1.1/24 interface=ether2
add address=2.2.2.1/24 interface=ether3
First we will define which ports will be used as traffic generator tx/rx ports
/tool traffic-generator port
add disabled=no interface=ether2 name=port0
add disabled=no interface=ether3 name=port1
To construct actual packet that will be generated, packet-template is used.