Pandora FMS community forums
modulegraph in email alert not showing, but API check OK - Printable Version

+- Pandora FMS community forums (http://pandorafms.org/forum)
+-- Forum: Pandora FMS (http://pandorafms.org/forum/forum-3.html)
+--- Forum: Advanced troubleshooting and problems (http://pandorafms.org/forum/forum-11.html)
+--- Thread: modulegraph in email alert not showing, but API check OK (/thread-13730.html)



modulegraph in email alert not showing, but API check OK - taxis - 08-06-2019

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


RE: modulegraph in email alert not showing, but API check OK - Diego.M - 08-06-2019

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


RE: modulegraph in email alert not showing, but API check OK - taxis - 08-06-2019

(08-06-2019, 12:44 PM)DiegoM Wrote: 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


RE: modulegraph in email alert not showing, but API check OK - Diego.M - 08-07-2019

Hello Martin

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

Enjoy PandoraFMS
Diego