Job email notifications per organization for Veeam Backup for Microsoft 365

Job email notifications per organization for Veeam Backup for Microsoft 365

A popular feature request via the Veeam forums is the ability to have email notifications on a per organization or job level within Veeam Backup for Microsoft 365. Currently, this is not available within the product and customers who also use Veeam Backup & Replication are familiar with this option. I decided to look into this and figure out if there was a potential solution by using some Powershell magic.

I’ve put together a script on GitHub that provides a workaround for this by providing emails per organization for all the relevant jobs.

It works by using an external database (CSV file) which contains all the organizations and the contact person’s email.

To use the script, you have to edit the organizations.csv file and list all the organizations to which you want to send an email. Make sure that the organization is listed with the same name as used within the Veeam console.

Organization;Contact
company.onmicrosoft.com;user@company.com

The next step is to edit the settings in the Powershell scripts.

  • VBO365-NotificationPerOrganization – this script will send out notifications per organization
  • VBO365-NotificationPerOrganizationAdministration – this script can be used to generate an email with the origanizations which don’t have a contact person

In both the scripts, all you need to configure is the email setting such as the mail server, the email address from where you send it, and the authentication details.

Once you run these scripts, it will create the required reports.

Script output example

An example of a report for a OneDrive job per organization is shown below:

Once the script finishes, the results are stored in the jobs-result.csv file. This file is used to keep track of when the last email was sent for a specific job. The email will only be sent out for jobs that have finished with one of 3 statuses:

  • Success
  • Warning
  • Stopped

If you run the Administration script, you will receive an email with a report as well.

Automate it

If you want to automate the generation and provide the emails every hour or every day, you can use the Windows Scheduler for this.

2 thoughts on “Job email notifications per organization for Veeam Backup for Microsoft 365

  1. Hi Niels,
    this is exactly what I was looking for but somehow I do not get any email being sent. If I use the same mailserver settings in VBO365 itself I receive those mails or testmail. If I use that “Send-Mailmessage” line in your code with a mix of the given variables and static text (like body = blablabla) I also receive the email. So I’m not sure why your script isn’t sending out mails. There are no errors when running the script. I’m on version 5.0.3.1035.
    Don’t know if you can help me out here. Thx

Comments are closed.

Comments are closed.