X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?a=blobdiff_plain;f=yardstick%2Fbenchmark%2Fcontexts%2Fstandalone%2Fmodel.py;h=30170832afbfba5adb165a70abc7b4dd74d867c1;hb=3d13a4e3a2a593cee37d55638d0c1e49cec1dea7;hp=85ae14b1dc05d38da6cef90d455c261ca34dfce7;hpb=e268fa7ae7c17604ecad787d6940fdf77426dc0f;p=yardstick.git diff --git a/yardstick/benchmark/contexts/standalone/model.py b/yardstick/benchmark/contexts/standalone/model.py index 85ae14b1d..30170832a 100644 --- a/yardstick/benchmark/contexts/standalone/model.py +++ b/yardstick/benchmark/contexts/standalone/model.py @@ -35,7 +35,7 @@ LOG = logging.getLogger(__name__) VM_TEMPLATE = """ - {vm_name} + {vm_name} {random_uuid} {memory} {memory} @@ -80,7 +80,13 @@ VM_TEMPLATE = """ - + + + + + + + """ WAIT_FOR_BOOT = 30 @@ -212,9 +218,8 @@ class Libvirt(object): mac.set('address', vf_mac) source = ET.SubElement(interface, 'source') - addr = ET.SubElement(source, 'address') pci_address = PciAddress(vf_pci.strip()) - cls._add_interface_address(addr, pci_address) + cls._add_interface_address(source, pci_address) pci_vm_address = PciAddress(vm_pci.strip()) cls._add_interface_address(interface, pci_vm_address) @@ -287,7 +292,8 @@ class StandaloneContextHelper(object): super(StandaloneContextHelper, self).__init__() @staticmethod - def install_req_libs(connection, extra_pkgs=[]): + def install_req_libs(connection, extra_pkgs=None): + extra_pkgs = extra_pkgs or [] pkgs = ["qemu-kvm", "libvirt-bin", "bridge-utils", "numactl", "fping"] pkgs.extend(extra_pkgs) cmd_template = "dpkg-query -W --showformat='${Status}\\n' \"%s\"|grep 'ok installed'"