aboutsummaryrefslogtreecommitdiffstats
path: root/yardstick/benchmark/contexts/standalone
AgeCommit message (Collapse)AuthorFilesLines
2019-04-19Log VM OS version, Sample VNF branch/commit IDStepan Andrushko1-0/+11
Added debug logs to track VM, Sample VNF details during testing: - Virtual machine OS, kernel version; - Sample VNF branch, commit ID. JIRA: YARDSTICK-1499 Change-Id: I243c435809d4541dfdb8c7c3466f50c5d524ac00 Signed-off-by: Stepan Andrushko <stepanx.andrushko@intel.com>
2018-11-29Merge "Distribute dpdk/vhostuser between CPUs for SA OVS"Volodymyr Mytnyk1-10/+25
2018-11-22Fix OvS-DPDK context mem allocation problemMytnyk, Volodymyr1-5/+11
The hugepages allocated for OvS-DPDK context is not correct, thus it is causing an issue to allocate the required amount of memory for VM. JIRA: YARDSTICK-1538 Change-Id: I1a34199d4f78c999476603fa86d79ffc1fbf27c8 Signed-off-by: Mytnyk, Volodymyr <volodymyrx.mytnyk@intel.com>
2018-11-20Make VM machine type as a user configurationMytnyk, Volodymyr1-2/+4
For backward compatibility, the default value of this option has been left unchanged. JIRA: YARDSTICK-1528 Change-Id: I42ceca96501f1136cba27d85c2d82240bd45c10c Signed-off-by: Mytnyk, Volodymyr <volodymyrx.mytnyk@intel.com>
2018-11-13Distribute dpdk/vhostuser between CPUs for SA OVSStepan Andrushko1-10/+25
Update Yardstick with ability to distribute DPDK/vhost-user ports/queues between CPU cores. Extended OVS add vhost-user interface command with option "n_rxq", provided in the test case. Ordered ports added to OVS. JIRA: YARDSTICK-1490 Change-Id: I71f5d878a9ee3a11f636762fc16b04ee6bc79e14 Signed-off-by: Stepan Andrushko <stepanx.andrushko@intel.com>
2018-11-07Merge "Setup hugepages on SA host(sriov, ovs_dpdk)"Abhijit Sinha2-1/+10
2018-11-07Merge "Make OvS max_idle & queues configuration optional"Abhijit Sinha2-5/+14
2018-11-07Merge "Update: assign static IP to VM for standalone"Abhijit Sinha1-1/+3
2018-11-02Make OvS max_idle & queues configuration optionalMytnyk, Volodymyr2-5/+14
Remove hardcoded rx queue value JIRA: YARDSTICK-1493 Change-Id: Ia4944db21d94399c724bcabf4e0eae809518e7e9 Signed-off-by: Mytnyk, Volodymyr <volodymyrx.mytnyk@intel.com>
2018-10-30Update: assign static IP to VM for standaloneStepan Andrushko1-1/+3
Updated cloud-init network file to be used on Ubuntu 16.04 and Ubuntu 18.04. Fields 'macaddress' and 'prefix' modified in network-config file. JIRA: YARDSTICK-1402 Change-Id: Ibe7fb9dbf23326a0a6106f98d3b2b9fedf81f79a Signed-off-by: Stepan Andrushko <stepanx.andrushko@intel.com>
2018-10-30Make OvS to listen on TCP by defaultMytnyk, Volodymyr1-2/+2
JIRA: YARDSTICK-1492 Change-Id: I81c682d473ffe3d70ecbb42cce40c2d16e608b41 Signed-off-by: Mytnyk, Volodymyr <volodymyrx.mytnyk@intel.com>
2018-10-27Setup hugepages on SA host(sriov, ovs_dpdk)Serhiy Pshyk2-1/+10
JIRA: YARDSTICK-1461 Change-Id: Ia1f5026eee989672aac57775ec9dd182df658fa4 Signed-off-by: Serhiy Pshyk <serhiyx.pshyk@intel.com>
2018-10-12Merge "Add OvS 2.8.1 support into SA context"Abhijit Sinha1-1/+2
2018-10-12Merge "Configure n_rxq DPDK port option when adding the port"Abhijit Sinha1-7/+5
2018-10-04Configure n_rxq DPDK port option when adding the portMytnyk, Volodymyr1-7/+5
On some platform, setting n_rxq option on port separately does not work well and causes issues like port link down, so changed the logic to set n_rxq DPDK port option during adding the port to the bridge which help to resolve the problem. JIRA: YARDSTICK-1463 Change-Id: Icdb064153a38afd53b835de8742e6fcef08f66bb Signed-off-by: Mytnyk, Volodymyr <volodymyrx.mytnyk@intel.com>
2018-10-04Add OvS 2.8.1 support into SA contextMytnyk, Volodymyr1-1/+2
JIRA: YARDSTICK-1462 Change-Id: I001a173fc728be6e88f5ae6d38c64b740e536ff2 Signed-off-by: Mytnyk, Volodymyr <volodymyrx.mytnyk@intel.com>
2018-09-20SA: Fix private key file name generation issueMytnyk, Volodymyr1-1/+1
In current implementation of Yardstick, SA context uses the same SSH key file name for each VM created. E.g. the Yardstick overrides the key file context each time the new VM is created. As a result, the key file is valid only for last VM created by Yardstick causing the connection problem for other VMs. Solution is to generate different key file name for each VM name separately. JIRA: YARDSTICK-1436 Change-Id: I22ae2874695736255aa3314654a2cced9338b53d Signed-off-by: Mytnyk, Volodymyr <volodymyrx.mytnyk@intel.com>
2018-08-29Assign static IP to VM for standalone contextStepan Andrushko3-13/+35
During VM spawning IP address should be assigned by DHCP server in the local network. Sometimes DHCP server is not capable to assign IP address. So, need to add static IP address. JIRA: YARDSTICK-1402 Change-Id: Ie59c340eb88eddcaff043496fc20aa48b49205ec Signed-off-by: Stepan Andrushko <stepanx.andrushko@intel.com>
2018-08-23Provide access to VM in Standalone contextStepan Andrushko3-17/+134
Add possibility to access VM with SampleVNF image, which is spawned on baremetal server using password or key pairs (provided or generated). Changes provided for OVS-DPDK and SRIOV cases. JIRA: YARDSTICK-1260 Change-Id: I89cf17dc83f02abe23d206b24b9d0ec1298d3231 Signed-off-by: Stepan Andrushko <stepanx.andrushko@intel.com>
2018-07-05Make context types constantsRodolfo Alonso Hernandez2-8/+10
Make context types constants. These are the current context types: - Dummy - Heat - Kubernetes - Node - StandaloneOvsDpdk - StandaloneSriov Any reference to a context type should use the referred constant. JIRA: YARDSTICK-1292 Change-Id: I1ff0085161f88304d71e3ddad7975f9020e0fc20 Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
2018-06-29Move "read_yaml_file" to common.yaml_loaderRodolfo Alonso Hernandez1-3/+3
JIRA: YARDSTICK-1265 Change-Id: Ic2813dca7fc9a3230632f6e8bd75aeacc7e951b0 Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
2018-06-26Extended Context class with get_physical_nodes functionalityChornyi, TarasX3-11/+34
JIRA: YARDSTICK-1255 Change-Id: I446d715dc6cf716a4fcbc1b809c1b1d6303071e0 Signed-off-by: Chornyi, TarasX <tarasx.chornyi@intel.com>
2018-06-14Merge "Add "host_name_separator" variable to Context class"Rodolfo Alonso Hernandez2-2/+2
2018-05-22Standalone XML machine type is not longer validRodolfo Alonso Hernandez1-1/+1
Current XML machine type definition [1] is not longer valid. According to [2], the default machine type should be "pc-i440fx-xenial". NOTE: StandAlone physical nodes are deployed using Ubuntu OS. [1]https://github.com/opnfv/yardstick/blob/master/yardstick/benchmark/contexts/standalone/model.py#L48 [2]https://wiki.ubuntu.com/QemuKVMMigration#Upgrade_machine_type JIRA: YARDSTICK-1192 Change-Id: I77b1379aaf416b1225e91af2c3ac746cb101f774 Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
2018-05-22Error when adding SR-IOV interfaces in SR-IOV contextRodolfo Alonso Hernandez1-3/+3
Method "add_sriov_interfaces" in Libvirt class throws an error when trying to add SR-IOV interfaces in the XML file. Function "setup_sriov_context" in SriovContext if passing to "_enable_interfaces" method the XML file name instead of passing the XML string. JIRA: YARDSTICK-1189 Change-Id: If021c102311ecb98cb26934f78067dfc720e4291 Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
2018-05-21Add "host_name_separator" variable to Context classRodolfo Alonso Hernandez2-2/+2
This feature will provide Kubernetes context the ability to handle the context name inside the class itself, providing to the developer an abstraction of the possible naming limitations in Kubernetes. E.g.: "dot" character in Pod names is no allowed [1]. [1] https://github.com/fabric8io/fluent-plugin-kubernetes_metadata_filter/issues/58 JIRA: YARDSTICK-1188 Change-Id: I82121f970b550170357a443b6340be7900602a57 Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
2018-04-16Improve "Libvirt.create_snapshot_qemu" functionRodolfo Alonso Hernandez1-8/+34
Improved "Libvirt.create_snapshot_qemu" function: - Check if the base image is present in the remote host. If not, try to copy from the execution host. - Check the execution status. In case the command fails, raise an exception. JIRA: YARDSTICK-944 Change-Id: I78bd0d3ed6a1f35ed772c0d192bb240009a580ed Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
2018-03-28Remove tool provisioning in Standalone contextsRodolfo Alonso Hernandez2-9/+5
In both Standalone contexts, SR-IOV and DPDK, the tool provisioning must be removed. If the tool, "dpdk-devbind.py", is not in the VNF, the test should fail because this tool should be provided during the provisioning, not during the test execution. JIRA: YARDSTICK-1092 Change-Id: I212c1303fd655f151e9c0efc29aad97fe6d71d1c Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
2018-03-21Improve "Libvirt.virsh_destroy_vm" functionRodolfo Alonso Hernandez1-1/+4
Read the command exit code and log a warning in case the VM destroy process went wrong. JIRA: YARDSTICK-943 Change-Id: I2750b8d4a8f67af081c1988510cf5aca848a2cf1 Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
2018-03-21Improve "Libvirt.virsh_create_vm" functionRodolfo Alonso Hernandez1-2/+4
Read the command exit code and raise an exception in case the VM boot process went wrong. JIRA: YARDSTICK-941 Change-Id: Ibabaae8983213a33799ad00fa4d9541bbabea857 Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
2018-03-21Improve NSB Standalone XML generationRodolfo Alonso Hernandez3-49/+54
Delayed the generation of the XML file until the last step. The following functions will return a XML string insted: - Libvirt.build_vm_xml - SriovContext._enable_interfaces - OvsDpdkContext._enable_interfaces The XML file will be written just before copying the file to the compute hosting the VMs. JIRA: YARDSTICK-939 Change-Id: Icc80f4741903bbe335db4ebccab395b72fa87e82 Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
2018-03-21Improve OVS-DPDK setup processRodolfo Alonso Hernandez1-23/+21
Improved OVS-DPDK setup process: - Added log string for each command executed. - Removed unnecessary 'kill' command. - Check if commands are executed correctly. JIRA: YARDSTICK-922 Change-Id: I09fba96ffa39cde1e000a3c4382d474219c99985 Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
2018-03-21Improve OVS-DPDK boot processRodolfo Alonso Hernandez2-70/+98
Check if hugepages are present in the system. Check if every command executed during the boot up process exits correctly. JIRA: YARDSTICK-917 Change-Id: Ic0c8a72199ad80e3a65488cc88d0692863751284 Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
2018-03-01Add qualified name to ContextEmma Foley2-4/+2
The context name depends on the defined name in the testcase input file, the task ID and the flags of the context. If the context is going to be undeployed at the end of the test, the task ID is suffixed to the name to avoid interferences with previous deployments. If the context needs to be deployed at the end of the test, the name assigned is kept. This patch makes base.Context use Flags when initialising contexts, this sets the name property based on the no_setup and no_teardown flags. Since base.Context is an abstract class, it cannot be instantiated. However, there are some non-abstract methods that need testing. Since DummyContext does not override any of these methods, it can be used for testing. JIRA: YARDSTICK-886 Change-Id: I1447fb5ed447691eaeb0a97f928c0b3333799d07 Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com> Signed-off-by: Emma Foley <emma.l.foley@intel.com>
2018-02-05Remove references to "dpdk_nic_bind" utilityRodolfo Alonso Hernandez3-22/+20
In DPDK 16.07 [1], "dpdk_nic_bind" utility was renamed to "dpdk-devbind". This patch removes all references to this previous naming to avoid confusions. [1] https://dpdk-guide.gitlab.io/dpdk-guide/setup/binding.html JIRA: YARDSTICK-995 Change-Id: I827c4c11c9e9e519f33f21b80459e7d65e51545e Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
2018-01-24Merge "'libvirt' guest console in Standalone model"Ross Brattain1-3/+10
2018-01-16bugfix: Fix duplicate 'address' in standlone SRIOVDino Madarang1-2/+1
* Add unit test per Rodolfo's comment Creating a VM using generted xml file /tmp/vm_sriov_0.xml returns an XML error: missing source address type. This fix modifies generted xml from: <source> <address> <address bus="0x1a" domain="0x0000" function="0x0" slot="0x10" type="pci" /> </address> </source> to: <source> <address bus="0x1a" domain="0x0000" function="0x0" slot="0x10" type="pci" /> </source> Change-Id: I694153e7468986bacb19ba3e09e761993aad7184 Signed-off-by: Dino Simeon Madarang <dinox.madarang@intel.com> Reviewed-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com> Reviewed-by: Ross Brattain <ross.b.brattain@intel.com> Reviewed-by: Alain Jebara <alain.jebara@intel.com> Reviewed-by: Emma Foley <emma.l.foley@intel.com>
2017-12-16samples: Add generic L3 forwarder testsDino Madarang2-3/+14
A generic throughput test case that can be used as a stub code for a Linux-based VNF configured as an L3 forwarder. Supported context: * Standalone OVSDPDK and SRIOV * Baremetal Code changes: * Allow pmd-cpu-mask and lcore mask for OVS DPDK * router_vnf.py - configures interface IP addresses and static arp entries using ip command * NFVi KPIs * Allow cputune tag for standalone context to be able to PIN on NUMA 1 cpus SRIOV Test cases: * RFC2544 Ethernet framesizes, 128K Flows * 2,4 and 6 ports * 2 and 3 vcpus per port * OVSDPDK Test cases: * RFC2544 Ethernet framesizes, 128K Flows * 2 and 4 ports * 2 vcpus per port * 2 PMD threads per port TODO: * Documentation * Add 6 ports tests References: * router_vnf.py is based on sample_vnf.py * tc_*.yaml files are based on acl/vfw test case files Added unitests Added get_stats to parse ip -s link Change-Id: Id1b969d5420dfcab7c1e695acbd2cd1655747efe Signed-off-by: Dino Simeon Madarang <dinox.madarang@intel.com> Signed-off-by: Kavindya Deegala <kavindya.s.deegala@intel.com> Reviewed-by: Alain Jebara <alain.jebara@intel.com> Reviewed-by: Deepak S <deepak.s@linux.intel.com> Reviewed-by: Emma Foley <emma.l.foley@intel.com> Reviewed-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com> Reviewed-by: Ross Brattain <ross.b.brattain@intel.com> Reviewed-by: Edward MacGillivray <edward.s.macgillivray@intel.com> Signed-off-by: Dhaval Patel <dhaval.r.patel@intel.com> Signed-off-by: Ross Brattain <ross.b.brattain@intel.com>
2017-12-15'libvirt' guest console in Standalone modelJan Malanik1-3/+10
Add support for 'libvirt' guest console in Standalone model. Change-Id: I660e641339658d8abe4f040bec96e9d0041402c6 Signed-off-by: Jan Malanik <janx.malanik@intel.com>
2017-12-15NSB: Fix standalone.model.Libvirt SR-IOV modelingDino Madarang3-50/+95
Fixed standalone.model.Libvirt SR-IOV XML interface modeling, acording to [1]: - All PCI attributes now are printed in hexadecimal format. - The PCI address is now added in the correct section, 'interface'. network_services.utils.PciAddress was refactored to accept both 'domain: bus:slot:function' and 'bus:slot:function' format inputs. This class is used as input in the previous class, Libvirt, to print in XML the PCI address of a SR-IOV interface. network_services.utils.PciAddress.parse_address is now deprecated. Instead the class standard instantiation must be used: libvirt_obj = utils.PciAddress(text_with_address) A deprecation decorator is implemented along with this patch. This decorator is used for the first time in the previously mentioned function. This decorator stores every decorated function name and deprecation message and raises a logging warning message the first time this function is used. [1] https://goo.gl/so2Mrp Change-Id: I22e95c488e27d6e2a8fdf6c1a07faab275fa6bba Signed-off-by: Dino Simeon Madarang <dinox.madarang@intel.com> Reviewed-by: Alain Jebara <alain.jebara@intel.com> Reviewed-by: Deepak S <deepak.s@linux.intel.com> Reviewed-by: Ross Brattain <ross.b.brattain@intel.com> Reviewed-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
2017-11-20NSB: Fix IndexError in pin_vcpu_for_perfDino Madarang1-1/+1
This addresses the IndexError in Standalone SRIOV/OVSDPDK context. The correct sys_cpu number should be sys_cpu-1 Error: threads = "%s-%s" % (soc_cpu[socket][sys_cpu], soc_cpu[socket][-1]) IndexError: list index out of range Tested platform: (Hyper-Threading disabled) NUMA node0 CPU(s): 0-21 NUMA node1 CPU(s): 22-43 With socket equal to 0, sys_cpu value was 22 which resulted to IndexError. Change-Id: I36b045cacce4caff4b5ddafaa9b6737f1c6df0a1 Signed-off-by: Dino Simeon Madarang <dinox.madarang@intel.com> Reviewed-by: Alain Jebara <alain.jebara@intel.com> Reviewed-by: Deepak S <deepak.s@linux.intel.com> Reviewed-by: Ross Brattain <ross.b.brattain@intel.com> Reviewed-by: Edward MacGillivray <edward.s.macgillivray@intel.com>
2017-10-19Merge "Create the ovs-vswitchd logging directory"Ross Brattain1-0/+1
2017-10-19Merge "Disable spoof check on vfs in sriov setup"Ross Brattain1-0/+3
2017-10-18Create the ovs-vswitchd logging directoryMartin Banszel1-0/+1
Change-Id: Id7f55f7fcb2fec2866b76821595776908ac30c04 Signed-off-by: Martin Banszel <martinx.banszel@intel.com>
2017-10-16Disable spoof check on vfs in sriov setupDeepak S1-0/+3
Change-Id: I8577231c2e78776cb30f7f7ded353a4fbc585aaa Signed-off-by: Deepak S <deepak.s@linux.intel.com>
2017-10-16Adding cpu set to enable affinity for given vcpuDeepak S3-43/+17
Change-Id: If2e079966939b7faa33d2833d81caad0a3669036 Signed-off-by: Deepak S <deepak.s@linux.intel.com>
2017-09-29Enabling multi_VM & multi port launch in standalone contextDeepak S5-977/+1103
new context names: - SRIOV - StandaloneSriov - OvsDpdk - StandaloneOvsDpdk - Seperate helper, libvirt, server info class - Allow multi-port and multi-VM support. Change-Id: I3c65e4535082fa0e2f4c6ee11c3bca9ccfdc01b8 Signed-off-by: Deepak S <deepak.s@linux.intel.com> Signed-off-by: Martin Banszel <martinx.banszel@intel.com>
2017-08-21Refactor to make file sys more like class inheritanceEdward MacGillivray3-0/+1011
Change-Id: I5471d2e894ca78407a57f3ba01202264c69ad174 Signed-off-by: Edward MacGillivray <edward.s.macgillivray@intel.com>