[ZBX-18254] Custom alertscript gets "No media defined for user." intermittently Created: 2020 Aug 13  Updated: 2023 Feb 01  Resolved: 2020 Aug 21

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Problem report Priority: Trivial
Reporter: Multazim Deshmukh Assignee: Zabbix Support Team
Resolution: Won't fix Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Zabbix Server: 4.0.20, MySQL DB Version: 5.6.10, Operating System: Ubuntu 18.04


Attachments: JPEG File ZBXemail.jpg     PNG File image-2020-08-21-11-50-21-391.png     PNG File teams.PNG     Text File zabbix_server.log    

 Description   

Steps to reproduce:

Set a user to send notification through custom script

Result:
See screenshot...

Expected:
notification should be delivered & should not show said error. 



 Comments   
Comment by Multazim Deshmukh [ 2020 Aug 13 ]

I see "No media defined for user." message for few of the notifications being sent to Microsoft Teams using a custom alertscript even though media is properly defined for that user.

Comment by Edgars Melveris [ 2020 Aug 17 ]

Hello Multazim.
Please attach Zabbix server log file, that includes the period, where there where failed notifications.

Comment by Multazim Deshmukh [ 2020 Aug 17 ]

I checked zabbix_server.log for that duration and found two errors. 

Permission denied --> I have resolved this by giving correct permission to zabbix group. 

Timeout while executing a shell script --> I have resolved this by reducing the action message payload which was given to the custom script. 

I haven't seen any failures in last 2 days.

Closing the case for now. I will reopen if issue reoccurs in future. 

Comment by Multazim Deshmukh [ 2020 Aug 21 ]

reopening as issue occurred again
 

No references found in Zabbix server log. Attaching zabbix_server.log for the hour when issue occurred.

Please help me investigate this further. 

Comment by Edgars Melveris [ 2020 Aug 21 ]

Try to catch one such situation with an increased debug level for escalator.
You can increase the debug level for a specific process in runtime by executing this command:

zabbix_server -R log_level_increase=escalator

This might increase the size of the log file considerably.
After you have logged the failure, you can decrease the debug level back to normal with this command:

zabbix_server -R log_level_decrease=escalator
Comment by Multazim Deshmukh [ 2020 Aug 21 ]

I did more digging into my script and found some major issues in it.

I have made it cleaner & expect issues to resolve. 

I will definitely increase logging if issue occurs again. 

Comment by Henrik Peitilä [ 2023 Feb 01 ]

Hi,

I have observed same issue also. I'm runninx Zabbix 6.0.12 within swarm using zabbix-*-mysql:alpine-6.0.12 stack.

Unfortunately nothing found in Zabbix logs at that time and this has happened only once as far as I know and have not increased escalator log level.

I'll increase the log level if we are starting to see more of this kind of problems and try to capture the situation.

Generated at Sun Jan 11 05:36:08 EET 2026 using Jira 10.3.13#10030013-sha1:56dd970ae30ebfeda3a697d25be1f6388b68a422.