NetWorker: How To Configure Policy Email Notifications
Summary: This KB offers an overview of NetWorker logging and how to configure Simple Mail Transfer Protocol (SMTP) email notifications for policy-based actions.
Instructions
NetWorker notifications can send backup info to default logs or email addresses using SMTP, using the NetWorker server's operating system mail command.
Log Locations:
/nsr/logs
Windows (Default):
C:\Program Files\EMC NetWorker\nsr\logs
/nsr/logs/policy by default, even if email is used for notifications instead of nsrlog. The 'nsrlog -f filename' command is used to send the policy completion details to a specified file under /nsr/logs. The default file is /nsr/logs/policy_notifications.log.
Email Commands:
mail [-s smtphost] [-s subject] [-r sender] recipient [recipient[...]]Windows:
smtpmail [-s subject] [-h smtphost] [-p port] [-f sender] recipient [recipient[...]]
mail command:
mail/mailx: https://linux.die.net/man/1/mailsmtpmail: https://www.mkssoftware.com/docs/man1/smtpmail.1.asp
The Send Notification conditions have the following options:
- On Failure: Only sends a notification when a job has failed.
- On Completion: An email is sent whether the backup is successful or failed.
The notifications are configured at the POLICY, WORKFLOW, or ACTION level.
By default the WORKFLOW and ACTION notification setting is set to "Set at Policy Level":
Workflow notification settings:
With this configuration, the following would be received:
1 "Action Report" for each ACTION under this policy.
For example, with this configuration the "Server Protection" policy sends three email messages:
2 "Action Report" notifications show the completion time and status and information for each ACTION, e.g: the "Expiration" and "Server db backup" ACTIONS.
POLICY: On completion or failure - operating system-specific mail command and options. See Email Commands.
WORKFLOW: On completion or failure - "nsrlog -f policy_notifications.log"
ACTION (expiration only): On completion or failure - "nsrlog -f policy_notifications.log"
With this configuration one email is received showing the backup details, the WORKFLOW notifications and "Expiration" ACTION details are sent to the default policy_notifications.log