View example github
- Trapping is not agent, but port is 10051 and no interface is needed
- Agent passive, 10050 and interface needed, template name, can use userparamter also
- Agent active, 10050 and 10051 and interface needed, template name active, can use userparamter also
This blog post:
Zabbix Agent: Active vs. Passive – Zabbix Blog
Introduction
Active vs. Passive
Topology benefits
Now, imagine that you intend to set up automatic issue resolution on your hosts in addition to monitoring. The simplest example with Windows services would be configuring the items and triggers to check the health of specific services. But before notifying users about a Windows service that has stopped, you want to try to restart it automatically.
This is possible with remote commands. You can learn more about setting up remote commands by watching the video Zabbix Email Notifications And Actions. In the front end, open Configuration > Actions > Steps > Remote Command. Then enter the following CMD command:
Each time the trigger fires, the Zabbix agent will try to start the service. If it fails to do so, then a notification will be sent. But this remote command will only work with the Zabbix agent in the passive mode.
If you use the Zabbix agent in the passive mode, it means that the poller (internal server process) connects to the agent on port 10050/TCP and polls for a certain value
In the active mode, all data processing is performed on the agent, without the interference of pollers. However, the agent must know what metrics should be monitored, and that is why the agent connects to the trapper port 10051/TCP of the server once every two minutes (by default).