Description

This article describes how to poll native-vlan ID information from EX9200 chassis using SNMP OID and ASCII string. The output describes native-vlan ID mapping per individual port.

Symptoms


Solution

Object: dot1qPvid
OID: 1.3.6.1.2.1.17.7.1.4.5.1.1
Type: VlanIndex
Permission: read
Description: "The VLAN ID assigned to untagged frames received on this port."

1) Checking trunk interface configured on chassis
user1 @ex9214-1> show configuration interfaces | display set | match trunk
set interfaces ge-0/0/0 unit 0 family ethernet-switching interface-mode trunk
set interfaces ge-0/0/1 unit 0 family ethernet-switching interface-mode trunk
set interfaces ge-0/0/2 unit 0 family ethernet-switching interface-mode trunk


2) Checking native-vlan mapping before configuring any native-vlan ID (using ASCII)

user1 @ex9214-1> show snmp mib walk ascii dot1qPvid
dot1qPvid.1 = 0 >>>> 0 shows no native-vlan configured.
dot1qPvid.2 = 0 >>>> '.2' stands for the second port switch which is ge-0/0/1 in this scenario.
dot1qPvid.3 = 0


3) Configuring native vlan-id on interface ge-0/0/0 and ge-0/0/1
user1 @ex9214-1# set interfaces ge-0/0/0 native-vlan-id 10 >>>> vlan 10 configured as native-vlan for ge-0/0/0
user1@ex9214-1# set interfaces ge-0/0/1 native-vlan-id 20
>>>> vlan 20 configured as native-vlan for ge-0/0/1

[edit]
user1@ex9214-1# show |compare
[edit interfaces ge-0/0/0]
+ native-vlan-id 10;
[edit interfaces ge-0/0/1]
+ native-vlan-id 20;

[edit]
user1@ex9214-1# commit
commit complete


4) Checking native-vlan mapping after configuration.
user1 @ex9214-1# run show snmp mib walk ascii dot1qPvid
dot1qPvid.1 = 10 >>>> vlan 10 is native for first port (ge-0/0/0)
dot1qPvid.2 = 20 >>>> vlan 20 is native for second port (ge-0/0/1)
dot1qPvid.3 = 0 
>>>> no native-vlan configured for third port (ge-0/0/2)

5) SNMP OID for polling native-vlan mapping
user1 @ex9214-1# run show snmp mib walk .1.3.6.1.2.1.17.7.1.4.5.1.1
dot1qPvid.1 = 10
dot1qPvid.2 = 20
dot1qPvid.3 = 0