zabbix icmpping 问题

icmpping 依赖 linux 第三方包 fping,centos 在 安装 epel 源的情况下再安装fping

然后配置 zabbix server 或者 zabbix agent 的配置文件;

  • icmpping 是借助 linux fping 命令来实现的;

    在 agent 有 proxy 时,检查 proxy 上的 fping 是否配置,在 agent 无 proxy 时,检查 zabbix server 上的 fping 是否配置

    agent 有 proxy 时,是 proxy 执行fping;aget 没有 proxy 时,是 zabbix server 执行 fping

    配置示例:

    grep fping /etc/zabbix/zabbix_proxy.conf
    FpingLocation=/usr/sbin/fping		# 配置了 fping
    
    ll /usr/sbin/fping
    -rwsr-xr-x 1 root root 37136 May 12  2021 /usr/sbin/fping		# 可以看到 fping 具有 suid权限;
    
    # 通过 zabbix_get 命令来查看 fping 是否成功
    zabbix_get -s 10.21.143.82 -p 10050 -k icmpping
    
    
    # 如果执行 zabbix_get 命令返回如下错误:
    zabbix_get [21724]: Check access restrictions in Zabbix agent configuration
    # 请修改zabbix agent 配置文件的Server,将proxy ip地址添加进去 , 隔开
    Server=hawkeyes-p-awsen.nq.com,10.0.0.4,10.21.144.230