Configure sm_notify.log of SAM Notification Adapter so mail notifier will log processed notifications
search cancel

Configure sm_notify.log of SAM Notification Adapter so mail notifier will log processed notifications

book

Article ID: 315770

calendar_today

Updated On:

Products

VMware Smart Assurance

Issue/Introduction

How do you configure the sm_notify.log of the Smarts SAM Notification Adapter so that the mail notifier will log processed notifications?

Smarts SAM Notification Adapter sm_notify.log for mail notifier does not contain any messages about processed notifications.

Environment

VMware Smart Assurance - SMARTS

Cause

By default, the log file for sm_notify process only logs its connect/disconnect events to the domain.

Resolution

To add additional logging so that the mail notifier process will log processed notifications, you must change the mail-notify.asl script as follows: 

  1. Open the mail-notify.asl script for editing as follows:

    ./sm_edit rules/notifier/mail/mail-notify.asl
     
  2. Find the mailer-> function to send mail at the very end of the script.
  3. Add a print statement below the mailer-> function as follows:

    68      mailer->sendmail(sender, recipients, subject, body) ? LOG, STOP;
    69      print(sender."\t".recipients."\t".subject."\t".body."\n");  /*print statement added for logging.*/
     
  4. Restart the sm_notify service. Notifications processed by the adapter will be written to the log.