Update dsmon.sh

This commit is contained in:
2025-06-14 15:01:57 -05:00
parent a1e7f00574
commit 144efc878c

View File

@@ -160,6 +160,7 @@ CHECK(){
nc_count=0; lc_count=0; completed=false; scanstart=$(date +%s)
until [ "${completed}" == "true" ]; do
until [ $(ls /tmp/dscheck.*.done 2>/dev/null | wc -l) -gt 0 ]; do tmp=tmp; done
[ ${nc_count} -gt 0 ] && echo -en "\r\033[2K~\n\r\033[2K#\033[1A\r%"
for host in /tmp/dscheck.*.done; do
NTS=$(grep -oP '(?<=dscheck\.).*?(?=\.done)' <<< "${host}")
if [ -n "$NTS" ]; then
@@ -171,7 +172,6 @@ CHECK(){
((nc_count++))
fi
done
[ ${nc_count} -gt 0 ] && echo -en "\r\033[2K~\n\r\033[2K#\033[1A\r%"
if [ "${1}" != "report" ]; then
[ ${nc_count} -gt ${lc_count} ] && echo