diff options
Diffstat (limited to 'resources')
5 files changed, 24 insertions, 16 deletions
diff --git a/resources/libraries/python/ContainerUtils.py b/resources/libraries/python/ContainerUtils.py index 5e1ab5ab4f..9a141767b9 100644 --- a/resources/libraries/python/ContainerUtils.py +++ b/resources/libraries/python/ContainerUtils.py @@ -80,14 +80,21 @@ class ContainerManager(object): # Set cpuset.cpus cgroup skip_cnt = kwargs['cpu_skip'] + smt_used = CpuUtils.is_smt_enabled(kwargs['node']['cpuinfo']) if not kwargs['cpu_shared']: skip_cnt += kwargs['i'] * kwargs['cpu_count'] self.engine.container.cpuset_cpus = \ CpuUtils.cpu_slice_of_list_per_node(node=kwargs['node'], cpu_node=kwargs['cpuset_mems'], skip_cnt=skip_cnt, - cpu_cnt=kwargs['cpu_count'], - smt_used=kwargs['smt_used']) + cpu_cnt=1, + smt_used=False) \ + + \ + CpuUtils.cpu_slice_of_list_per_node(node=kwargs['node'], + cpu_node=kwargs['cpuset_mems'], + skip_cnt=skip_cnt+1, + cpu_cnt=kwargs['cpu_count']-1, + smt_used=smt_used) # Store container instance self.containers[kwargs['name']] = self.engine.container @@ -340,6 +347,7 @@ class ContainerEngine(object): 'priority=1', config_file=SUPERVISOR_CONF)) self.execute('supervisorctl reload') + self.execute('supervisorctl restart vpp') def restart_vpp(self): """Restart VPP service inside a container.""" diff --git a/resources/libraries/python/InterfaceUtil.py b/resources/libraries/python/InterfaceUtil.py index c5223d5496..7286633676 100644 --- a/resources/libraries/python/InterfaceUtil.py +++ b/resources/libraries/python/InterfaceUtil.py @@ -68,9 +68,9 @@ class InterfaceUtil(object): if node['type'] == NodeType.DUT: if state == 'up': - state = 'admin-up' + state = 'admin-up link-up' elif state == 'down': - state = 'admin-down' + state = 'admin-down link-down' else: raise ValueError('Unexpected interface state: {}'.format(state)) VatExecutor.cmd_from_template(node, 'set_if_state.vat', @@ -170,7 +170,7 @@ class InterfaceUtil(object): InterfaceUtil.vpp_set_interfaces_mtu_on_node(node, mtu) @staticmethod - def vpp_node_interfaces_ready_wait(node, timeout=10): + def vpp_node_interfaces_ready_wait(node, timeout=30): """Wait until all interfaces with admin-up are in link-up state. :param node: Node to wait on. @@ -205,7 +205,7 @@ class InterfaceUtil(object): sleep(1) @staticmethod - def vpp_nodes_interfaces_ready_wait(nodes, timeout=10): + def vpp_nodes_interfaces_ready_wait(nodes, timeout=30): """Wait until all interfaces with admin-up are in link-up state for listed nodes. @@ -219,7 +219,7 @@ class InterfaceUtil(object): InterfaceUtil.vpp_node_interfaces_ready_wait(node, timeout) @staticmethod - def all_vpp_interfaces_ready_wait(nodes, timeout=10): + def all_vpp_interfaces_ready_wait(nodes, timeout=30): """Wait until all interfaces with admin-up are in link-up state for all nodes in the topology. diff --git a/resources/libraries/robot/performance/performance_configuration.robot b/resources/libraries/robot/performance/performance_configuration.robot index 2e2eb84e2f..74b44b13c8 100644 --- a/resources/libraries/robot/performance/performance_configuration.robot +++ b/resources/libraries/robot/performance/performance_configuration.robot @@ -49,11 +49,11 @@ # library | | ${duts}= | Get Matches | ${nodes} | DUT* | | :FOR | ${dut} | IN | @{duts} -| | | Set Interface State | ${nodes['${dut}']} | ${${dut}_if1} | up | | | VPP Set Interface MTU | ${nodes['${dut}']} | ${${dut}_if1} -| | | Set Interface State | ${nodes['${dut}']} | ${${dut}_if2} | up +| | | Set Interface State | ${nodes['${dut}']} | ${${dut}_if1} | up | | | VPP Set Interface MTU | ${nodes['${dut}']} | ${${dut}_if2} -| | | VPP Node Interfaces Ready Wait | ${nodes['${dut}']} +| | | Set Interface State | ${nodes['${dut}']} | ${${dut}_if2} | up +| | All VPP Interfaces Ready Wait | ${nodes} | Initialize IPSec in 3-node circular topology | | [Documentation] @@ -997,6 +997,7 @@ | | ... | ${sock1} | ${sock2} | | Configure L2XC | ${dut2} | ${subif_index_2} | ${vhost_if1} | | Configure L2XC | ${dut2} | ${dut2_if2} | ${vhost_if2} +| | All VPP Interfaces Ready Wait | ${nodes} | Initialize L2 xconnect with Vhost-User and VLAN with VPP link bonding in 3-node circular topology | | [Documentation] diff --git a/resources/libraries/robot/shared/container.robot b/resources/libraries/robot/shared/container.robot index 201cadcb73..8a56caacb4 100644 --- a/resources/libraries/robot/shared/container.robot +++ b/resources/libraries/robot/shared/container.robot @@ -34,7 +34,7 @@ | | | Run Keyword | ${group}.Construct containers | | | ... | name=${dut}_${group} | node=${nodes['${dut}']} | mnt=${mnt} | | | ... | image=${container_image} | cpu_count=${container_cpus} -| | | ... | cpu_skip=${skip_cpus} | smt_used=${False} | cpuset_mems=${cpu_node} +| | | ... | cpu_skip=${skip_cpus} | cpuset_mems=${cpu_node} | | | ... | cpu_shared=${False} | env=${env} | count=${container_count} | | | ... | install_dkms=${container_install_dkms} | | Append To List | ${container_groups} | ${group} @@ -56,7 +56,7 @@ | | | Run Keyword | ${group}.Construct container | | | ... | name=${dut}_${group} | node=${nodes['${dut}']} | | | ... | image=${container_image} | cpu_count=${1} | cpu_skip=${0} -| | | ... | smt_used=${False} | cpuset_mems=${cpu_node} | cpu_shared=${True} +| | | ... | cpuset_mems=${cpu_node} | cpu_shared=${True} | | | ... | publish=${publish} | command=${command} | | Append To List | ${container_groups} | ${group} @@ -76,8 +76,7 @@ | | | Run Keyword | ${group}.Construct container | | | ... | name=${dut}_${group} | node=${nodes['${dut}']} | image=${image} | | | ... | cpu_count=${1} | cpu_skip=${0} | cpuset_mems=${cpu_node} -| | | ... | smt_used=${False} | cpu_shared=${True} | publish=${publish} -| | | ... | env=${env} +| | | ... | cpu_shared=${True} | publish=${publish} | env=${env} | | Append To List | ${container_groups} | ${group} | Acquire all '${group}' containers diff --git a/resources/libraries/robot/tcp/tcp_setup.robot b/resources/libraries/robot/tcp/tcp_setup.robot index 42026a1e2c..d2bc41fce0 100644 --- a/resources/libraries/robot/tcp/tcp_setup.robot +++ b/resources/libraries/robot/tcp/tcp_setup.robot @@ -34,7 +34,7 @@ | | | Run keyword | ${dut}.Add Unix Nodaemon | | | Run keyword | ${dut}.Add DPDK Socketmem | 4096,4096 | | | Run keyword | ${dut}.Add DPDK Log Level | debug -| | | Run keyword | ${dut}.Add DPDK Uio Driver | ${uio_driver} +| | | Run keyword | ${dut}.Add DPDK Uio Driver | | | Run keyword | ${dut}.Add Heapsize | 4G | | | Run keyword | ${dut}.Add Plugin | disable | default | | | Run keyword | ${dut}.Add Plugin | enable | @{plugins_to_enable} @@ -73,4 +73,4 @@ | | Vpp Node Interfaces Ready Wait | ${dut1} | | Start HTTP server params | ${dut1} | ${prealloc_fifos} | ${fifo_size} | | ... | ${private_segment_size} -| | Sleep | 30
\ No newline at end of file +| | Sleep | 30 |