Icinga2 : EMail Notification

Hi ,

we have an Icinga2 Installed in our environment , we would like to send Icinga monitoring report ( server Uptime ) to Email Id on weekly basis, i am new to this monitoring tool and need assistance to configure this setup perfectly , can anyone please asssist.

Hello and welcome.

To be able to send notifications you need a package that provides the mail command and a MTA (like postfix) on your master server that relays the messages to a mail server.
Icinga will trigger the notification script based on your defined notification rules (see docs for a first start: Notifications)

There should be plenty guides on the net/youtube that walk you through the whole setup. Be sure to use a fairly recent guide, as things might/will have changed over time.

In case you stumble into problems then, feel free to ask here again!

Hi @log1c - i tried to for whole setup but no luck yet. , can you paste here any link that will walk through the whole setup , please assist.

Sure, I can google that for you :wink:

This one looks pretty good, apart from the fact that it uses other notification scripts than the standard ones provided by Icinga itself.

Instead of creating the notification commands from scratch, like the guide does, I would suggest using the one from the Icinga example configuration by adding the following line to /etc/icinga2/icinga2.conf

include "conf.d/commands.conf"
(systemctl reload icinga2 is needed afterwards)

And then run the Icinga Director Kickstart Wizard from the web interface @ .../director/dashboard?name=infrastructure#!/director/kickstart to have them available in the Director.

You would then use them instead of the Host Alarm By Email and Service Alarm By Email commands from the guide.

Hi @log1c - unfortunately , icingaweb is not installed in our environment.

if i installed that , will that affect the current running setup alerts?

also , i have tried to do the below configuration , but still no luck , please have a look as below.


Hi @log1c - i have done the setup , when i run the mail script , , it fetching email as below

my requirement is to get the server weekly report as shown below in the Email , can you let me know how it will get possible?

this would be more a reporting thing:

if you use icingadb the sla reports are already available once reporting is installed in icingaweb2

if you use ido/monitoring there is an own module for the reports:

1 Like

AS the last screenshot tells you, you have a duplicate definition of the notification commands.
Either do not include the conf.d/commands.conf file or delete your own commands-perspectium.conf

Then, as @moreamazingnick saif, have a look at the reporting module, that sound more like what you need in regard to Emails for host/service SLA reports.