Check nagios配置文件报错例如以下:

[nagios@2 etc]$ /usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg

Nagios Core 4.0.6
Copyright (c) 2009-present Nagios Core Development Team and Community Contributors
Copyright (c) 1999-2009 Ethan Galstad
Last Modified: 04-29-2014
License: GPL

Website: http://www.nagios.org
Reading configuration data...
   Read main config file okay...
Error: Template 'timman' specified in contact definition could not be not found (config file '/usr/local/nagios/etc/objects/contacts.cfg', starting on line 65)
   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.

2 查看报错内容

[nagios@2 etc]$ more /usr/local/nagios/etc/objects/contacts.cfg

......

define contact{
        contact_name                    timman          
        use                             timman       这里报错,说无效的。
        alias                           tim man         
        service_notification_period     24x7
        host_notification_period        24x7
        service_notification_options    w,u,c,r
        host_notification_options       d,u,r
        service_notification_commands   notify-host-by-email
        host_notification_commands      notify-host-by-email
        email                           mchdba@sohu.com
        pager                           14782121512
        }

define contactgroup{
        contactgroup_name       ops
        alias                   pl ops team
        members                 timman,nagiosadmin
        }

3 将timman换成generic-contact

vi /usr/local/nagios/etc/objects/contacts.cfg

use                             timman

替换成

use                             generic-contact

4 又一次检測,Check下

[nagios@2 etc]$ /usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg

Nagios Core 4.0.6
Copyright (c) 2009-present Nagios Core Development Team and Community Contributors
Copyright (c) 1999-2009 Ethan Galstad
Last Modified: 04-29-2014
License: GPL

Website: http://www.nagios.org
Reading configuration data...
   Read main config file okay...
   Read object config files okay...

Running pre-flight check on configuration data...

Checking objects...
Checked 8 services.
Checked 1 hosts.
Checked 1 host groups.
Checked 0 service groups.
Checked 2 contacts.
Checked 2 contact groups.
Checked 24 commands.
Checked 5 time periods.
Checked 0 host escalations.
Checked 0 service escalations.
Checking for circular paths...
Checked 1 hosts
Checked 0 service dependencies
Checked 0 host dependencies
Checked 5 timeperiods
Checking global event handlers...
Checking obsessive compulsive processor commands...
Checking misc settings...

Total Warnings: 0
Total Errors:   0

Things look okay - No serious problems were detected during the pre-flight check
[nagios@cache-2 etc]$

[Nagios] Error: Template 'timman' specified in contact definition could not be not found (c的更多相关文章

  1. ..\OBJ\CAN.axf: Error: L6411E: No compatible library exists with a definition of startup symbol __main.

    ..\OBJ\CAN.axf: Error: L6411E: No compatible library exists with a definition of startup symbol __ma ...

  2. Error creating bean with name 'menuController': Injection of autowired dependency……

    出现了一大串错误 Error creating bean with name 'userController': Injection of autowired dependencies failed. ...

  3. Error creating bean with name 'memcachedClient'...java.lang.OutOfMemoryError

    1,Tomcat启动报错例如以下: Caused by: org.springframework.beans.factory.BeanCreationException: Error creating ...

  4. Error occured processing XML 'Cannot find class [springmvc.extention.BeanArgumentResolver]'.

    <Description Resource Path Location Type Error occured processing XML 'Cannot find class [springm ...

  5. 解决ERROR 2002 (HY000): Can&#39;t connect to local MySQL server through socket &#39;/tmp/mysql.sock&#39; (2)

    在Mac和XAMPP环境,假设终端打字mysql,现这样的问题: ERROR 2002 (HY000): Can't connect to local MySQL server through soc ...

  6. iOS开展-clang: error: unknown argument: &#39;-websockets&#39;解决方案

    问题: 昨天莫名其妙Xcode自己主动升级,那么今天之前执行project什么时候,不知怎的,他们都获得了. 错误内容: clang: error: unknown argument: '-webso ...

  7. [生产环境数据恢复]innobackupex: fatal error: OR no &#39;datadir&#39; option in group &#39;mysqld&#39; in MySQL options

    1 运行恢复命令  [xxx@xxx-c001db1 tmp]$ time /usr/bin/innobackupex --rsync --user="user" --passwo ...

  8. 追索权 Eclipse + NDK error: stray &#39;\24&#39; in program

    [size=16px][b][color=#FF0000]追索权 Eclipse + NDK  error: stray '\24' in program[/color][b][/b][/b][/si ...

  9. error C2871: &#39;std&#39; : does not exist or is not a namespace

    #include <iostream.h> using namespace std; 然后编译时出现 error C2871: 'std' : does not exist or is n ...

随机推荐

  1. 解决input为number类型时maxlength无效的问题

    使用input数字number类型的时候maxlength无效,假设需要控制输入数量为18,可以用以下方式: 无效: <input type="text"  maxlengt ...

  2. 移动端地区选择mobile-select-area插件的使用方法

    顾名思义,mobile-select-area插件就是使用在移动端上的进行地区选择的插件,而且使用方法简单,我就说我是怎么用的吧 一.准备工作 首先肯定要下载插件对应的css+js文件, 当你下载好这 ...

  3. Strut2开发经验总结

    1.如何在html静态页面中使用struts tomcat目录/conf/web.xml 文件中,找到 <servlet-mapping> <servlet-name>jsp& ...

  4. CIO在数字化转型中如何正确定位?

    在数字化转型的大潮下,CIO和传统企业应如何抓住数字生态系统中的机遇?CIO该如何面对领导力.资金.技术和人才的挑战? Gartner研究总监陈勇表示:IT部门在企业中应转变成为一个引领创新的部门,C ...

  5. java变量常量

    1. java 变量遵循先声明,再赋值,后使用的原则. 一个变量可以只声明,不赋值,没有问题(只是这个变量没有实际意义,但完全没有问题).但如果想要使用它,那么就一定要给它赋值,而大多数时候我们又不知 ...

  6. JVM知识(三):内存模型和可见性

    这篇文章我们将根据JVM的内存模型探索java当中变量的可见性以及不同的java指令在并发时可能发生的指令重排序的情况.来聊聊java线程对一个变量的更新怎么通知另一个线程,及volatile的作用和 ...

  7. Oracle EBS 获取用户挂的职责 请求 请求的类别(RTF还是什么的)

    select fu.user_ID, fu.user_name, fu.start_date, fu.END_DATE, fu.description, fe.last_name, fr.RESPON ...

  8. SQL server数据库压缩空间

    SQL server数据库,在手动删除或者自动删除数据后,查看数据库物理文件发现占用空间并没有释放,果断采用万能的重启.(反正是自己用的一个服务器,随便玩.如果不是只有自己用的服务器,还是建议让运维或 ...

  9. 使用AHKActionSheet

    使用AHKActionSheet https://github.com/fastred/AHKActionSheet 基本配置代码: AHKActionSheet *actionSheet = [[A ...

  10. Celery学习---Celery 分布式队列介绍及安装

    Celery介绍和基本使用 Celery 是一个 基于python开发的分布式异步消息任务队列,通过它可以轻松的实现任务的异步处理, 如果你的业务场景中需要用到异步任务,就可以考虑使用celery, ...