Server Fault Asked by Alfred Balle on January 11, 2021
I’m running Debian 8 and Zabbix 3.4 and made a custom alert script, which runs fine when I run in terminal from /usr/lib/zabbix/alertscripts
:
./sms.sh
This send a SMS via Nexmo.
In my zabbix_server.conf I have:
AlertScriptsPath=/usr/lib/zabbix/alertscripts
I’ve created a custom media type following https://www.zabbix.com/documentation/3.4/manual/config/notifications/media/script
But the script is not being called.
My permissions for the script is:
ls -alh
total 12K
drwxr-xr-x 2 root root 4.0K Jun 27 12:26 .
drwxr-xr-x 4 root root 4.0K Jun 6 11:12 ..
-rwxr-xr-x 1 root root 181 Jun 27 12:37 sms.sh
I’ve tried to grep for “sms” and “nexmo” in the /var/log/ directory to see if any errors occurred. Nothing.
I’m ending my script with
exit 0
How to debug?
Configure:
DebugLevel=5
and restart&check zabbix server logs. Good test will be also to run your sms.sh script under zabbix
user.
Answered by Jan Garaj on January 11, 2021
Get help from others!
Recent Answers
Recent Questions
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP