From f68ff0bef1ce136003ede46b8e325e949238120c Mon Sep 17 00:00:00 2001 From: Rakshitha Kamath Date: Thu, 13 Jul 2023 22:15:38 +0530 Subject: [PATCH] Update the custom option for jobs pynfs and pynfs-acl to abort after 4 hours Signed-off-by: Rakshitha Kamath --- build_scripts/cthon04/client.sh | 19 ++++++++++++------- jobs/cthon04.yml | 1 + jobs/macros.yml | 15 ++++++++------- jobs/pynfs-acl.yml | 1 + jobs/pynfs-ceph.yml | 1 + jobs/pynfs.yml | 1 + 6 files changed, 24 insertions(+), 14 deletions(-) diff --git a/build_scripts/cthon04/client.sh b/build_scripts/cthon04/client.sh index b5c786e6..f4fc7c67 100644 --- a/build_scripts/cthon04/client.sh +++ b/build_scripts/cthon04/client.sh @@ -15,10 +15,14 @@ set -x # install build and runtime dependencies yum -y install git gcc nfs-utils time make -if [ "${CENTOS_VERSION}" == "9s" ]; then +if [ "${CENTOS_VERSION}" == "8s" ] || [ "${CENTOS_VERSION}" == "9s" ]; then yum -y install libtirpc-devel fi +#Logic to generate corefiles +echo "/tmp/cores/core.%e.%p.%h.%t" > /proc/sys/kernel/core_pattern +mkdir -p /tmp/cores + # checkout the connectathon tests git clone --depth=1 git://git.linux-nfs.org/projects/steved/cthon04.git cd cthon04 @@ -27,13 +31,14 @@ make all # v3 mount mkdir -p /mnt/nfsv3 mount -t nfs -o vers=3 ${SERVER}:${EXPORT} /mnt/nfsv3 -timeout -s SIGKILL 240s ./server -a -p ${EXPORT} -m /mnt/nfsv3 ${SERVER} -TIMED_OUT=$? +./server -a -p ${EXPORT} -m /mnt/nfsv3 ${SERVER} +#timeout -s SIGKILL 240s ./server -a -p ${EXPORT} -m /mnt/nfsv3 ${SERVER} +#TIMED_OUT=$? #Return code will be 124 if it ends the process by using SIGTERM for not getting any response. 137 when used SIGKILL to kill the process -if [ $TIMED_OUT == 137 ]; then - echo -e "The process timed out after 4 minute!\nLooks like the Server process to see if it has crashed!" - exit 1 -fi +#if [ $TIMED_OUT == 137 ]; then +# echo -e "The process timed out after 4 minute!\nLooks like the Server process to see if it has crashed!" +# exit 1 +#fi # v4 mount mkdir -p /mnt/nfsv4 diff --git a/jobs/cthon04.yml b/jobs/cthon04.yml index a9188fb5..3d94d413 100644 --- a/jobs/cthon04.yml +++ b/jobs/cthon04.yml @@ -35,6 +35,7 @@ wrappers: - cleanup-ws + - terminate_stuck_build - gerrithub_key publishers: diff --git a/jobs/macros.yml b/jobs/macros.yml index 3212fc54..75d815fe 100644 --- a/jobs/macros.yml +++ b/jobs/macros.yml @@ -130,13 +130,14 @@ variable: GERRITHUB_KEY #Enable this to over-ride the configuration under Manage Jenkins > Configure System > Global Build Time Out -#- wrapper: -# name: terminate_stuck_build -# wrappers: -# - timeout: -# timeout: 120 -# abort: true -# type: no-activity +#This one is meant for pynfs jobs, setting the value to 4 hours as a part of my testing! +- wrapper: + name: terminate_stuck_build + wrappers: + - timeout: + timeout: 240 + abort: true + type: no-activity - publisher: name: post_build_task_return-node diff --git a/jobs/pynfs-acl.yml b/jobs/pynfs-acl.yml index ecc4fa71..0094c827 100644 --- a/jobs/pynfs-acl.yml +++ b/jobs/pynfs-acl.yml @@ -46,6 +46,7 @@ wrappers: - gerrithub_key + - terminate_stuck_build - cleanup-ws publishers: diff --git a/jobs/pynfs-ceph.yml b/jobs/pynfs-ceph.yml index cc438263..acce0d1d 100644 --- a/jobs/pynfs-ceph.yml +++ b/jobs/pynfs-ceph.yml @@ -5,6 +5,7 @@ project-type: freestyle concurrent: false allow-manual-triggers: true + disabled: true scm: - ci-tests diff --git a/jobs/pynfs.yml b/jobs/pynfs.yml index 865387d4..5b347be7 100644 --- a/jobs/pynfs.yml +++ b/jobs/pynfs.yml @@ -38,6 +38,7 @@ wrappers: - gerrithub_key + - terminate_stuck_build - cleanup-ws triggers: