haoman 发表于 2019-1-16 10:48:48

nagios安装后,没有check_mysql怎么办?


[*]nagios监控mysql服务器:
[*]方法:定期去select下某个空闲的数据库
[*]使用插件:check_mysql
[*]
[*]问题:安装完成nagios后,发现居然没有这个插件,怎么办?
[*]解决方法:
[*]# yum install mysql-devel         
[*]重装下nagios-plugins插件包
[*]# ./configure
[*]            --with-apt-get-command:
[*]            --with-ping6-command: /bin/ping6 -n -U -w %d -c %d %s
[*]               --with-ping-command: /bin/ping -n -U -w %d -c %d %s
[*]                     --with-ipv6: yes
[*]                      --with-mysql: /usr/bin/mysql_config
[*]                  --with-openssl: yes
[*]                     --with-gnutls: no
[*]               --enable-extra-opts: no
[*]                     --with-perl: /usr/bin/perl
[*]             --enable-perl-modules: no
[*]                     --with-cgiurl: /nagios/cgi-bin
[*]               --with-trusted-path: /bin:/sbin:/usr/bin:/usr/sbin
[*]                   --enable-libtap: no
[*]# make && make install
[*]
[*]结果:这个插件有了!
[*]# ll /usr/local/nagios/libexec/check_mysql*
[*]-rwxr-xr-x 1 root root 124343 Aug 31 13:13 /usr/local/nagios/libexec/check_mysql
[*]-rwxr-xr-x 1 root root 120909 Aug 31 13:13 /usr/local/nagios/libexec/check_mysql_query




页: [1]
查看完整版本: nagios安装后,没有check_mysql怎么办?