博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
Zabbix网络自动发现规则和自动添加hosts及link模板
阅读量:5219 次
发布时间:2019-06-14

本文共 3021 字,大约阅读时间需要 10 分钟。

Version: zabbix 3.0

一、配置网络发现规则(Configuration Discovery)

Device uniqueness criteria:选择主机名作为唯一标识(Configuation Hosts中显示的NAME)

 

二、查看发现的主机(Monitoring->Discovery)

ps: 显示主机名(m-proxy1)需要在服务器端/etc/hosts定义

192.168.0.2  m-proxy1

 

三、自动添加Hosts(加入到对应组,links对应模板)(Configuration -> Actions Event -> Discovery)

 

 

现在可以看到添加的主机(Configuation->Hosts)

 

Q&S

步骤一后 并未发现hosts

Solve:

1 tcpdump -vnn host 172.16.0.116 and port 10050  #发现服务器并没有发送discovery包到客户端

2 日志开启 debugging (DebugLevel=5)

tail -f /tmp/zabbix_server.log | grep discover

9983:20160312:174909.385 __zbx_zbx_setproctitle() title:'discoverer #1 [processed 1 rules in 0.020067 sec, performing discovery]'  9983:20160312:174909.393 In discover_service()  9983:20160312:174909.394 discovery: item [system.uname] error: A TLS connection is configured to be used with agent but support for TLS was not compiled into server.  9983:20160312:174909.394 End of discover_service():FAIL  9983:20160312:174909.394 In discovery_update_service() ip:'172.16.0.115' dns:'' port:10050 status:1 value:''  9983:20160312:174909.395 In discovery_register_host() ip:'172.16.0.115' status:1 value:''  9983:20160312:174909.395 End of discovery_register_host()  9983:20160312:174909.395 End of discovery_update_service()  9983:20160312:174909.396 In discovery_update_host()  9983:20160312:174909.397 End of discovery_update_host()  9983:20160312:174909.397 In discovery_clean_services()  9983:20160312:174909.397 End of discovery_clean_services()  9983:20160312:174909.400 __zbx_zbx_setproctitle() title:'discoverer #1 [processed 1 rules in 0.014707 sec, idle 30 sec]'  9965:20160312:174923.275 query [txnlev:0] [select refresh_unsupported,discovery_groupid,snmptrap_logging,severity_name_0,severity_name_1,severity_name_2,severity_name_3,severity_name_4,severity_name_5,hk_events_mode,hk_events_trigger,hk_events_internal,hk_events_discovery,hk_events_autoreg,hk_services_mode,hk_services,hk_audit_mode,hk_audit,hk_sessions_mode,hk_sessions,hk_history_mode,hk_history_global,hk_history,hk_trends_mode,hk_trends_global,hk_trends,default_inventory_mode from config]  9967:20160312:174935.465 In substitute_key_macros() data:'zabbix[process,discoverer,avg,busy]'  9967:20160312:174935.465 End of substitute_key_macros():SUCCEED data:'zabbix[process,discoverer,avg,busy]'  9967:20160312:174935.465 In get_value() key:'zabbix[process,discoverer,avg,busy]'  9985:20160312:174935.671 In evaluate_function() function:'Zabbix server:zabbix[process,discoverer,avg,busy].avg(10m)'  9983:20160312:174939.404 __zbx_zbx_setproctitle() title:'discoverer #1 [processed 1 rules in 0.014707 sec, performing discovery]'  9983:20160312:174939.413 In discover_service()  9983:20160312:174939.413 discovery: item [system.uname] error: A TLS connection is configured to be used with agent but support for TLS was not compiled into server.  9983:20160312:174939.413 End of discover_service():FAIL

需要TLS支持(yum install -y openssl openssl-devel)  configure --with-openssl

(2.0网络发现没有这个要求)

 

转载于:https://www.cnblogs.com/metasequoia/p/5272116.html

你可能感兴趣的文章
jQuery总结第一天
查看>>
Java -- Swing 组件使用
查看>>
Software--Architecture--DesignPattern IoC, Factory Method, Source Locator
查看>>
poj1936---subsequence(判断子串)
查看>>
黑马程序员_Java基础枚举类型
查看>>
[ python ] 练习作业 - 2
查看>>
一位90后程序员的自述:如何从年薪3w到30w!
查看>>
在.net core上使用Entity FramWork(Db first)
查看>>
System.Net.WebException: 无法显示错误消息,原因是无法找到包含此错误消息的可选资源程序集...
查看>>
UIImage 和 iOS 图片压缩UIImage / UIImageVIew
查看>>
MongoDB的数据库、集合的基本操作
查看>>
ajax向后台传递数组
查看>>
疯狂JAVA16课之对象与内存控制
查看>>
[转载]树、森林和二叉树的转换
查看>>
WPF移动Window窗体(鼠标点击左键移动窗体自定义行为)
查看>>
软件测试-----Graph Coverage作业
查看>>
django ORM创建数据库方法
查看>>
创建Oracle synonym 详解
查看>>
php7 新特性整理
查看>>
RabbitMQ、Redis、Memcache、SQLAlchemy
查看>>