From 575a302d75d6d02d0d4a0ce9a3ea0787af61b87d Mon Sep 17 00:00:00 2001 From: Michal Berger Date: Fri, 20 Jan 2023 01:29:21 +0100 Subject: [PATCH] autotest: Attempt to cleanup SPDK processes prior running tests There are some occasions where some phy nodes in the CI pool are not properly cleaned up due to various reasons - hard crashes, sudden network disconnects, etc. Whenever this happens, subsequent job on the affected node usually fails due to overall instability caused by lingering processes that should have been already killed. Example of such failure is https://github.com/spdk/spdk/issues/2749. This attempts to mitage potential impact of these issues under per-patch testing. Signed-off-by: Michal Berger Change-Id: I6e5c834ab77813e7484fa7f65c9d39967a305329 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/16364 Reviewed-by: Tomasz Zawadzki Reviewed-by: Jim Harris Tested-by: SPDK CI Jenkins --- autotest.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/autotest.sh b/autotest.sh index f2d7a1224..1b5bb49ce 100755 --- a/autotest.sh +++ b/autotest.sh @@ -113,6 +113,10 @@ done sync +if ! xtrace_disable_per_cmd reap_spdk_processes; then + echo "WARNING: Lingering SPDK processes were detected. Testing environment may be unstable" >&2 +fi + if [ $(uname -s) = Linux ]; then run_test "setup.sh" "$rootdir/test/setup/test-setup.sh" fi