You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
echo>&2"apache: empty values got from apache server: ${apache_response[*]}"
139
+
error "empty values got from apache server: ${apache_response[*]}"
134
140
return 1
135
141
fi
136
142
@@ -151,7 +157,7 @@ apache_check() {
151
157
apache_get
152
158
if [ $?-ne 0 ]
153
159
then
154
-
echo>&2"apache: cannot find stub_status on URL '${apache_url}'. Please set apache_url='http://apache.server:80/server-status?auto' in $confd/apache.conf"
160
+
error "cannot find stub_status on URL '${apache_url}'. Please set apache_url='http://apache.server:80/server-status?auto' in $confd/apache.conf"
Copy file name to clipboardExpand all lines: charts.d/example.chart.sh
+7-2Lines changed: 7 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,11 @@
1
1
# no need for shebang - this file is loaded from charts.d.plugin
2
2
3
+
# netdata
4
+
# real-time performance and health monitoring, done right!
5
+
# (C) 2016 Costa Tsaousis <costa@tsaousis.gr>
6
+
# GPL v3+
7
+
#
8
+
3
9
# if this chart is called X.chart.sh, then all functions and global variables
4
10
# must start with X_
5
11
@@ -67,7 +73,7 @@ example_check() {
67
73
# - 1 to disable the chart
68
74
69
75
# check something
70
-
[ "${example_magic_number}"!="12345" ] &&echo>&2"example: you have to set example_magic_number=$example_magic_number in example.conf to start example chart."&&return 1
76
+
[ "${example_magic_number}"!="12345" ] &&error "manual configuration required: you have to set example_magic_number=$example_magic_number in example.conf to start example chart."&&return 1
71
77
72
78
# check that we can collect data
73
79
example_get ||return 1
@@ -108,7 +114,6 @@ BEGIN example.random2 $1
108
114
SET random = $example_value4
109
115
END
110
116
VALUESEOF
111
-
# echo >&2 "example_count = $example_count value = $value4"
0 commit comments