Nagios监控windows,安装配置NSClien++后,重启报错 配置报错 -问答-阿里云开发者社区-阿里云

开发者社区> 问答> 正文

Nagios监控windows,安装配置NSClien++后,重启报错 配置报错 

kun坤 2020-06-04 13:15:51 52

求大神指引。。。

linux还是菜鸟,于是现在玩监控玩出问题了。

大概情况是这样。ubuntu配置好了Nagios,并且可以监控自己。

现在想监控下windows的机子,于是在windows的机子上安装了NSClien++插件,并且配置好了,服务开启,监听正常。

再回到ubuntu的机子上,于是悲剧了。

代码:
/var/log/nagios3# service nagios3 restart  * Restarting nagios3 monitoring daemon nagios3 Nagios Core 3.2.3 Copyright (c) 2009-2010 Nagios Core Development Team and Community Contributors Copyright (c) 1999-2009 Ethan Galstad Last Modified: 10-03-2010 License: GPL Website: http://www.nagios.org Reading configuration data...    Read main config file okay... Processing object config file '/etc/nagios3/commands.cfg'... Processing object config directory '/etc/nagios-plugins/config'... Processing object config file '/etc/nagios-plugins/config/users.cfg'... Processing object config file '/etc/nagios-plugins/config/mailq.cfg'... Processing object config file '/etc/nagios-plugins/config/procs.cfg'... Processing object config file '/etc/nagios-plugins/config/disk-smb.cfg'... Processing object config file '/etc/nagios-plugins/config/load.cfg'... Processing object config file '/etc/nagios-plugins/config/dummy.cfg'... Processing object config file '/etc/nagios-plugins/config/radius.cfg'... Processing object config file '/etc/nagios-plugins/config/telnet.cfg'... Processing object config file '/etc/nagios-plugins/config/nt.cfg'... Warning: Duplicate definition found for command 'check_nt' (config file '/etc/nagios-plugins/config/nt.cfg', starting on line 6) Error: Could not add object property in file '/etc/nagios-plugins/config/nt.cfg' on line 7.    Error processing object config files! ***> One or more problems was encountered while processing the config files...      Check your configuration file(s) to ensure that they contain valid      directives and data defintions.  If you are upgrading from a previous      version of Nagios, you should be aware that some variables/definitions      may have been removed or modified in this version.  Make sure to read      the HTML documentation regarding the config files, as well as the      'Whats New' section to find out what has changed.  * errors in config!                                                                          [fail] 根据上面报错,我找到这个文件'/etc/nagios-plugins/config/nt.cfg' 这个文件很是纠结啊,我找网上的照抄无数个版本都不对。 此文件我是这样定义的。
代码:
# 'check_nt' command definition define command {         command_name    check_nt         command_line    /usr/lib/nagios/plugins/check_nt -H '$HOSTADDRESS$' -p 12489 -v '$ARG1$' '$ARG2$' } # 'check_nscp' command definition define command {         command_name    check_nscp         command_line    /usr/lib/nagios/plugins/check_nt -H '$HOSTADDRESS$' -p 12489 -v '$ARG1$' } 实在不清楚哪里错了,这个文件都被我改烂了。 求大神指教!
监控 Windows
分享到
取消 提交回答
全部回答(1)
  • kun坤
    2020-06-05 13:17:42

    我也没搞过,不过看了你的报错,应该是nt.config重复定义了,你以前是不是装过nagios,去看看文档"what new"那块,希望对你有帮助~~

    0 0
开发与运维
使用钉钉扫一扫加入圈子
+ 订阅

集结各类场景实战经验,助你开发运维畅行无忧

推荐文章
相似问题
推荐课程