zabbix新增主機時最常見的報錯

2022-09-23 02:24:14 字數 1756 閱讀 7243

今天在玩zabbix監控的時候,在被監控端裝好agent後,新增主機時介面上提示報錯zabbix agent on jiabao is unreachable for 5 minutes檢視日誌卻發現

[root@localhost tmp]# tail -f zabbix_server.log

26115:20190307:235549.064 cannot send list of active checks to "192.168.1.150": host [localhost] not found

26120:20190307:235715.010 executing housekeeper

26120:20190307:235715.015 housekeeper [deleted 0 hist/trends, 0 items, 0 events, 0 problems, 0 sessions, 0 alarms, 0 audit items in 0.003076 sec, idle for 1 hour(s)]

26115:20190307:235749.195 cannot send list of active checks to "192.168.1.150": host [localhost] not found

26115:20190307:235949.324 cannot send list of active checks to "192.168.1.150": host [localhost] not found

26115:20190308:000149.455 cannot send list of active checks to "192.168.1.150": host [localhost] not found

26115:20190308:000349.587 cannot send list of active checks to "192.168.1.150": host [localhost] not found

26115:20190308:000549.719 cannot send list of active checks to "192.168.1.150": host [localhost] not found

26115:20190308:000749.846 cannot send list of active checks to "192.168.1.150": host [localhost] not found

26115:20190308:000941.617 cannot send list of active checks to "192.168.1.150": host [localhost] not found

26117:20190308:001141.741 cannot send list of active checks to "192.168.1.150": host [localhost] not found

26117:20190308:001341.873 cannot send list of active checks to "192.168.1.150": host [localhost] not found

26117:20190308:001542.001 cannot send list of active checks to "192.168.1.150": host [localhost] not found

於是我就檢視agent端的配置檔案發現hostname欄位

和web介面上

不一致,因此出現了主機名識別不了導致無法連線,必須保證二者必須一致才可以更改之後檢視server端的日誌

zabbix 新增主機 API

zabbix 官網api 4.0,請選擇你自己的zabbix 版本 通過對zabbix 伺服器傳送 http 請求,可以完成配置,尤其是大量和需要自動化的時候 建立大量主機還有一種方式就是通過xml檔案,需要事先將檔案匯出 export 修改後將檔案匯入 import 本文主題通過api 為 zab...

zabbix新增主機流程

1新增host 以及新增host group 2鏈結到組的item模板 3看需求disable 不需要的item項 4檢視latest date 5 trigger看需求,關掉不需要的 6新增user以及郵件 給supper admin許可權,否則無法收到郵件 7配置action,盡量clone a...

zabbix新增監控主機

zabbix新增監控主機 安裝rpm uvh yum clean all install zabbix agent 安裝zabbix監控元件 yum install zabbix agent配置zabbix agentvim etc zabbix zabbix agentd.conf hostnam...