Description

This knowledge base article provides a simple example of how to generate a trap based on a specific SysLog event. 

Symptoms

Event policies can include an action that raises traps for events based on system log messages. This feature enables notification of an SNMP trap-based application when an important system log message occurs. You can convert any system log message,for which there is no corresponding trap, into a trap. If you are using network management system traps rather than system log messages to monitor your network, you can use this feature to ensure that you get notified of all the major events.

Solution

To configure a policy that raises a trap on receipt of an event, include the following statements at the [edit event-options policy policy-name] hierarchy level:

[edit event-options policy policy-name]
events [ events ];
   then {
      raise-trap;
}

The following example shows the sample configuration for raising a trap for the event 'ui_mgd_terminate' :

Generating Traps Based on SysLog Events
[edit event-options policy p1]
events ui_mgd_terminate;
   then {
       raise-trap;
}

Related Information