T
T
TOParh2016-12-02 16:06:39
linux
TOParh, 2016-12-02 16:06:39

How to run a command via SSH in Zabbix?

Good afternoon, comrades-gentlemen-colleagues!
For the second week I have been struggling with the question - how to force Zabbix to restart the service on the Zimbra mail server.
This is how I set it up:
dab2bf0ec2c54036a70709cd89c606ad.png
When the trigger fires, nothing happens, and the following entry appears on the events.
afdbf97cfa21496ebd18304b5be8ea0c.png
But if you simply run the command
"$ ssh [email protected] zmmailboxdctl restart" on the zabbix server in the console, then the service on the remote server is restarted.
Why is this happening I don't understand?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
S
SagePtr, 2016-12-02
@Berezoff

Is there anything in the server logs?

T
TOParh, 2016-12-05
@Berezoff

Thanks everyone for the advice and replies. The problem was in the settings of the ssh server on Zimbra, I added the useDNS no parameter to the ssh config, which allowed it to work normally through the IP address without being tied to the DNS host name. BUT zabbix still writes an authorization error as in the second screen. So the problem was not completely resolved - I will write about it on the Zabbix forum.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question