How to configure vlan-translation via CLI and SNMP on ECS4620 series ?

Steven_zhangCreated at:Dec 11, 2019 14:06:11Updated at:Dec 11, 2019 14:06:20

Scenario:

Apply VLAN translation on port 1 of ECS4620-28P.

mceclip0.png

 

Configuration on ECS4620-52P:

ECS4620-52P#con
ECS4620-52P(config)#vlan database
ECS4620-52P(config-vlan)#vlan 10,20
ECS4620-52P(config-vlan)#ex
ECS4620-52P(config)#interface ethernet 1/1
ECS4620-52P(config-if)#switchport allowed vlan add 10,20 tagged
ECS4620-52P(config-if)#ex
ECS4620-52P(config)#interface ethernet 1/3
ECS4620-52P(config-if)#switchport allowed vlan add 10 untagged
ECS4620-52P(config-if)#switchport native vlan 10
ECS4620-52P(config-if)#switchport allowed vlan remove 1
ECS4620-52P(config-if)#ex
ECS4620-52P(config)#interface ethernet 1/4
ECS4620-52P(config-if)#switchport allowed vlan add 20 untagged
ECS4620-52P(config-if)#switchport native vlan 20
ECS4620-52P(config-if)#switchport allowed vlan remove 1
ECS4620-52P(config-if)#end

 

Configuration on ECS4620-28P:

ECS4620-28P#con
ECS4620-28P(config)#vlan database
ECS4620-28P(config-vlan)#vlan 100,200
ECS4620-28P(config-vlan)#ex
ECS4620-28P(config)#interface ethernet 1/3
ECS4620-28P(config-if)#switchport allowed vlan add 100 untagged
ECS4620-28P(config-if)#switchport native vlan 100
ECS4620-28P(config-if)#switchport allowed vlan remove 1
ECS4620-28P(config-if)#ex
ECS4620-28P(config)#interface ethernet 1/4
ECS4620-28P(config-if)#switchport allowed vlan add 200 untagged
ECS4620-28P(config-if)#switchport native vlan 200
ECS4620-28P(config-if)#switchport allowed vlan remove 1
ECS4620-28P(config-if)#ex
ECS4620-28P(config)#interface ethernet 1/1
ECS4620-28P(config-if)#switchport allowed vlan add 100,200 tagged
ECS4620-28P(config-if)#switchport vlan-translation 10 100
ECS4620-28P(config-if)#switchport vlan-translation 20 200
ECS4620-28P(config-if)#end

 

[CLI Command] switchport vlan-translation original-vlan new-vlan

Port1 of ECS4620-28P

Console(config-if)#switchport vlan-translation 10 100

Ingress -> map original-vlan(VLAN10) to new-vlan(VLAN100)

Egress -> map new-vlan(VLAN100) to original-vlan(VLAN10)

 

[SNMPSET command format]

snmpset -v 2c -c private {switch ip} { vlanTraslationPortStatus | vlanTraslationPortNewVid }.{vlanTraslationPortIndex}.{vlanTraslationPortOldVid} {integer} {value}

 

For vlanTraslationPortStatus, OID 1.3.6.1.4.1.259.10.1.41.1.12.22.1.4

 Set OID 1.3.6.1.4.1.259.10.1.41.1.12.22.1.4 to valid(1) to create an entry.

 Set OID 1.3.6.1.4.1.259.10.1.41.1.12.22.1.4 to invalid(2) to destroy an entry.

For vlanTraslationPortNewVid, OID 1.3.6.1.4.1.259.10.1.41.1.12.22.1.3

 Specify the new VLAN ID that will be mapped to.

For vlanTraslationPortIndex: The port interface of vlanTraslationPortIndex

 The interface identified by a particular value of this index is the same interface as identified by the same value of ifIndex in the IF-MIB.

For vlanTraslationPortOldVid,

 Specify the original VLAN ID that the traffic arrive.

 

(1) vlanTraslationPortStatus, OID 1.3.6.1.4.1.259.10.1.41.1.12.22.1.4 ; vlanTraslationPortIndex = 1 ; vlanTraslationPortOldVid = 10 (Integer 1 :valid)

mceclip1.png

vlanTraslationPortStatus, OID 1.3.6.1.4.1.259.10.1.41.1.12.22.1.4 ; vlanTraslationPortIndex = 1 ; vlanTraslationPortOldVid = 20 (Integer 1 :valid)

mceclip2.png

(2) vlanTraslationPortNewVid, OID 1.3.6.1.4.1.259.10.1.41.1.12.22.1.3 ; vlanTraslationPortIndex = 1 ; vlanTraslationPortOldVid = 10 (Integer 100 :new vlan ID vlan100)

mceclip3.png

vlanTraslationPortNewVid, OID 1.3.6.1.4.1.259.10.1.41.1.12.22.1.3 ; vlanTraslationPortIndex = 1 ; vlanTraslationPortOldVid = 20 (Integer 200 :new vlan ID vlan200)

mceclip4.png

Display the configuration settings for VLAN translation.

mceclip5.png

 

Result

VLAN10 - Client1(192.168.10.88) and VLAN100 - Client2(192.168.10.99) can ping each other.

mceclip6.png

MAC-address-table of ECS4620-52P

mceclip7.png

MAC-address-table of ECS4620-28P

mceclip8.png

VLAN20 - Client1(192.168.20.88) and VLAN200 - Client2(192.168.20.99) can ping each other.

mceclip9.png

MAC-address-table of ECS4620-52P

mceclip10.png

MAC-address-table of ECS4620-28P

mceclip11.png