By default, Simple Network Management Protocol (SNMP) is disabled on JUNOS devices. To enable SNMP on a JUNOS device, you must include the SNMP configuration statements at the [edit snmp] hierarchy level.
To configure the minimum requirements for SNMP, include the following statements at the [edit snmp] hierarchy level of the configuration:
- [edit]
-
snmp {
-
community public;
- }
The community defined here as public grants read access to all MIB data to any client.
To configure complete SNMP features, include the following statements at the [edit snmp] hierarchy level:
-
snmp {
-
-
client-list client-list-name {
-
ip-addresses;
- }
-
-
community community-name {
-
authorization authorization;
-
client-list-name client-list-name;
-
-
clients {
-
address restrict;
- }
-
-
routing-instance routing-instance-name {
-
clients {
-
addresses;
- }
- }
-
-
logical-system logical-system-name {
-
-
routing-instance routing-instance-name {
-
clients {
-
addresses;
- }
- }
- }
-
view view-name;
- }
-
contact contact;
-
description description;
-
-
engine-id {
- (local engine-id | use-mac-address
| use-default-ip-address);
- }
-
filter-duplicates;
-
-
health-monitor {
-
falling-threshold integer;
-
interval seconds;
-
rising-threshold integer;
- }
-
interface [ interface-names ];
-
location location;
-
name name;
-
-
nonvolatile {
-
commit-delay seconds;
- }
-
-
rmon {
-
-
alarm index {
-
description text-description;
-
falling-event-index index;
-
falling-threshold integer;
-
interval seconds;
-
rising-event-index index;
-
falling-threshold-interval seconds;
-
request-type (get-next-request | get-request
| walk-request);
-
sample-type type;
-
startup-alarm alarm;
-
syslog-subtag syslog-subtag;
-
variable oid-variable;
- }
-
-
event index {
-
community community-name;
-
description text-description;
-
type type;
- }
- }
-
-
traceoptions {
- file filename <files number> <size size> <world-readable
| no-world-readable> <match regex>;
- flag flag;
- }
-
-
trap-group group-name {
-
-
categories {
-
category;
- }
-
destination-port port-number;
-
routing-instance instance;
-
-
targets {
-
address;
- }
-
version (all | v1 | v2);
- }
-
-
trap-options {
-
agent-address outgoing-interface;
-
source-address address;
- }
-
-
view view-name {
-
oid object-identifier (include | exclude);
- }
- }