Description

This article provides an example of what configuration should be added to the switch in order to make it response SNMP get-request when management instance is configured.

Symptoms

The switch receives get-request from device/server doing snmp walk, however it fails to response.
 
From snmp traces, the following logs are displayed:
  • Get-request received:
Nov 20 15:24:48.538928 snmpd[6578] >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
Nov 20 15:24:48.539046 snmpd[6578] >>> Get-Next-Request
Nov 20 15:24:48.539098 snmpd[6578] >>> Source:   192.168.X.X
Nov 20 15:24:48.539138 snmpd[6578] >>> Destination: 172.16.X.X
Nov 20 15:24:48.539171 snmpd[6578] >>> Version:   SNMPv2
Nov 20 15:24:48.539203 snmpd[6578] >>> Request_id: 0x6578
Nov 20 15:24:48.539280 snmpd[6578] >>> Community:  Test
Nov 20 15:24:48.539321 snmpd[6578] >>> Error:    status=0 / vb_index=0
Nov 20 15:24:48.539423 snmpd[6578] >>>  OID : .0.1
Nov 20 15:24:48.539467 snmpd[6578] >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
Nov 20 15:24:50.039085 AgentX subagent: /var/run/dot1xd_snmp, PDU request id: 2, trans id: 1, rsp(us): 1497513
  • Switch fails to send Get-response:
Nov 20 15:24:50.039655 snmpd[6578] <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
Nov 20 15:24:50.039750 snmpd[6578] <<< Get-Response
Nov 20 15:24:50.039801 snmpd[6578] <<< Source:   172.16.X.X
Nov 20 15:24:50.039841 snmpd[6578] <<< Destination: 192.168.X.X
Nov 20 15:24:50.039873 snmpd[6578] <<< Version:   SNMPv2
Nov 20 15:24:50.039903 snmpd[6578] <<< Request_id: 0x6578
Nov 20 15:24:50.039936 snmpd[6578] <<< Community:  Test
Nov 20 15:24:50.039967 snmpd[6578] <<< Error:    status=0 / vb_index=0
Nov 20 15:24:50.040027 snmpd[6578] <<<  OID : dot1xPaeSystemAuthControl.0
Nov 20 15:24:50.040069 snmpd[6578] <<<  type : Number
Nov 20 15:24:50.040104 snmpd[6578] <<<  value: 0
Nov 20 15:24:50.040135 snmpd[6578] <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
Nov 20 15:24:50.040331 SNMPD_SEND_FAILURE: jnx_netsnmp_udp_send: send message (192.168.X.X) failure: Can't assign requested address >>>>>> Failure reason
 
Management routing instance is configured:
 
root@sw> show configuration routing-instances
mgmt_junos {
  routing-options {
    static {
      route 0.0.0.0/0 next-hop 10.85.X.X;
 
root@sw> show configuration system
management-instance;
 
SNMP configuration:

set snmp view test oid .1 include
set snmp community Test view test
set snmp community Test authorization read-only
 

Solution

To fix the problem add the following commands:
  • root@sw#set snmp routing-instance-access >>>>> this command allows SNMP managers to access SNMP information from an instance which is not default routing instance
  • root@sw#set snmp community <name> routing-instance <instance's name>

Modification History

2023-11-22 : Article Created

Related Information

https://www.juniper.net/documentation/us/en/software/junos/network-mgmt/topics/topic-map/configuring-snmp-for-routing-instances.html#id-enabling-snmp-access-over-routing-instances