Enea Test VNF Example Use-cases The Enea Test VNF is a simple Enea Linux based VM, which can be used for various testing purposes, by using basic DPDK applications (e.g. testpmd) as well as non-DPDK tools (e.g. iPerf3). For more information about the Testpmd application please see the Testpmd Application User Guide.
Prerequisites Two uCPE devices will be required for this setup. The system requirements for each uCPE device are: 2 Network Interfaces. One for the Enea Edge Management application and one for data traffic. 2 GB of RAM memory The following files are needed for this example use case: VNF image: Enea Test VNF. Please contact Enea to get this image. VNF Configuration files. These files are provided with your Enea Edge release: enea-vnf-testpmd-fwd.conf. enea-vnf-testpmd-term.conf.
TestPMD VNF In this use-case, uCPE device 1 runs the pktgen DPDK application to generate traffic and uCPE device 2 runs two Enea Test VNFs. One VNF runs the TestPMD DPDK application forwarding traffic, and the other runs the TestPMD in order to terminate traffic.
TestPMD VNF Overview
Use-case Setup Network Configuration: Select uCPE device 1, access Configuration, add the network interface that will be used and configure it for DPDK. Note the PCI address of the interface, it will be used later to run the pktgen application. Select uCPE device 2, access Configuration, add the network interface that will be used and configure it for DPDK. Create an OVS bridge on uCPE device 2 and attach the DPDK interface. Onboarding the VNF: Onboard the Enea Test VNF by filling the required fields with the following values: VM Image File: Provide the path to the Enea Test VNF qcow2 image. Memory in MB: 2048 Num of CPUs: 2 Storage in GB: 10 Interfaces: Add 1 interface. Cloud-init Datasource: NoCloud Cloud-init Disk Type: disk Instantiating the VNFs: Instantiate the Enea Edge TestPMD forwarding VNF on uCPE Device 2 by filling the required fields with the following values: Name: testpmd_fwd VNF Type: Select Enea Test VNF. uCPE Device: Select uCPE device 2. Cloud Init File: Provide the path to the Enea VNF TestPMD forwarding cloud-init file. Interfaces: Set the interface type to DPDK and select the OVS bridge created above. Instantiate the Enea Edge TestPMD termination VNF on uCPE Device 2 by filling the required fields with the following values: Name: testpmd_term VNF Type: Select Enea Test VNF. uCPE Device: Select uCPE device 2. Cloud Init File: Provide the path to the Enea VNF TestPMD termination cloud-init file. Interfaces: Set the interface type to DPDK and select the OVS bridge created above. Creating OVS flow rules: Select uCPE device 2, access Configuration, open the OVS bridge and add two flow rules: Source: DPDK interface, Target: testpmd_fwd. Source: testpmd_fwd, Target: testpmd_term. The flow rules can be described using either the Enea Edge Management interface or the configuration files.
Testing the Use-case SSH to uCPE device 1 (Username: root) and start the pktgen application: cd /usr/share/apps/pktgen/ ./pktgen -c 0x7 -n 4 --proc-type auto --socket-mem 256 -w 0000:01:00.0 -- \ -P -m "[1:2].0" Pktgen:/> start 0 Replace 0000:01:00.0 with the actual PCI address of the network interface used on uCPE device 1. SSH to uCPE device 2 and connect to the TestPMD forwarding VNF console: virsh list virsh console <id of testpmd fwd> Check the TestPMD traffic forwarding statistics: # qemux86-64 login: root tail -f /var/log/testpmd-out
TestPMD VNF using PCI passthrough In this use case, uCPE device 1 will run the Pktgen and uCPE device 2 will run the TestPMD VNF. Both will be using PCI passthrough: Make sure that neither uCPE device 1 nor uCPE device 2 have any configured host interfaces by selcting uCPE device : Configuration -> OpenVSwitch -> Host Interfaces. On uCPE device 1 start the Pktgen VNF. Select PciPassthrough as the Interface type. From the drop-down list, select the PCI interface corresponding to the NIC which is connected to uCPE device 2: On uCPE device 2, start the TestPmdForwarder VNF. Select "PciPassthrough" as the Interface type. From the drop-down list, select the PCI interface corresponding to the NIC which is connected to uCPE device 1: To check that traffic is being forwarded from uCPE device 2, SSH to the uCPE device and connect to the VNFs console: Right click on uCPE device 2 and select SSH. Run: virsh list Run: virsh console [VM NAME] Run: tail -f /opt/testpmd-out