From 412e8eeccbc216c2d3488f34a5e6e1efbe3be843 Mon Sep 17 00:00:00 2001 From: m0duspwnens Date: Thu, 17 Dec 2020 18:05:25 -0500 Subject: [PATCH] tell dc to use 4 decimal spot for suriloss calc --- salt/telegraf/scripts/suriloss.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/salt/telegraf/scripts/suriloss.sh b/salt/telegraf/scripts/suriloss.sh index cc2cff94c..7ef8de2ee 100644 --- a/salt/telegraf/scripts/suriloss.sh +++ b/salt/telegraf/scripts/suriloss.sh @@ -44,7 +44,7 @@ if [ $CHECKIT == 2 ]; then TOTALPAST=$(($PASTPACKETS + $PASTDROP)) TOTAL=$(($TOTALCURRENT - $TOTALPAST)) - LOSS=$(echo $DROPPED $TOTAL / p | dc) + LOSS=$(echo 4 k $DROPPED $TOTAL / p | dc) echo "suridrop drop=$LOSS" fi else