In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-10-15 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Network Security >
Share
Shulou(Shulou.com)06/01 Report--
Zabbix agent automatic Registration function to realize batch Monitoring of hosts
Zabbix auto registration is very powerful. When you add a new agent, you only need to add a trigger to the server and modify several parameters in the agent to automatically add to the monitoring. This feature plays an important role in batch monitoring. If you need to add a monitoring item later, you only need to add item to the template.
1. Clone a new template and create a new host group
Template clone
[configuration] à [template] à hand-selected template à [full clone]
If you have already made a template, you can call it directly; if you have not done a good job and want to change it later, it is best to use a new template.
New host group
[configuration] à [host group] à [create host group]
A new host group is created to distinguish between different business hosts for batch management.
2. Create an auto-registered trigger
In the [configuration] à [Action] à [Auto Registration] à [create Action] column
My auto registration rules are as follows:
3. Modify agentd.conf parameters
Modify Hostname, ServerActive, Server, Timeout parameters in agentd.conf
Hostname reported by Hostname:agent to server
ServerActive: to whom?
Server: who is allowed to connect
Timeout: timeout when executing script. If timeout occurs, an error will be reported on the server side.
Sed-i's/ ^ server. * / Server=127.0.0.1,zabbixserver/g' zabbix_agentd.conf# allows the source IPsed-I "s / ^ hostname =. * / Hostname= `hostname` / g" zabbix_agentd.conf# to write the current hostname into the agentd.conf. Remember that the hostname must meet the matching condition of sed-i's/ ^ ServerActive. * / ServerActive=zabbixserver/g'zabbix_agentd.conf# allows active monitoring, that is, agent is enabled to report to the server. Sed-I / ^ Timeout/dzabbix_agentd.confecho "Timeout=30" > > zabbix_agentd.conf# sets the timeout because some scripts are executed for a long time. By default, it is easy to time out echo "1.1.1.1zabbixserver" > > / etc/hosts# to modify the hosts resolution of server IP 4 and restart the zabbix_agentd service.
At this point, you can see that the agent host and all template services have been monitored on server.
My auto-registration agent is 2, 3, 4, 5, and the automatic registration hosts are all displayed with host names, so when designing hostname, it must be easy to distinguish.
To facilitate more automation, I envision deploying slatstack, automatically installing zabbix on the monitored server, synchronizing files and monitoring scripts, and so on.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
The market share of Chrome browser on the desktop has exceeded 70%, and users are complaining about
The world's first 2nm mobile chip: Samsung Exynos 2600 is ready for mass production.According to a r
A US federal judge has ruled that Google can keep its Chrome browser, but it will be prohibited from
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
About us Contact us Product review car news thenatureplanet
More Form oMedia: AutoTimes. Bestcoffee. SL News. Jarebook. Coffee Hunters. Sundaily. Modezone. NNB. Coffee. Game News. FrontStreet. GGAMEN
© 2024 shulou.com SLNews company. All rights reserved.