check_mysql

Israel Brewster israel at frontierflying.com
Wed Oct 15 21:10:35 CEST 2008


On Oct 15, 2008, at 11:00 AM, jeremiah wrote:

> I want nagios to automatically check mysql services on my servers.
> However when i view the web interface i see that staus is UNKNOWN  
> and it
> displays the usage for check_mysql. In what file am i supposed to put
> the arguments for this command?

The arguments go in your service definition on the check_command line,  
separated from each other and the command name by "!". So in your  
case, you would have a check_command line something like:

check_command		check_mysql!<arg1>!<arg2>!<arg3>

where <arg1> <arg2> and <arg3> are respectively whatever you need for  
the -P, -u and -p switches to check_mysql.

-----------------------------------------------
Israel Brewster
Computer Support Technician
Frontier Flying Service Inc.
5245 Airport Industrial Rd
Fairbanks, AK 99709
(907) 450-7250 x293
-----------------------------------------------

>
>
> Here is what i have so far in commands.cfg
>
> define command{
>        command_name    check_mysql
>        command_line    $USER1$/check_mysql -H $HOSTADDRESS$ -P $ARG1$
> -u $ARG2$ -p $ARG3$
> }
>
> and my services.cf file...
>
> define service{
>        use                             generic-service         ; Name
> of service template
>        hostgroup_name                  mysql_servers
>        service_description             MYSQL
>        is_volatile                     0
>        check_period                    24x7
>        max_check_attempts              3
>        normal_check_interval           3
>        retry_check_interval            1
>        contact_groups                  admins
>        notification_interval           30
>        notification_period             24x7
>        notification_options            w,u,c,r
>        check_command                   check_mysql
>        }
>
>
> Thanks!
>
>
>
> Disclaimer: The information contained in this transmission,  
> including any
> attachments, may contain confidential information of Panasonic  
> Avionics
> Corporation.  This transmission is intended only for the use of the
> addressee(s) listed above.  Unauthorized review, dissemination or  
> other use
> of the information contained in this transmission is strictly  
> prohibited.
> If you have received this transmission in error or have reason to  
> believe
> you are not authorized to receive it, please notify the sender by  
> return
> email and promptly delete the transmission.
>
>
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's  
> challenge
> Build the coolest Linux based applications with Moblin SDK & win  
> great prizes
> Grand prize is a trip for two to an Open Source event anywhere in  
> the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> Nagios-users mailing list
> Nagios-users at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/nagios-users
> ::: Please include Nagios version, plugin version (-v) and OS when  
> reporting any issue.
> ::: Messages without supporting info will risk being sent to /dev/null


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list