Setting up email for mailing reports
After generating a report, you can send it to multiple recipients via email as a PDF file or as an attached zipped HTML file. You can also publish a generated report. For more information, see Publishing-a-report.
From the Mail tab, you can define the settings, like encryption type, user name, and password, for the email that contains your generated report. See detailed description of the mail settings in Managing-email-settings.
As reports can be assigned to several groups, every recipient in the distribution group receives the email with the report designated for that group. Each email specifies the group name and the attachment in the following format:
- Subject: <subject text> <group name>
- Attachment: <report name>.<group name>.<file extention>
For Example:
Subject: Have a look at this!
All Devices with Agent Attachment: Hardware Summary List. All Devices with Agent.html
Before you begin
Before you can send an email to a specific recipient, an administrator, or an administrator group, you must ensure that the email is set up for the BMC Client Management. For more information, see Managing-email-settings.
To set up the email for mailing reports
- In the left window pane of the BMC Client Management application select Reports and then select the required report from the list.
- In the right window pane, select the Mail tab.
- Select Edit > Add email
The Define Mail dialog box is displayed. - To add recipients, click To , CC , BCC.
The Select an Address dialog box is displayed. Perform one of the following actions:
Action
Purpose
Description
Select from List
To select an administrator or an administrator group
If you select an administrator group as recipient, the email will be sent to all members having a valid email address specified in their respective General tab.
Select Manually
To enter any valid email address into designated text box
You can enter more than one email address by using a semicolon as separator. For example: scotty@enterprise.com;kirk@enterprise.com
- (Optional) Enter a subject in the Subject text box.
This text box can contain up to 256 characters. If this text box is left empty, the subject of the email will only consist of the Group's name the respective report is assigned to. - (Optional) Enter a message into the designated text box. You can use up to 2000 characters.
- From the Export Format list, select the format of the attached report .
- (Optional) Clear the Attach Report to Mail check box.
If you clear this check box, the email will only contain a link to the storing location of the respective report in the Report Portal of the agent interface. - To confirm the data for the email and add it to the list, click OK.
To enable HTML reports to be displayed in the email body for Windows
After 21.02.03 patch for on-premises installations you can generate an HTML report that will be sent in the email as an attached zipped file. In order to activate this option, you need to install Node.js. Users with limited system access or permissions find HTML reports more convenient than receiving files.
Download Node.js from the official Node.js website. You should choose the most suitable LTS version; 16.x is recommended. Install it by using the wizard.
- From Windows PowerShell terminal, run the npm install -g puppeteer command.
- Set NODE_PATH in the System environment variable with the complete path of the node_modules folder containing the puppeteer module. The default path for Windows is C:\Users\<user>\AppData\Roaming\npm\node_modules, where <user> stands for the current Windows logged in user.
To enable attached html email, in Vision64Database.ini set EmbeddedHtmlEmail to true:
[Report]
EmbeddedHtmlEmail=true[Report]
Defines if we want to use embedded HTML emails(no attachments)
This requires installation of Node.js and puppeteer module.
EmbeddedHtmlEmail=true
[OpRUleThread]
Section for OPRule thread settings. The Op Rule thread is a background thread that runs periodically updating Op Rules and their results.- For the System environment settings to be implemented, restart the BCM Service or reboot the machine.
- In the BCM Client Management application, from the Mail tab > Export Format list, select html.
- Select Attach Report to Mail check box.
To enable HTML reports to be displayed in the email body for Linux
- Download Node.js from the official Node.js website.
To install Node.js for the Linux Distributions, download Package installation. The detailed instructions on the installation process are available on the Node.js Documentation page. The process of implementing settings for HTML report is described in the Debian master example. From the terminal, run the following commands:
install curl if not already installed: sudo apt-get install curl
sudo curl -fsSL https://deb.nodesource.com/setup_16.x | sudo bash -
sudo apt-get install -y nodejs npm
sudo npm install -g puppeteerTo enable attached html email, in Vision64Database.ini set EmbeddedHtmlEmail to true:
[Report]
EmbeddedHtmlEmail=true- Restart BMC Client Management Service.
- Modify convertHtmlReportAsImage.js in ../data/Vision64Database/reports/common/js/ by following further steps:
- Add the default path for puppeteer. Line 1 should read:
const puppeteer = require ('/usr/lib/node_modules/puppeteer') - Add launch parameters to the launch function. Line 4 should read:
const browser = await puppeteer.launch({
executablePath: '/path/to/Chrome',
args: ['--no-sandbox']});
- Add the default path for puppeteer. Line 1 should read:
- In the BCM Client Management application, from the Mail tab > Export Format list, select html. And then Select Attach Report to Mail check box.