Page 1 of 1

check_mysql_health fails when password has exclamation mark

Posted: Wed Jul 04, 2018 1:38 am
by utsadmin
Hi

If I run the following command from the commandline on nagios server, it returns OK:

./check_mysql_health --hostname blabhlah.com --username blahuser --password 'blahblah!' --mode slow-queries
OK - 0 slow queries in 20518 seconds (0.00/sec) | slow_queries_rate=0.00%;0.1;1

However, the gui shows a warning and this error:

/bin/sh: -c: line 0: unexpected EOF while looking for matching `''

I have worked around this problem by changing the password to one which does not include an exclamation mark.

Re: check_mysql_health fails when password has exclamation m

Posted: Thu Jul 05, 2018 9:25 am
by cdienger
! is a special character for Nagios. https://support.nagios.com/kb/article/n ... s-580.html covers how you can still use special characters in configs.