Alert Email body unable to change

We have created template for postgresql database alert.like warnings errors now we received warnings errors but we haven’t recieved in our custom template (hostname) like database server details in email body.

Can you please share the entire template? If you make your own template, then that is all the data shown. Nothing else will be added. If you want server names, you need to add those variables to the template.

When we are using default template all is good but when we are using custom template we need to show server name or other things there but we can’t show values there, Can you please give me some step by step guidance or query for this issue.

Please find attached template or mails.

I don’t have an step-by-step guidance. I have an example that I used on another customer to output all keys and values. Perhaps you can edit this to suit your needs.

Okay thank you !! I had another question, how can I display the errors that appear in my postgresql database log file in these tools or how can I fire an email alert for that error?

If you want logs from your DB in PMM, you need to setup Loki, a plugin and side companion to Grafana. Here’s a blog that gives some guidance:

Since this is not officially supported, you’ll have to troubleshoot things on your own. You might end up having to create some custom alarms in PMM to trigger events from the logs in Loki.