<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 TRANSITIONAL//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=UTF-8">
<META NAME="GENERATOR" CONTENT="GtkHTML/3.18.3">
</HEAD>
<BODY>
I'm having issues getting the check_mysql to work in nagios. I had a pre-existing host setup by someone long gone, and am trying to add 2 other new mysql servers to a basic check. I did my best to make the user appear to be setup exactly as I saw the original one was. check_mysql -H hostname -u nagios -p passwd works from the commandline, but then fails from the nagios check. Oddly the original host gives me a access denied from the commandline, but then works from the check nagios sends.<BR>
<BR>
Here is the lines from .cfg's pretty basic.<BR>
<BR>
commands.cfg<BR>
# 'check_mysql' command definition<BR>
define command{<BR>
command_name check_mysql<BR>
command_line $USER1$/check_mysql -H $HOSTADDRESS$ -u $ARG1$ -p $ARG2$<BR>
}<BR>
<BR>
services.cfg<BR>
# Service definition<BR>
define service{<BR>
use generic-service ; Name of service template to use<BR>
host_name originalserver,newserver<BR>
service_description MYSQL<BR>
check_command check_mysql!nagios!NORTREALPASSWD<BR>
}<BR>
<BR>
<BR>
Newserver on commandline recieves the usual Uptime, threads, etc.. readout, but in nagios returns this error<BR>
<BR>
Access denied for user 'nagios'@'qeren.zacks.com' (using password: YES)<BR>
<BR>
And oddly it's the opposite for the original server which works in nagios, but returns same error on commandline.<BR>
<BR>
Here is what the current permissions are set to which is the same as on the original server as far as I can tell.<BR>
User:nagios Host:server.domain.com Password:Yes GlobalPrivileges:<TT>U</TT>SAGE<TT> Grant:No</TT><BR>
<BR>
<BR>
<BR>
</BODY>
</HTML>