aboutsummaryrefslogtreecommitdiffstats
path: root/tests/dpdk/dpdk_scripts/run_l3fwd.sh
diff options
context:
space:
mode:
authorPeter Mikus <pmikus@cisco.com>2020-04-17 12:38:09 +0000
committerPeter Mikus <pmikus@cisco.com>2020-04-23 12:36:54 +0000
commit54beb458703ff91e9f522f8af0a57722966f093e (patch)
tree5aa977fe9149e2d870ac87a35256783aeac60761 /tests/dpdk/dpdk_scripts/run_l3fwd.sh
parent5dc176ab31af5dff73be6dd5266169a7be19dd13 (diff)
Performance: DPDK refactor
+ Rework BASH scripts (more code to python). + Move BASH into libraries. + Allows RDMA usage. + Fix 9000B tests. + Rename confusing l2fwd -> testpmd. + Fix suite setup. + Fix PCI whitelist to not accidentally pickup wrong interface. + Fix deprecated DPDK cli arguments. - MLX5 jumbo are disabled on NIC (i will increase separately). https://jenkins.fd.io/job/csit-dpdk-perf-verify-master-2n-clx/6/console (l3fwd still broken) - MLX5 IMIX seems to be some TRex issue with IMIX for mlx5 (i will handle separately) Signed-off-by: Peter Mikus <pmikus@cisco.com> Change-Id: I31d1b67305fa247cb5e1f57e739d3ef30dc1a04b
Diffstat (limited to 'tests/dpdk/dpdk_scripts/run_l3fwd.sh')
-rwxr-xr-xtests/dpdk/dpdk_scripts/run_l3fwd.sh126
1 files changed, 0 insertions, 126 deletions
diff --git a/tests/dpdk/dpdk_scripts/run_l3fwd.sh b/tests/dpdk/dpdk_scripts/run_l3fwd.sh
deleted file mode 100755
index bab7668f5c..0000000000
--- a/tests/dpdk/dpdk_scripts/run_l3fwd.sh
+++ /dev/null
@@ -1,126 +0,0 @@
-#!/usr/bin/env bash
-
-# Copyright (c) 2020 Cisco and/or its affiliates.
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at:
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-set -xuo pipefail
-
-# Setting variables.
-DPDK_DIR="dpdk"
-ROOTDIR="/tmp/openvpp-testing"
-L3FWDLOG="screenlog.0"
-PWDDIR="$(pwd)"
-
-# Setting command line arguments.
-cpu_corelist="${1}"
-port_config="${2}"
-adj_mac0="${3}"
-adj_mac1="${4}"
-jumbo_frames="${5}"
-
-SCRIPT_NAME="$(basename $0)"
-
-# define a function to get the l3fwd PID.
-function get_l3fwd_pid()
-{
- pid_l3fwd=`sudo ps -elf | grep l3fwd | grep -v grep | grep -v SCREEN | grep -v ${SCRIPT_NAME} | awk '{print $4}'`
- echo "${pid_l3fwd}"
-}
-
-# Try to kill the l3fwd.
-# Don't use the pgrep and pkill.
-l3fwd_pid=`get_l3fwd_pid`
-echo "${l3fwd_pid}"
-if [ ! -z "${l3fwd_pid}" ]; then
- success=false
- sudo kill -15 "${l3fwd_pid}"
- echo "RC = ${?}"
- for attempt in {1..60}; do
- echo "Checking if l3fwd is still alive, attempt nr ${attempt}"
- l3fwd_pid=`get_l3fwd_pid`
- if [ -z "${l3fwd_pid}" ]; then
- echo "l3fwd is dead"
- success=true
- break
- fi
- echo "l3fwd is still alive, waiting 1 second"
- sleep 1
- done
- if [ "${success}" = false ]; then
- echo "The command sudo kill -15 l3fwd failed"
- sudo kill -9 "${l3fwd_pid}"
- echo "RC = ${?}"
- exit 1
- fi
-else
- echo "l3fwd is not running"
-fi
-
-# Try to kill the testpmd.
-sudo pgrep testpmd
-if [ ${?} -eq "0" ]; then
- success=false
- sudo pkill testpmd
- echo "RC = ${?}"
- for attempt in {1..60}; do
- echo "Checking if testpmd is still alive, attempt nr ${attempt}"
- sudo pgrep testpmd
- if [ ${?} -eq "1" ]; then
- echo "testpmd is dead"
- success=true
- break
- fi
- echo "testpmd is still alive, waiting 1 second"
- sleep 1
- done
- if [ "${success}" = false ]; then
- echo "The command sudo pkill testpmd failed"
- sudo pkill -9 testpmd
- echo "RC = ${?}"
- exit 1
- fi
-else
- echo "testpmd is not running"
-fi
-
-# Remove hugepages.
-sudo rm -f /dev/hugepages/*
-
-sleep 2
-
-cd "${ROOTDIR}/${DPDK_DIR}/"
-rm -f "${L3FWDLOG}"
-if [ "${jumbo_frames}" = "yes" ]; then
- sudo sh -c "screen -dmSL DPDK-test ./examples/l3fwd/build/app/l3fwd \
- -l ${cpu_corelist} -n 4 --log-level 8 -- \
- -P -L -p 0x3 --config='${port_config}' \
- --enable-jumbo --max-pkt-len=9000 --eth-dest=0,${adj_mac0} \
- --eth-dest=1,${adj_mac1} --parse-ptype"
-else
- sudo sh -c "screen -dmSL DPDK-test ./examples/l3fwd/build/app/l3fwd \
- -l ${cpu_corelist} -n 4 --log-level 8 -- \
- -P -L -p 0x3 --config='${port_config}' \
- --eth-dest=0,${adj_mac0} --eth-dest=1,${adj_mac1} --parse-ptype"
-fi
-
-for attempt in {1..60}; do
- echo "Checking if l3fwd is alive, attempt nr ${attempt}"
- fgrep "L3FWD: entering main loop on lcore" "${L3FWDLOG}"
- if [ "${?}" -eq "0" ]; then
- cat "${L3FWDLOG}"
- exit 0
- fi
- sleep 1
-done
-
-exit 1