-
Notifications
You must be signed in to change notification settings - Fork 53
server42dpdk and LAB(OVS)
Nikita Marchenko edited this page Jul 19, 2021
·
5 revisions
First way with pipework
- add
kilda_server42_control_switch_to_vlan_3000: "3000=00:00:00:00:00:00:01:01,00:00:00:00:00:00:01:02,00:00:00:00:00:00:01:03"
toconfd/vars/main.yaml
- uncomment
no_server42_server_stub
and commentno_server42_server
inconfd/vars/docker-compose.yaml
- build and run kilda
make up-stable
- shutdown
server42-server
containerdocker-compose stop server42-server
- run server42 with bash
docker-compose run --use-aliases server42-server bash
- create lab with lab service
- connect both docker instances with pipework
sudo ./pipework br_kilda_dpdk -i eth10 <instance id> 0/0
- create flow on lab
- run server42 with command
./server42 -c 0x1f --vdev=net_pcap0,iface=eth10,phy_mac=1 --no-huge -- --debug
- find server42 mac with
sudo tcpdump -elnXXi br_kilda_dpdk
. In case02:70:63:61:70:00 > 00:00:00:00:01:02
server42-adress is02:70:63:61:70:00
- put property with correct mac address to kilda switch properties and enable server42 rtt
- in lab instance add new link for strip server42 transport vlan
ip link add link eth10 name eth10.3000 type vlan id 3000
- up interface
sudo up ip link set up dev eth10.3000
- create new port for server42 in switch
ovs-vsctl add-port sw01 eth10.3000 -- set interface eth10.3000 ofport=10
. Here 3000 is transport vlan, sw01 is ovs switch and eth10 interface connected tobr_kilda_dpdk
lab - 3116a0642ea3 s42 - 2fd35a9c27ee
ip link add dev s42_ns type veth peer name s42_main
ip link add dev lab_ns type veth peer name lab_main
vconfig add lab_ns 3000
brctl addbr s42
brctl addif s42 s42_main
brctl addif s42 lab_main
ip link set up dev s42
ip link set up dev s42_main
ip link set up dev lab_main
ip link set s42_ns netns 2fd35a9c27ee
ip link set lab_ns.3000 netns 3116a0642ea3
ip netns exec 2fd35a9c27ee ip link set up dev s42_ns
ip netns exec 3116a0642ea3 ip link set up dev lab_ns.3000
ip link set up dev lab_ns
ovs-vsctl add-port sw01 lab_ns.3000 -- set interface lab_ns.3000 ofport=10
{
"switches": [
{
"name": "sw01",
"dp_id": "00:00:00:00:00:00:01:01",
"of_version": "OF_13",
"status": "active",
"max_port": 30,
"regions": [
1,
"1.stats"
],
"out_ports": [
{
"port": 10,
"vlan_range": "101..150"
}
],
"controller": "tcp:floodlight_1.pendev:6653"
},
{
"name": "sw02",
"dp_id": "00:00:00:00:00:00:01:02",
"of_version": "OF_13",
"status": "active",
"max_port": 30,
"regions": [
1,
"1.stats"
],
"out_ports": [
{
"port": 10,
"vlan_range": "101..150"
}
],
"controller": "tcp:floodlight_1.pendev:6653"
}
],
"isls": [
{
"src_switch": "sw01",
"src_port": 1,
"dst_switch": "sw02",
"dst_port": 1,
"max_bandwidth": 40000000
}
],
"traff_gens": [
],
"traff_gen_config": {
"address_pool_base": "172.16.80.0",
"address_pool_prefix_len": 20
}
}
{
"multi_table": true,
"server42_flow_rtt": true,
"server42_mac_address": "02:70:63:61:70:00",
"server42_port": 10,
"server42_vlan": 3000,
"supported_transit_encapsulation": [
"TRANSIT_VLAN"
],
"switch_arp": false,
"switch_lldp": false
}
{
"flowid": "fA",
"source": {
"port-id": 12,
"switch-id": "00:00:00:00:00:00:01:01",
"vlan-id": 102
},
"destination": {
"port-id": 12,
"switch-id": "00:00:00:00:00:00:01:02",
"vlan-id": 102
}
}