From fafd9877ce9861e295d957148dbbe67faeba6c5c Mon Sep 17 00:00:00 2001 From: Wenchao Hao Date: Thu, 21 Sep 2023 16:45:35 +0800 Subject: [PATCH] update --- checkstat.sh | 2 +- loop.sh | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/checkstat.sh b/checkstat.sh index 778dc3d..595eb8d 100644 --- a/checkstat.sh +++ b/checkstat.sh @@ -7,7 +7,7 @@ do hostbusy=$(cat /sys/class/scsi_host/host3/host_busy) echo -e "\e[36mhost busy :\t \e[32m$hostbusy\e[0m" echo -e "\e[36mhost state :\t \e[32m$(cat /sys/class/scsi_host/host3/state)\e[0m" - echo -e "\e[36mfio :\t \e[32m$(ps aux | grep -c fio)\e[0m" + echo -e "\e[36mfio :\t \e[32m$(ps aux | grep dev | grep -c fio)\e[0m" ps aux | grep -w sh | grep D echo -e "\e[36m-------------------------------------\e[0m" diff --git a/loop.sh b/loop.sh index 0f7492f..aef4496 100644 --- a/loop.sh +++ b/loop.sh @@ -9,7 +9,7 @@ function add_fio() for dev in `lsscsi | grep scsi_debug | awk '{print $6}'` do fio_cnt=$(ps aux | grep fio | grep $dev -c) - if [ $fio_cnt -gt 20 ]; then + if [ $fio_cnt -gt 15 ]; then echo "$fio_cnt larger than 20, do not add" continue fi @@ -20,7 +20,7 @@ function add_fio() done - sleep 10 + sleep 3 done }