Send alert state to Zabbix
SZ-MCP sends Zabbix the same per-rule results it sends Nagios, packed as one
JSON value on a single trapper item, szmcp.results. A template discovers one
service per element, so adding or removing an alert rule needs no change in
Zabbix. A nodata trigger tells you when SZ-MCP stops sending. Set it up under
Configure › Integrations (admins only). The
rules every integration follows
apply here too.
API or sender: which transport?
Section titled “API or sender: which transport?”| Transport | Use when | Needs |
|---|---|---|
| API (Zabbix 7.0 or later, https) (the default) | Your Zabbix front end is reachable over https | The Zabbix front end URL (api_jsonrpc.php is added for you) and an API token for a user who can write to the host |
| Sender (trapper port, unencrypted) | Your Zabbix server’s trapper port is reachable from the internet | The Zabbix server and Port (default 10051). No token |
The sender protocol is plain TCP. Zabbix encrypts it only with a PSK or client certificates, which SZ-MCP can’t present, so the values cross the internet unencrypted. Prefer the API where you can.
How do I set it up?
Section titled “How do I set it up?”- In SZ-MCP, open Configure › Integrations, click Add an integration, choose Zabbix, and pick the transport.
- Fill in the URL and API token, or the server and port. Set Host name in
Zabbix (default
sz-mcp), then click Save. - Click Template and import the YAML it opens (
sz-mcp-zabbix-template.yaml) into Zabbix. It creates the SZ-MCP alerts template in the Templates/Applications group. - In Zabbix, create a host with exactly the host name you entered, and link the SZ-MCP alerts template to it.
- Back in SZ-MCP, click Send now.
What does the template contain?
Section titled “What does the template contain?”SZ-MCP results, the trapper itemszmcp.results. Its value is a JSON array of{service, code, state, text}, one element per enabled rule plus theSZ-MCPsummary.- A discovery rule that creates a state item and a text item for each
{#SERVICE}. - Three trigger prototypes per service: CRITICAL (priority High), WARNING
(Warning) and UNKNOWN (Average), named
{#SERVICE} is CRITICAL: …with the result text. SZ-MCP: no results for …s (sz-mcp stopped sending), anodatatrigger (Average) on the trapper item, after three intervals without a value.
The nodata period is three times the integration’s interval. Import the
template again after changing the interval.
What do the fields do?
Section titled “What do the fields do?”The host name, Service name prefix, Send everything every (minutes) (default 5, 1–60), The SZ-MCP summary service and Acknowledged, in-downtime and unreachable problems raise the state too work as they do for Nagios and Icinga. So does the state each service reports: the worst unhandled HARD problem of its rule.
What errors can I get?
Section titled “What errors can I get?”Errors show on the integration and under Recent deliveries as
zabbix:<name>:
| Message | What to check |
|---|---|
Zabbix API: … (history.push needs Zabbix 7.0 or later) | The API transport needs Zabbix 7.0 or later. Use the sender on older versions |
Zabbix API: HTTP <status> … | The URL or the token |
Zabbix sender: the server refused the value (no host "<host>" with the SZ-MCP alerts template linked, or this address is not in the item's allowed hosts) | The host name, the template link, and the item’s allowed hosts |
Zabbix closed the connection without a reply (is this host allowed to send to the trapper?) | The trapper’s allowed hosts, or a firewall |
the Zabbix sender needs outbound TCP, which this server does not have | The sender is unavailable on this deployment. Use the API |