报错提示:
failed to accept an incoming connection: connection from “172.16.238.2” rejected, allowed hosts: “127.0.0.1,192.168.2.20,0.0.0.0”
解决方法:
/etc/zabbix/zabbix_agentd.conf
Server=127.0.0.1,192.168.2.20,0.0.0.0,172.16.238.2 # 这个配置文件将本机IP和docker容器IP都加入进来
ListenPort=10050 # 和zabbix控制台配置一一致
ServerActive=127.0.0.1,192.168.2.20,0.0.0.0,172.16.238.2 # 这个配置文件将本机IP和docker容器IP都加入进来
Hostname=Zabbix host # 和zabbix控制台配置一一致
zabbix控制台配置
agent IP:192.168.2.20
端口:10050
主机名称:Zabbix host