{"id":85875,"date":"2023-12-28T22:00:13","date_gmt":"2023-12-28T14:00:13","guid":{"rendered":"http:\/\/lrxjmw.cn\/?p=85875"},"modified":"2023-12-28T22:00:13","modified_gmt":"2023-12-28T14:00:13","slug":"zabbix-fping","status":"publish","type":"post","link":"https:\/\/lrxjmw.cn\/zabbix-fping.html","title":{"rendered":"Zabbix\u81ea\u52a8\u53d1\u73b0\u4e4bfping"},"content":{"rendered":"
\u5bfc\u8bfb<\/td>\n | Zabbix\u81ea\u52a8\u53d1\u73b0\u529f\u80fd\u4ece\u914d\u7f6e\u6d41\u7a0b\u4e0a\u6bd4\u8f83\u7b80\u5355\uff1aDiscovery\u4e0eAction\u3002\u5728\u505aZabbix\u7684\u81ea\u52a8\u53d1\u73b0\u9a8c\u8bc1\u65f6\uff0c\u4f7f\u7528\"ICMP ping\"\u7684check\u65b9\u5f0f\u65f6\uff0c\u81ea\u52a8\u53d1\u73b0\u529f\u80fd\u5e76\u4e0d\u751f\u6548\u3002<\/strong><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n \u4e00\uff0e\u73af\u5883 <\/strong><\/div>\n 1. zabbix\u73af\u5883<\/strong><\/span><\/div>\n
2. \u914d\u7f6e\u73af\u5883<\/strong><\/span><\/div>\n \u53d1\u73b0\u672c\u5730\u7f51\u7edc172.19.200.1-254\uff0cCheck\uff1aICMP ping\uff0c\u5982\u4e0b\uff1a ICMP ping\u65b9\u5f0f\u4e0b\uff0cUP\u72b6\u6001\u7684\u4e3b\u673a\u6dfb\u52a0\u5230\"Discovery hosts\"\u7ec4\uff0c\u5982\u4e0b\uff1a \u4e8c\uff0e\u81ea\u52a8\u53d1\u73b0\u5931\u6548<\/strong><\/div>\n 1. \u73b0\u8c61<\/strong><\/span><\/div>\n \u5728\u81ea\u52a8\u53d1\u73b0\u7684discovery\u4e0eaction\u6d41\u7a0b\u914d\u7f6e\u6b63\u786e\u7684\u524d\u63d0\u4e0b\uff0c\u7b49\u5f8510\u5206\u949f\u89c2\u5bdf\uff0c\u81ea\u52a8\u53d1\u73b0\u529f\u80fd\u5e76\u4e0d\u751f\u6548\u3002<\/p>\n 2. \u5b9a\u4f4d\u6545\u969c<\/strong><\/span><\/div>\n #\u53d1\u73b0\u6709\"\u627e\u4e0d\u5230\/usr\/sbin\/fping<\/span>\u6587\u4ef6\"\u7684\u4fe1\u606f\u8bb0\u5f55\u3002 1412:20160621:110040.593 \/usr\/sbin\/fping: [2] No such file or directory<\/p>\n \"ICMP ping\"<\/span>\u7684check\u65b9\u5f0f\uff0c\u4f7f\u7528\/usr\/sbin\/fping<\/span>\u547d\u4ee4\u68c0\u6d4b\u72b6\u6001\uff0c\u5982\u679c\u7cfb\u7edf\u6ca1\u6709\u5b89\u88c5\u6216fping\u547d\u4ee4\u6267\u884c\u8def\u5f84\u6709\u8bef\uff0c\u5219check\u65b9\u5f0f\u4e0d\u80fd\u53d1\u73b0\u8bbe\u5907\uff0c\u81ea\u52a8\u53d1\u73b0\u529f\u80fd\u5931\u6548\u3002<\/p>\n #fping\u76f8\u5bf9ping\uff0c\u53ef\u4ee5\u540c\u65f6ping\u591a\u4e2a\u76ee\u6807\u5e76\u4e14\u6709\u591a\u79cd\u7edf\u8ba1\u8f93\u51fa\u683c\u5f0f\uff0c#fping\u76ee\u524d\u53ea\u80fd\u901a\u8fc7\u7f16\u8bd1\u7684\u65b9\u5f0f\u5b89\u88c5\u3002 #zabbix_server\u914d\u7f6e\u6587\u4ef6\u4e2d\u9ed8\u8ba4fping\u7684\u6267\u884c\u8def\u5f84\u88ab\u6ce8\u91ca\u6389\u4e86\uff0c\u6b64\u65f6\u9ed8\u8ba4\u8def\u5f84\u5c31\u4e3a\uff1a\/usr\/sbin\/fping<\/span><\/p>\n #\u53ef\u4ee5\u914d\u7f6efping\u7684\u6267\u884c\u8def\u5f84\uff0c\u5982\u4e0b\uff1a #\u6216\u8005\u4e0d\u4fee\u6539 zabbix_server.conf<\/span>\u6587\u4ef6\uff0c\u4f7f\u7528\u8f6f\u8fde\u63a5ln -s \/usr\/local\/sbin\/fping \/usr\/sbin\/fping<\/span><\/p>\n #fping\u5fc5\u987b\u7531root\u7528\u6237\u6267\u884c\uff0c\u5982\u679c\u975eroot\u8d26\u53f7\u6267\u884cfping\uff0c\u67e5\u770bzabbix_server\u65e5\u5fd7\u4f1a\u6709\u5982\u4e0b\u62a5\u8b66\u4fe1\u606f\uff1a #\u5982\u679c\u662froot\u8d26\u53f7\u5b89\u88c5\u7684fping\uff0c\u53ef\u4ee5\u4e0d\u7528\u4fee\u6539owner<\/p>\n #\u4f46zabbix_server\u662f\u4f7f\u7528zabbix\u8d26\u53f7\u8c03\u7528\u547d\u4ee4\u7684\uff0c\u53ef\u4ee5\u4e3afping\u8bbe\u7f6eSUID\u6743\u9650\uff0c\u5982\u4e0b\uff1a Monitoring--> Discovery--> Discovery rule\uff0c\u9009\u62e9\"Local network\"(\u521b\u5efadiscovery\u65f6\u7684name)\uff0c\u5982\u4e0b\uff1a Configuration--> Hosts--> Group\uff0c\u9009\u62e9\"Discovery hosts\"\u7ec4\uff0c\u5982\u4e0b\uff1a \u539f\u6587\u6765\u81ea\uff1ahttp:\/\/www.linuxidc.com\/Linux\/2017-10\/147563.htm<\/a><\/p>\n |