tags:

views:

156

answers:

2

I want to make sure all of the mysql servers have a certain configuration (max_connections>1000, innodb_file_per_table=on) and do regular checks via nagios.

However the nagios plugin check_mysql_query states

Only first column in first row will be read" ... "The result from the query should be numeric

Has anybody an idea how to setup the check_mysql_query plugin to read the output of

show variables like '%max_user_connections%;

...to produce:

+----------------------+-------+
| Variable_name        | Value |
+----------------------+-------+
| max_connections      | 1000  |
+----------------------+-------+
+1  A: 

answering my own question -

mysql> SELECT @@max_connections;
+-------------------+
| @@max_connections |
+-------------------+
|               886 |
+-------------------+
1 row in set (0.03 sec)

does the trick

A: 

Awesome answer to your'e own question, it will help me too!

nenne