Watch4net: How do I configure Watch4net to alert on Smarts Events?
search cancel

Watch4net: How do I configure Watch4net to alert on Smarts Events?


Article ID: 307217


Updated On:




VMware Smart Assurance - Watch4Net/M&R
VMware Smart Assurance - SMARTS


How do I configure Watch4net to alert on Smarts Events?

The RPE feature (Report Pack for Events) should and must be already installed and functional. See APG-RPE-How-To.pdf in /opt/APG/Docs or C:\Program Files\APG\Docs.

1. Create the APG Events Adapter in the Alerting module in the Frontend:

In Administration, go to Modules and open Alerting
Select Adapters and click "Create new element":

Type:                    APG Events Adapter
Name:                   Smarts Events Adapter
Value field:            Any numerical field from a Smarts event (such as FirstNotifiedAt). Note you need to specify one. See below for a full list of the Smarts event fields and their data types.
Properties field:    Inculde all fields from a Smarts event that you need to push to the Alerting-Backend. Each field must be separated by a comma. Eg ClassName,Name,EventName
Port:                     4010 (any unused port on the server where the alerting backed is installed)

Click Save
Go to Adapters and ensure the newly created adapter is Enabled.

2. Create an Alert definition.

The Alert filter should filter only on properties made available by the Events Adapter (e.g. EventName is present or ClassName=='Router').
The log template can be used, but the Entry Content should be changed to use Smarts Event fields (e.g. PROP.'ClassName' event is PROP.'Name' and element is PROP.'ElementName').
Again, only use fields that were made available to the Alerting-Backend via the Properties field of the Events adapter.
Save and Enable the alert.

3. Install the Generic-Event-Writer module
/opt/APG/bin/ install generic-event-writer

4. Configure the Event-Processing-Manager to send alerts to the Generic-Event-Writer

Edit /opt/APG/Event-Processing/Event-Processing-Manager/Default/conf/processing.xml:

Add the following line. This will enable the Generic-Event-Writer configuration:

<!-- Generic Event Writer -->
<processing-element name="Generic-Event-Writer" config="Generic-Event-Writer/Default/conf/generic-event-writer.xml"/>

Edit the Smarts-Listener line and set it to send the events also to a Generic-Event-Writer stream named data:

<!-- Smarts Listener -->
<processing-element name="Smarts" config="Smarts-Listener/Default/conf/smarts-listener.xml" data="AC Generic-Event-Writer[data]" />

Edit /opt/APG/Event-Processing/Generic-Event-Writer/Default/conf/generic-event-writer.xml) and enable the stream:
   <!-- Data received on the specified INPUT stream will be sent on the specified port. -->
- Ensure port used (4010) is the same as the one defined for the APG Events Adapter in step 2.
- Ensure the name of the stream (data) is the same as what is specified processing.xml configuration for Smarts-Listener (data="AC Generic-Event-Writer[data]").

5. Restart the Event Processing Manager and check the logs.

The Event Processing Manager will not start if the APG Events Adapter from Step 1 is not enabled.

6. Check the log file created by the Alert created on step 2

 If the file prefix is Alerts/log, the file location will be in /opt/APG/Backends/Alerting-Backend/Default/Alerts/ directory.


Additional Information

Smarts Event fields and their data types:  

    Name                              STRING
    ClassName                      STRING
    InstanceName                STRING
    EventName                     STRING
    ClassDisplayName          STRING
    InstanceDisplayName     STRING
    EventDisplayName         STRING
    ElementClassName         STRING
    ElementName                 STRING
    SourceDomainName      STRING
    SourceEventType         STRING
    Active                           BOOLEAN
    OccurrenceCount         LONG
    FirstNotifiedAt              LONG
    OpenedAt                    LONG
    ClosedAt                      LONG
    LastChangedAt            LONG
    IsRoot                          BOOLEAN
    IsProblem                     BOOLEAN
    Acknowledged             BOOLEAN
    ClearOnAcknowledge  BOOLEAN
    EventType                   STRING
    EventState                  STRING
    Category                     STRING
    EventText                   STRING
    Severity                       LONG
    Impact                         LONG
    Certainty                     FLOAT
    InMaintenance            BOOLEAN
    TroubleTicketID           STRING
    Owner                        STRING
    UserDefined1 - 20      STRING
    Source                        STRING
    SourceSpecific            STRING