From 2c7ba231d3dc28469c97a9f53ddf773266b7e795 Mon Sep 17 00:00:00 2001 From: Karol Latecki Date: Thu, 21 May 2020 09:45:46 +0200 Subject: [PATCH] test/vhost_perf: use system fio if not specified by user Use system-wide fio if a specific binary was not provided. Additionally add 1 second delay after finishing fio run to make sure fio client-server finishes correctly. Signed-off-by: Karol Latecki Change-Id: Id7d1e7f70017755206c8fe9942ef8d6051a73bbe Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/2559 Tested-by: SPDK CI Jenkins Community-CI: Mellanox Build Bot Reviewed-by: Darek Stojaczyk Reviewed-by: Changpeng Liu --- test/vhost/common.sh | 5 +++++ test/vhost/perf_bench/vhost_perf.sh | 1 - 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/test/vhost/common.sh b/test/vhost/common.sh index 55b6675a6..b7b475ae6 100644 --- a/test/vhost/common.sh +++ b/test/vhost/common.sh @@ -1066,6 +1066,10 @@ function run_fio() { return 1 fi + if [[ -z "$fio_bin" ]]; then + fio_bin="fio" + fi + if [[ ! -r "$job_file" ]]; then error "Fio job '$job_file' does not exist" return 1 @@ -1121,6 +1125,7 @@ function run_fio() { fi $fio_start_cmd + sleep 1 if [[ ! $hide_results ]]; then cat $out/$log_fname diff --git a/test/vhost/perf_bench/vhost_perf.sh b/test/vhost/perf_bench/vhost_perf.sh index e03197e5a..9c9b50181 100755 --- a/test/vhost/perf_bench/vhost_perf.sh +++ b/test/vhost/perf_bench/vhost_perf.sh @@ -23,7 +23,6 @@ split_bdevs=() used_vms="" wwpn_prefix="naa.5001405bc6498" -fio_bin="--fio-bin=/home/sys_sgsw/fio_ubuntu" fio_iterations=1 precond_fio_bin=$CONFIG_FIO_SOURCE_DIR/fio disk_map=""