]> arthur.barton.de Git - netdata.git/blobdiff - charts.d/mysql.chart.sh
Merge pull request #2021 from ktsaou/master
[netdata.git] / charts.d / mysql.chart.sh
old mode 100755 (executable)
new mode 100644 (file)
index 2bb80a8..1363d01
@@ -1,5 +1,11 @@
 # no need for shebang - this file is loaded from charts.d.plugin
 
+# netdata
+# real-time performance and health monitoring, done right!
+# (C) 2016 Costa Tsaousis <costa@tsaousis.gr>
+# GPL v3+
+#
+
 # http://dev.mysql.com/doc/refman/5.0/en/server-status-variables.html
 #
 # https://dev.mysql.com/doc/refman/5.1/en/show-status.html
@@ -49,7 +55,7 @@ mysql_check() {
                shift
        fi
 
-       [ -z "${mysql_cmd}" ] && mysql_cmd="$(which mysql)"
+       [ -z "${mysql_cmd}" ] && mysql_cmd="$(which mysql 2>/dev/null || command -v mysql 2>/dev/null)"
 
        if [ ${#mysql_opts[@]} -eq 0 ]
                then