Welcome to Pandora FMS Community!

Find answers, ask questions, and connect with our community around the world.

Welcome to Pandora FMS Community Forums Community support Advanced troubleshooting modulegraph in email alert not showing, but API check OK

  • modulegraph in email alert not showing, but API check OK

    Posted by taxis on August 6, 2019 at 11:21

    Hello,

    I have some problems with the graphs in email alerts.

    I use the macro _modulegraph_2h_ in the email alert, but I only get an red cross icon in the received alert email.

    I configured the pandora_server.conf with the described options:
    console_api_url http://10.1.7.20/pandora_console/include/api.php
    console_api_pass apipass
    console_user admin
    console_pass pandora

    In the console gerneral configuration, I put the following IPs to the API Access IPs:
    127.0.0.1
    10.1.7.20
    *
    And I fill the API-Password with the obove one.

    Now I used the API Checker in the console and also the check commando on the cli.
    In both times, I get an correct result -> OK,v7.0NG.737,PC190731
    So I guess, the API function is working correctly.

    But in the alert Email, there is no modulegraph, only the red cross picture.

    What is wrong, how can I fix it??

    Greetings
    Martin

    diego-m replied 5 years, 3 months ago 2 Members · 3 Replies
  • 3 Replies
  • diego-m

    Moderator
    August 6, 2019 at 16:44
    500 Karma points
    Community rank: tentacle_master_icon Tentacle Master
    Like it
    Up
    0
    Down
    Drop it
    ::

    Hello Martin,

    The macro you are talking about is “_modulegraph_24h_”, the hours aren’t a parameter so it wont work if you write “_2h_”.

    Best regards.
    Diego

  • taxis

    Member
    August 6, 2019 at 18:08
    0 Karma points
    Community rank: tentacle-noob-1 Tentacle noob
    Like it
    Up
    0
    Down
    Drop it
    ::

    Hello Martin,

    The macro you are talking about is “_modulegraph_24h_”, the hours aren’t a parameter so it wont work if you write “_2h_”.

    Best regards.
    Diego

    Hello Diego,

    but in your documentation for this macro is the use of hours described:
    _modulegraph_nh_: (Only for alerts that use the command eMail) Returns an image codified in base64 of a module graph with a period of n hours (eg. _modulegraph_24h_). A correct setup of the connection between the server and the console’s api is required. This setup is done into the server’s configuration file.

    For testing, I changed the macro to _modulegraph_24h_, but no difference, the graph isn’t showing in the email alert.

    Greetings
    Martin


    Hello Diego,

    I found the problem.
    After I configured “phantomjs”, the modulegraph is working in email alert.

    Greetings
    Martin

  • diego-m

    Moderator
    August 7, 2019 at 10:09
    500 Karma points
    Community rank: tentacle_master_icon Tentacle Master
    Like it
    Up
    0
    Down
    Drop it
    ::

    Hello Martin

    Thank you for the advice with the documentation, we’ll check that!

    Enjoy PandoraFMS
    Diego