use our fork of fping until it is stabilized
Costa Tsaousis (ktsaou) committed
Nov 2, 2016 at 00:56 UTC
1d2a80326b1bdf2c33d85c8c5cccc4f9f1875c10
4 files changed
+21
-12
conf.d/fping.conf
+2
-2
@@ -37,8 +37,8 @@ hosts=""
37
# other fping options - defaults:
38
# -R = send packets with random data
39
# -b 56 = the number of bytes per packet
40
-# -i 1 = 1ms when sending packets to others hosts (switching hosts)
40
+# -i 1 = 1 ms when sending packets to others hosts (switching hosts)
41
# -r 0 = never retry packets
42
-# -t 5000 = per packet timeout at 5000ms
42
+# -t 5000 = per packet timeout at 5000 ms
43
44
#fping_opts="-R -b 56 -i 1 -r 0 -t 5000"
plugins.d/fping.plugin
+17
-8
@@ -27,13 +27,13 @@ if [ "${1}" = "install" ]
27
28
run cd /usr/src
29
30
- if [ -d fping.git ]
30
+ if [ -d fping-ktsaou.git ]
31
then
32
- run cd fping.git
32
+ run cd fping-ktsaou.git
33
run git pull
34
else
35
- run git clone https://github.com/schweikert/fping.git fping.git
36
- run cd fping.git
35
+ run git clone https://github.com/ktsaou/fping.git fping-ktsaou.git
36
+ run cd fping-ktsaou.git
37
fi
38
39
run ./autogen.sh
@@ -50,9 +50,18 @@ if [ "${1}" = "install" ]
50
echo >&2
51
echo >&2 "All done, you have a compatible fping now at /usr/local/bin/fping."
52
echo >&2
53
- echo >&2 "If you have another fping installed, please set:"
54
- echo >&2 " fping=\"/usr/local/bin/fping\""
55
- echo >&2 "at /etc/netdata/fping.conf"
53
+
54
+ fping="$(which fping 2>/dev/null || command -v fping 2>/dev/null)"
55
+ if [ "${fping}" != "/usr/local/bin/fping" ]
56
+ then
57
+ echo >&2 "You have another fping installed at: ${fping}."
58
+ echo >&2 "Please set:"
59
+ echo >&2
60
+ echo >&2 " fping=\"/usr/local/bin/fping\""
61
+ echo >&2
62
+ echo >&2 "at /etc/netdata/fping.conf"
63
+ echo >&2
64
+ fi
65
exit 0
66
fi
67
@@ -152,7 +161,7 @@ if [ ${ping_every} -lt 20 ]
161
fi
162
163
# the fping options we will use
155
-options=( -N -l -Q ${update_every} -p ${ping_every} ${other_opts} ${hosts} )
164
+options=( -N -l -Q ${update_every} -p ${ping_every} ${fping_opts} ${hosts} )
165
166
# execute fping
167
exec "${fping}" "${options[@]}"
web/dashboard_info.js
+1
-1
@@ -746,7 +746,7 @@ netdataDashboard.context = {
746
// fping
747
748
'fping.quality': {
749
- colors: NETDATA.colors[5],
749
+ colors: NETDATA.colors[10],
750
height: 0.5
751
},
752
web/index.html
+1
-1
@@ -2555,7 +2555,7 @@
2555
});
2556
2557
NETDATA.requiredJs.push({
2558
- url: NETDATA.serverDefault + 'dashboard_info.js?v20161101-1',
2558
+ url: NETDATA.serverDefault + 'dashboard_info.js?v20161101-6',
2559
async: false,
2560
isAlreadyLoaded: function() { return false; }
2561
});