Ad Widget

Collapse

Problem with email in Zabbix

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • kqfp31
    Member
    • Apr 2012
    • 48

    #1

    Problem with email in Zabbix

    Hi
    I try to make mail notification form Zabbix.
    Right know I few scripts and nothing working.
    For example I have script :
    /etc/zabbix/alert.d/zext_msmtp.sh
    with code:
    account zabbix
    tls on
    tls_starttls on
    tls_trust_file /etc/ssl/certs/ca-certificates.crt
    host smtp.gmail.com
    port 587
    auth on
    user mymail
    password mypassword
    from mymail
    logfile /var/log/msmtp.log

    Permission:

    -rwxr-xr-x 1 root root 219 Oct 31 17:06 /etc/zabbix/alert.d/zext_msmtp.sh

    Here is everything:


    I set Media Types:
    (Nr 1 on teh scren)

    I set user:
    (Nr 2 on teh scren)

    And I set Action:
    (Nr 3 on teh scren)

    In dashboard I have information that email was send:
    (Nr 4 on teh scren)
    But I don't get anything :/

    And in the log file is nothing

    Oct 26 16:33:32 host=smtp.gmail.com tls=on auth=on [email protected] from=default [email protected] mailsize=40 smtpstatus=250 smtpmsg='250 2.0.0 OK 1351254839 e7sm2407548eep.1' exitcode=EX_OK
    Oct 26 17:28:03 host=smtp.gmail.com tls=on auth=on [email protected] from=default [email protected] mailsize=40 smtpstatus=250 smtpmsg='250 2.0.0 OK 1351258111 t7sm2651083eel.14' exitcode=EX_OK
    ~

    Please, help
  • tchjts1
    Senior Member
    • May 2008
    • 1605

    #2
    My experience has been that if Zabbix shows that the e-mail has been sent, then it is not a Zabbix issue. It is outside of Zabbix. Screenshot #4 shows it has been sent.

    Are you checking your gmail spam/junk folders to see if it has gone there?

    Comment

    • kqfp31
      Member
      • Apr 2012
      • 48

      #3
      I check and unfotunately it is not in spam.

      Comment

      • lukeiam
        Member
        • Sep 2012
        • 38

        #4
        Hello,

        First of all, try simpler settings. Using no encryption, no authentication and maybe port 25 if possible. Can you telnet to the destination port? Some ISP block it. Check your maillog to see if the email is in deffered queue or if it actually got sent. If it was sent it will tell you the server name it was forwarded to.

        Regards,

        Luke

        Comment

        Working...