Observium Professional edition – Email setup

The default config file email setup needs some additions

pico /opt/observium/config.php

Existing config:

// Set up a default alerter (email to a single address)
$config['alerts']['alerter']['default']['descr']   = "Default Email Alert";
$config['alerts']['alerter']['default']['type']    = "email";
$config['alerts']['alerter']['default']['contact'] = "you@yourdomain.org";
$config['alerts']['alerter']['default']['enable']  = TRUE;

Add:

$config['email']['default']        = "you@yourdomain.org";
$config['alerts']['email']['from'] = "Observium <observium@yourdomain.org>";
$config['email']['default_only']   = TRUE;

Testing it:

root@observium:/opt/observium# php test_mail.php -h router
Observium v0.14.10.5903
Test E-mail Configuration
My Hostname: observium
E-mails ENABLED globally
E-mails use PHP-builtin MAIL backend
E-mails send only to default email
E-mails use these default recipient(s):
  you@yourdomain.org
E-mails send from:
  "Observium" <observium@yourdomain.org>
Try send test notification for router to these email(s):
  you@yourdomain.org
Notification for router SENT.

Multiple recipients can be defined as well.

$config['email']['default'] = "me@yourdomain.org,myself@yourdomain.org,i@yourdomain.org";

If you are having issues getting the mail to send, make sure that you actually have a device added and you are using it’s name for the test. Also exim4 needs to be set up correctly. This is an excellent resource.

Leave a Reply

Your email address will not be published. Required fields are marked *

*