Ad Widget

Collapse

Attach file or display contents of file in email alert. {ITEM.VALUE} character limit.

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • anonamoose
    Junior Member
    • May 2019
    • 16

    #1

    Attach file or display contents of file in email alert. {ITEM.VALUE} character limit.

    Hi,

    I'm creating a cron job that uses a simple bash script to create a file with hosts that have failed to run a puppet agent in over an hour and then Zabbix will trigger if the file isn't empty and email the hosts in the file to our systems administrators group.

    My googling landed me on ITEM.VALUE, but it has a serious character deficiency and truncates my list at about 220 characters.

    Is there a way to increase the limit of ITEM.VALUE or an alternative like for instance a remote command like system.run[cat /my/file/path] into the body of the email.

    I just want my full list of hosts that have failed to run puppet agent.

    Or I found this on zabbix documentation:
    Processor load is: {zabbix.zabbix.com:system.cpu.load[,avg1].last()} and that example was in the body of a message. Can system.run be used that way? So I can cat my file.

    I'm playing around with that macro so far with no success.
    Thanks.
    Last edited by anonamoose; 24-08-2019, 00:34.
  • anonamoose
    Junior Member
    • May 2019
    • 16

    #2
    Figured it out. User error. {ITEM.VALUE} wasn't the problem. I defined the trigger as character instead of text. If anyone else stumbles on this, character is a 255 char limit and text is 64KB. Good to know going forward, woops

    Comment

    Working...