Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 
 

SNMP Scripts Overview

Junos OS SNMP scripts, which are supported in Junos OS Release 15.1 and later releases, provide the flexibility to support custom MIBs that are not implemented in the Junos operating system (Junos OS). SNMP scripts are triggered automatically when the SNMP manager requests information from the SNMP agent for an object identifier (OID) that is mapped to an SNMP script for an unsupported OID. The script acts like an SNMP subagent, and the system sends the return value from the script to the network management system (NMS).

Note:

SNMP must be configured on the device before SNMP scripts can provide values for OIDs.

Table 1 lists SNMP script tasks and where to find details.

SNMP scripts are based on the Junos XML management protocol and the Junos XML API, which are discussed in Junos XML Management Protocol and Junos XML API Overview. You can write SNMP scripts in Python, Extensible Stylesheet Language Transformations (XSLT), or Stylesheet Language Alternative syntaX (SLAX). SNMP scripts written in SLAX and XSLT use XPath to locate the operational objects to be inspected and XSLT constructs to specify the actions to perform on the located operational objects. The actions can change the output or execute additional commands based on the output.