A customer VLAN that clashes with the provider's
A customer hands over its employee traffic tagged VLAN 10, but inside the provider's network VLAN 10 already belongs to someone else. The provider wants to carry this customer's traffic as VLAN 510. VLAN translation (also called VLAN mapping) rewrites the VLAN ID at the edge, in both directions. The same trick helps when two companies merge and their VLAN numbers clash.
Rewriting the tag in both directions
Device key: Provider edge (switch) · Provider network (network / service)
Lines show the example’s network connections. Thick links: uplinks/WAN, as labelled. The coloured path and envelope follow the current step; its text identifies the sender, receiver and traffic type.
- 1. Arrives as VLAN 10. The customer's frame comes in on the trunk tagged 10.
- 2. Leaves as VLAN 510. The edge switch rewrites the tag to 510 and forwards it inside the provider network.
- 3. Return traffic. Replies come back tagged 510…
- 4. Translated back. …and are rewritten to 10 before reaching the customer. Neither side knows the other's numbering.
Why it's different from QinQ: translation replaces the VLAN ID (one tag in, one tag out), while QinQ adds an outer tag and keeps the original. Translation also doesn't touch IP addresses; it's purely a Layer 2 relabel.
In practice the feature lives mostly on provider-edge and metro Ethernet switches. Many campus access switches don't offer it at all, so check the platform before designing a merger around it.
Mapping VLAN 10 to 510 on the trunk
interface GigabitEthernet1/0/1
description Trunk to customer
switchport mode trunk
switchport vlan mapping 10 510One-to-one mapping on the customer-facing trunk: frames arriving tagged 10 are switched in VLAN 510, and VLAN 510 leaves this port tagged 10. Syntax and support vary by platform (and some need VLAN 510 allowed on the trunk), so check your switch's documentation.
Checking that each side sees its own number
show interfaces vlan mappingLists each interface's original and translated VLAN IDs.
Then confirm in practice: the customer still sees VLAN 10 on its side (show interfaces trunk on the customer switch), while inside the provider network the traffic appears in VLAN 510 (for example show mac address-table vlan 510 lists the customer's MAC addresses).
Test yourself on VLAN translation
After translating 10 → 510, does the customer's IP addressing need to change?
Two customers both use VLAN 10 and the provider wants to keep each customer's tags intact end to end. Translation or QinQ?