go.ligato.io/vpp-agent/v3@v3.5.0/k8s/perf-demo/README.md (about) 1 ## Perfomance Demo Scenarios 2 ### Scenario 1 - 1 x VNF via memifs 3 <img src="scenario1/scenario1.png" width="400"> 4 5 6 ### Scenario 2 - 2 x VNF via memifs 7 <img src="scenario2/scenario2.png" width="400"> 8 9 ### Scenario 4 - 1 x VNF via veths+af_packet 10 <img src="scenario4/scenario4.png" width="400"> 11 12 13 ## Prepare Phase 14 Install and run Kubernetes, e.g. using [kubeadm](https://kubernetes.io/docs/setup/independent/create-cluster-kubeadm/). 15 16 Deploy ETCD and Kafka server PODs: 17 ``` 18 $ kubectl apply -f etcd.yaml 19 $ kubectl apply -f kafka.yaml 20 ``` 21 22 Verify the ETCD and Kafka PODs are ready: 23 ``` 24 $ kubectl get pods 25 NAME READY STATUS RESTARTS AGE 26 etcd-server 1/1 Running 0 12s 27 kafka-server 1/1 Running 0 5s 28 ``` 29 30 31 Modify ETCD configuration files, which contain physical interface names 32 `FortyGigabitEthernet89/0/0` and `FortyGigabitEthernet89/0/1`. If this does 33 not match your setup, set the names as follows: 34 ``` 35 ./interfaces.sh GigabitEthernet0/0/1 GigabitEthernet0/0/2 36 ``` 37 38 Also modify VPP startup config files for each scenario, to match your HW, e.g. 39 [scenario1/vswitch/vswitch-vpp-cfg.yaml](scenario1/vswitch/vswitch-vpp-cfg.yaml). 40 PIC addresses of the NICs should match interface names, e.g. ` 0000:89:00.0` 41 corresponds to `FortyGigabitEthernet89/0/0`. 42 43 If the two above steps are not configured properly, the demo will still work, 44 but the vSwitch will lack the physical interfaces. 45 46 47 ## Deploy Network Service 48 Import ETCD configuration for the given scenario (1, 2 or 4): 49 ``` 50 $ sudo ./etcdimport.sh scenario1/etcd.txt 51 ``` 52 53 Deploy vSwitch + VNF PODs of the given scenario (1, 2 or 4): 54 ``` 55 $ kubectl apply -R -f scenario1 56 ``` 57 58 Verify the PODs are ready: 59 ``` 60 $ kubectl get pods 61 NAME READY STATUS RESTARTS AGE 62 etcd-server 1/1 Running 0 33m 63 kafka-server 1/1 Running 0 6h 64 vnf-vpp 1/1 Running 0 26s 65 vswitch-vpp 1/1 Running 0 26s 66 ``` 67 68 ## Verify Service is Up 69 70 Telnet to the vSwitch VPP: 71 ``` 72 $ telnet localhost 5002 73 vpp# show interface 74 vpp# quit 75 ``` 76 77 Telnet to the VNF VPP: 78 ``` 79 $ kubectl describe pod vnf-vpp | grep IP 80 IP: 192.168.65.193 81 $ telnet 192.168.65.193 5002 82 vpp# show interface 83 vpp# quit 84 ``` 85 (use `vnf1-vpp` / `vnf2-vpp` instead of `vnf-vpp` for the scenario 2) 86 87 88 ## Cleanup 89 Undeploy the scenario: 90 ``` 91 $ kubectl delete -R -f scenario1/ 92 ``` 93 94 Wipe ETCD (restart it): 95 ``` 96 $ kubectl delete -f etcd.yaml 97 $ kubectl apply -f etcd.yaml 98 ``` 99 (make sure the POD gets undeployed after `delete` before `apply` by executing `kubectl get pods`) 100 101 You can continue with deploying of the next scenario as described in [Deploy Network Service](#Deploy Network Service).