luci-app-statistics: scale up ping_droprate to range 0-100
authorYousong Zhou <yszhou4tech@gmail.com>
Fri, 9 Aug 2019 10:05:02 +0000 (10:05 +0000)
committerYousong Zhou <yszhou4tech@gmail.com>
Sat, 10 Aug 2019 01:53:14 +0000 (09:53 +0800)
In original collectd, values of this metric are in range 0-1.  OpenWrt
previously have a custom patch scaling them up to range 0-100.  That
patch has been removed to align with possibly other deployments.

Ref: https://github.com/openwrt/packages/pull/9677
Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/ping.lua

index c3645e408cde2a7b9834befbeb7f6dba3fa75267..e290af549a74c31711da3ac29b7ed2920635bcdb 100644 (file)
@@ -27,7 +27,7 @@ function rrdargs( graph, plugin, plugin_instance, dtype )
                  data = {
                        types   = { "ping_droprate" },
                        options = { ping_droprate = {
-                               noarea = true, overlay = true, title = "%di" } }
+                               noarea = true, overlay = true, title = "%di", transform_rpn = "100,*" } }
                } }
        }
 end