This article provides information on how to enable the SNMP_TRAP_LINK_UP syslog message in the default syslog configuration and introduces a new feature - priority-override under the event-options hierarchy level to enable it.
By default, in Junos, the severity level for all of the facilities is notice ; except for the authorization facility:
file messages { any notice; authentication info;}
Before Junos 12.1, use the following workaround:
file messages { any notice; authentication info; explicit-priority; } file interface_status { daemon info; explicit-priority; match "(SNMP_TRAP_LINK_UP|SNMP_TRAP_LINK_DOWN)"; }
host 10.0.0.1 { any notice; authentication info; explicit-priority; } host 10.0.0.2 { daemon info; explicit-priority; match "(SNMP_TRAP_LINK_UP)|(SNMP_TRAP_LINK_DOWN)"; }
event-options { policy test { events SNMP_TRAP_LINK_UP; then { priority-override { facility daemon; severity notice; } } } }
2018-04-21: corrected match "(SNMP_TRAP_LINK_UP)|(SNMP_TRAP_LINK_DOWN)" syntax.2024-06-13: adding the url for event ID