Customer have configured a vrf "<vrf name>" with the context "<context name>" and these information are populated via the below oids.
{10, ".1.3.6.1.6.3.18.1.1.1.5"} #snmpCommunityContextNameThe reason to include and read the ciscoContextMappingOID (i.e .1.3.6.1.4.1.9.9.468.1.1.1.2) is because of implementing a strategy on managing a Cisco Nexus switch with multiple VRFs using SNMPv3.
Previously with SNMPv2, one can use the VDC contexts to map to each VRF. This would populate the SNMP-COMMUNITY-MIB::snmpCommunityContextName (.1.3.6.1.6.3.18.1.1.1.5) OID. Smarts would query this OID when discovering the device and then use the <community>@<context> syntax to discover and aggregate the results. However, when the VDC/VRF mapping is removed (a Cisco SNMPv2 command), the SNMP-COMMUNITY-MIB::snmpCommunityContextName OID is no longer populated. This results in only the default VRF being discovered.
An option to achieve this is to map a SNMPv3 security context to a VRF. This means that Smarts would have to be modified to discover all the security context on the Nexus switch. As per recommnedation from Cisco, we can use "CISCO-CONTEXT-MAPPING-MIB" to discover the context which should populated for both SNMPv2c and SNMPv3.
To do this, Smarts discovery included a logic to walk both the "snmpCommunityContextName" and "ciscoContextMapping" and add all the context information to a tables and use it to walk the context for information.
The problem is, if there are overlapping details, the information would get overridden in the table and thus retaining only unique entries. Thus a code change was made so when the context and VRF name are different, Smarts would seem them as two different context and hence the issue with discovery in this case.