net/mwan3: update logging output
authorFlorian Eckert <fe@dev.tdt.de>
Fri, 11 May 2018 06:35:43 +0000 (08:35 +0200)
committerFlorian Eckert <fe@dev.tdt.de>
Fri, 11 May 2018 06:46:40 +0000 (08:46 +0200)
Unify logging output for tracking methode ping.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
net/mwan3/files/usr/sbin/mwan3track

index f445b146e0e88328e77ab4387cb2d40bee35b77c..9bc17ed8d5cf2504d9d434de63a0b27a5de2c91f 100755 (executable)
@@ -162,7 +162,7 @@ main() {
                                                echo "$loss" > /var/run/mwan3track/$1/LOSS_${track_ip}
 
                                                if [ $score -gt $up ]; then
-                                                       $LOG info "Failed: Latency=$latency ms Loss=$loss% for target \"$track_ip\" on interface $1 ($2)"
+                                                       $LOG info "Check (${track_method}: latency=${latency}ms loss=${loss}%) failed for target \"$track_ip\" on interface $1 ($2)"
                                                fi
                                        elif [ "$loss" -le "$recovery_loss" -a "$latency" -le "$recovery_latency" ]; then
                                                let host_up_count++
@@ -171,7 +171,7 @@ main() {
                                                echo "$loss" > /var/run/mwan3track/$1/LOSS_${track_ip}
 
                                                if [ $score -le $up ]; then
-                                                       $LOG info "Success: Latency=$latency ms Loss=$loss% for target \"$track_ip\" on interface $1 ($2)"
+                                                       $LOG info "Check (${track_method}: latency=${latency}ms loss=${loss}%) success for target \"$track_ip\" on interface $1 ($2)"
                                                fi
                                        else
                                                echo "skipped" > /var/run/mwan3track/$1/TRACK_${track_ip}