瀏覽代碼

Merge pull request #238 from apollotonkosmo/mysql-uptime-perfdata

Move uptime to the metric_count[]
John C. Frickson 9 年之前
父節點
當前提交
28a1998ffd
共有 1 個文件被更改,包括 4 次插入4 次删除
  1. 4 4
      plugins/check_mysql.c

+ 4 - 4
plugins/check_mysql.c

@@ -66,17 +66,18 @@ int verbose = 0;
 static double warning_time = 0;
 static double warning_time = 0;
 static double critical_time = 0;
 static double critical_time = 0;
 
 
-#define LENGTH_METRIC_UNIT 6
+#define LENGTH_METRIC_UNIT 7
 static const char *metric_unit[LENGTH_METRIC_UNIT] = {
 static const char *metric_unit[LENGTH_METRIC_UNIT] = {
-	"Open_files",
+	"x",
 	"Open_tables",
 	"Open_tables",
 	"Qcache_free_memory",
 	"Qcache_free_memory",
 	"Qcache_queries_in_cache",
 	"Qcache_queries_in_cache",
 	"Threads_connected",
 	"Threads_connected",
 	"Threads_running"
 	"Threads_running"
+	"Uptime"
 };
 };
 
 
-#define LENGTH_METRIC_COUNTER 9
+#define LENGTH_METRIC_COUNTER 8
 static const char *metric_counter[LENGTH_METRIC_COUNTER] = {
 static const char *metric_counter[LENGTH_METRIC_COUNTER] = {
 	"Connections",
 	"Connections",
 	"Qcache_hits",
 	"Qcache_hits",
@@ -86,7 +87,6 @@ static const char *metric_counter[LENGTH_METRIC_COUNTER] = {
 	"Queries",
 	"Queries",
 	"Questions",
 	"Questions",
 	"Table_locks_waited",
 	"Table_locks_waited",
-	"Uptime"
 };
 };
 
 
 thresholds *my_threshold = NULL;
 thresholds *my_threshold = NULL;