H3C Fixed Port Campus Switches Configuration Examples-6W103

HomeSupportConfigure & DeployConfiguration ExamplesH3C Fixed Port Campus Switches Configuration Examples-6W103
Table of Contents
Related Documents
10-VLAN Tagging Configuration Examples
Title Size Download
10-VLAN Tagging Configuration Examples 862.23 KB

Contents

Introduction· 1

Prerequisites· 1

Example: Configuring QinQ·· 1

Network configuration· 1

Applicable hardware and software versions· 2

Restrictions and guidelines· 4

Procedures· 4

Configuring PE A· 4

Configuring PE B· 5

Configuring devices between PE A and PE B· 6

Verifying the configuration· 6

Configuration files· 6

Example: Configuring one-to-two VLAN mapping· 7

Network configuration· 7

Analysis· 9

Applicable hardware and software versions· 9

Restrictions and guidelines· 11

Procedures· 11

Configuring PE A· 11

Configuring PE B· 13

Configuring devices between PE A and PE B· 14

Verifying the configuration· 14

Configuration files· 15

Example: Configuring QoS policies for SVLAN tagging and 802.1p priority marking  17

Network configuration· 17

Analysis· 18

Applicable hardware and software versions· 19

Restrictions and guidelines· 21

Procedures· 21

Configuring PE A· 21

Configuring PE B· 23

Configuring devices between PE A and PE B· 26

Verifying the configuration· 26

Configuration files· 27

Example: Configuring one-to-one VLAN mapping· 31

Network configuration· 31

Applicable hardware and software versions· 32

Procedures· 34

Configuring Switch A· 34

Configuring Switch B· 35

Verifying the configuration· 35

Configuration files· 35

Example: Configuring many-to-one VLAN mapping· 37

Network configuration· 37

Applicable hardware and software versions· 38

Procedures· 39

Configuring Switch A· 39

Configuring Switch B and Switch C· 40

Configuring Switch D·· 40

Configuring Switch E· 40

Verifying the configuration· 40

Configuration files· 41

Example: Configuring two-to-two VLAN mapping· 42

Network configuration· 42

Applicable hardware and software versions· 43

Restrictions and guidelines· 45

Procedures· 45

Configuring Switch A· 45

Configuring Switch B· 46

Configuring Switch C· 47

Configuring Switch D·· 47

Verifying the configuration· 48

Configuration files· 48

Example: Modifying the CVLAN ID through QoS marking· 50

Network configuration· 50

Analysis· 50

Applicable hardware and software versions· 51

Procedures· 52

Configuring PE A· 52

Configuring PE B· 54

Configuring devices between PE A and PE B· 56

Verifying the configuration· 56

Configuration files· 58

 


Introduction

This document provides examples for using VLAN tagging features to extend customer VLANs (CVLANs) across an Ethernet service provider network.

VLAN tagging features enable service providers to separate or aggregate customer traffic in the service provider network. The following are available VLAN tagging operations:

·     Adding a layer of service provider VLAN (SVLAN) tag.

·     Modifying the SVLAN tag, CVLAN tag, or both.

To add an SVLAN tag, use one of the following VLAN tagging features:

·     QinQ—Tags all incoming frames (tagged or untagged) on the customer-side port with the PVID of the port.

·     One-to-two VLAN mapping—Adds different SVLANs for traffic with different CVLAN tags.

·     Policy-based VLAN manipulation—Uses QoS nest actions in a QoS policy to tag different classes of frames with different SVLAN tags. Traffic classifiers include CVLAN ID, IP address, and MAC address. In addition, you can use QoS priority marking to set the 802.1p priority in SVLAN tags.

To modify VLAN tags, use one of the following VLAN tagging features:

·     VLAN mapping—Includes the following features:

¡     One-to-one VLAN mapping—Replaces one VLAN tag with another.

¡     Two-to-two VLAN mapping—Replaces the SVLAN ID, CVLAN ID, or both IDs for an incoming double-tagged frame.

·     Policy-based VLAN manipulation—Uses a QoS policy to modify the CVLAN or SVLAN ID by using the remark customer-vlan-id or remark service-vlan-id action.

The devices in the service provider network learn MAC addresses of CVLANs into the MAC address table of the SVLAN.

Prerequisites

This document is not restricted to specific software or hardware versions.

The configuration examples in this document were created and verified in a lab environment, and all the devices were started with the factory default configuration. When you are working on a live network, make sure you understand the potential impact of every command on your network.

This document assumes that you have basic knowledge of QinQ, VLAN mapping, QoS nesting, and QoS priority and CVLAN marking.

Example: Configuring QinQ

Network configuration

As shown in Figure 1:

·     The service provider assigns VLAN 1000 to Company A's VLANs 100 through 150.

·     The service provider assigns VLAN 2000 to Company B's VLANs 120 through 200.

Configure QinQ on PE A and PE B to transmit traffic in VLANs 1000 and 2000 for Company A and Company B, respectively.

Figure 1 Network diagram

 

Applicable hardware and software versions

The following matrix shows the hardware and software versions to which this configuration example is applicable:

 

Hardware

Software version

S6812 switch series

S6813 switch series

Release 66xx

S6550XE-HI switch series

Release 6008 and later

S6525XE-HI switch series

Release 6008 and later

S5850 switch series

Release 8005 and later

S5570S-EI switch series

Release 11xx

S5560X-EI switch series

Release 63xx, Release 65xx, Release 66xx

S5560X-HI switch series

Release 63xx, Release 65xx, Release 66xx

S5500V2-EI switch series

Release 63xx, Release 65xx, Release 66xx

MS4520V2-30F switch

Release 63xx, Release 65xx, Release 66xx

MS4520V2-30C switch

MS4520V2-54C switch

Release 65xx, Release 66xx

MS4520V2-28S switch

MS4520V2-24TP switch

Release 63xx

S6520X-HI switch series

S6520X-EI switch series

Release 63xx, Release 65xx, Release 66xx

S6520X-SI switch series

S6520-SI switch series

Release 63xx, Release 65xx, Release 66xx

S5000-EI switch series

Release 63xx, Release 65xx, Release 66xx

MS4600 switch series

Release 63xx, Release 65xx, Release 66xx

ES5500 switch series

Release 63xx, Release 65xx, Release 66xx

S5560S-EI switch series

S5560S-SI switch series

Release 63xx

S5500V3-24P-SI switch

S5500V3-48P-SI switch

Release 63xx

S5500V3-SI switch series (except S5500V3-24P-SI and S5500V3-48P-SI)

Release 11xx

S5170-EI switch series

Release 11xx

S5130S-HI switch series

S5130S-EI switch series

S5130S-SI switch series

S5130S-LI switch series

Release 63xx

S5120V2-SI switch series

S5120V2-LI switch series

Release 63xx

S5120V3-EI switch series

Release 11xx

S5120V3-36F-SI switch

S5120V3-28P-HPWR-SI switch

S5120V3-54P-PWR-SI switch

Release 11xx

S5120V3-SI switch series (except S5120V3-36F-SI, S5120V3-28P-HPWR-SI, and S5120V3-54P-PWR-SI)

Release 63xx

S5120V3-LI switch series

Release 63xx

S3600V3-EI switch series

Release 11xx

S3600V3-SI switch series

Release 11xx

S3100V3-EI switch series

S3100V3-SI switch series

Release 63xx

S5110V2 switch series

Release 63xx

S5110V2-SI switch series

Not supported

S5000V3-EI switch series

S5000V5-EI switch series

Not supported

S5000E-X switch series

S5000X-EI switch series

Not supported

E128C switch

E152C switch

E500C switch series

E500D switch series

Release 63xx

MS4320V2 switch series

MS4320V3 switch series

MS4300V2 switch series

MS4320 switch series

MS4200 switch series

Release 63xx

WS5850-WiNet switch series

Release 63xx

WS5820-WiNet switch series

WS5810-WiNet switch series

Release 63xx

WAS6000 switch series

Release 63xx

IE4300-12P-AC switch

IE4300-12P-PWR switch

IE4300-M switch series

IE4320 switch series

Release 63xx

 

Restrictions and guidelines

When you configure QinQ, follow these restrictions and guidelines:

·     You only need to configure QinQ on customer-side ports of PEs.

·     The link type of the customer-side port can be access, hybrid, or trunk.

¡     If the link type is access, you must assign the port to the SVLAN.

¡     If the link type is trunk, you must assign the port to the SVLAN, and set the SVLAN ID as the PVID of the port.

¡     If the link type is hybrid, you must assign the port to the SVLAN as an untagged VLAN member, and set the SVLAN ID as the PVID of the port. The settings ensure that the port can forward traffic to the customer site with the SVLAN tag removed.

·     For QinQ frames to travel across the service provider network, you must perform the following tasks:

¡     Set the MTU to a minimum of 1504 bytes for each port on the path of QinQ frames. This value is the sum of the default Ethernet interface MTU (1500 bytes) and the length (4 bytes) of a CVLAN tag. The CVLAN tag of QinQ frames is treated as part of the payload during transmission.

¡     Configure all the ports on the forwarding path to allow frames from VLANs 1000 and 2000 to pass through without removing the VLAN tag.

Procedures

Configuring PE A

1.     Create VLANs 1000 and 2000.

<PE_A> system-view

[PE_A] vlan 1000

[PE_A-vlan1000] quit

[PE_A] vlan 2000

[PE_A-vlan2000] quit

2.     Configure GigabitEthernet 1/0/1:

# Configure the port as an access port, and assign the port to VLAN 1000.

[PE_A] interface gigabitethernet 1/0/1

[PE_A-GigabitEthernet1/0/1] port access vlan 1000

# Enable QinQ on the port.

[PE_A-GigabitEthernet1/0/1] qinq enable

[PE_A-GigabitEthernet1/0/1] quit

3.     Configure GigabitEthernet 1/0/2:

# Configure the port as an access port, and assign the port to VLAN 2000.

[PE_A] interface gigabitethernet 1/0/2

[PE_A-GigabitEthernet1/0/2] port access vlan 2000

# Enable QinQ on the port.

[PE_A-GigabitEthernet1/0/2] qinq enable

[PE_A-GigabitEthernet1/0/2] quit

4.     Configure GigabitEthernet 1/0/3:

# Configure the port as a trunk port.

[PE_A] interface gigabitethernet 1/0/3

[PE_A-GigabitEthernet1/0/3] port link-type trunk

# Assign the port to VLANs 1000 and 2000.

[PE_A-GigabitEthernet1/0/3] port trunk permit vlan 1000 2000

# Remove the port from VLAN 1.

[PE_A-GigabitEthernet1/0/3] undo port trunk permit vlan 1

[PE_A-GigabitEthernet1/0/3] quit

Configuring PE B

1.     Create VLANs 1000 and 2000.

<PE_B> system-view

[PE_B] vlan 1000

[PE_B-vlan1000] quit

[PE_B] vlan 2000

[PE_B-vlan2000] quit

2.     Configure GigabitEthernet 1/0/1:

# Configure the port as an access port, and assign the port to VLAN 2000.

[PE_B] interface gigabitethernet 1/0/1

[PE_B-GigabitEthernet1/0/1] port access vlan 2000

# Enable QinQ on the port.

[PE_B-GigabitEthernet1/0/1] qinq enable

[PE_B-GigabitEthernet1/0/1] quit

3.     Configure GigabitEthernet 1/0/2:

# Configure the port as an access port, and assign the port to VLAN 1000.

[PE_B] interface gigabitethernet 1/0/2

[PE_B-GigabitEthernet1/0/2] port access vlan 1000

# Enable QinQ on the port.

[PE_B-GigabitEthernet1/0/2] qinq enable

[PE_B-GigabitEthernet1/0/2] quit

4.     Configure GigabitEthernet 1/0/3:

# Configure the port as a trunk port.

[PE_B] interface gigabitethernet 1/0/3

[PE_B-GigabitEthernet1/0/3] port link-type trunk

# Assign the port to VLANs 1000 and 2000.

[PE_B-GigabitEthernet1/0/3] port trunk permit vlan 1000 2000

# Remove the port from VLAN 1.

[PE_B-GigabitEthernet1/0/3] undo port trunk permit vlan 1

[PE_B-GigabitEthernet1/0/3] quit

Configuring devices between PE A and PE B

# Set the MTU to a minimum of 1504 bytes for each port on the path of QinQ frames. (Details not shown.)

# Configure all ports on the forwarding path to allow frames from VLANs 1000 and 2000 to pass through without removing the VLAN tag. (Details not shown.)

Verifying the configuration

# Verify that each company's PCs can ping each other in the same CVLAN across the service provider network. (Details not shown.)

# Verify that the two companies' PCs cannot communicate at Layer 2 even if their CVLAN IDs are the same. The ARP tables on one company's PCs do not contain entries for MAC addresses of the other company's PCs. (Details not shown.)

Configuration files

IMPORTANT

IMPORTANT:

Support for the port link-mode bridge command depends on the device model.

 

·     PE A:

#

vlan 1000

#

vlan 2000

#

interface GigabitEthernet1/0/1

 port link-mode bridge

 port access vlan 1000

 qinq enable

#

interface GigabitEthernet1/0/2

 port link-mode bridge

 port access vlan 2000

 qinq enable

#

interface GigabitEthernet1/0/3

 port link-mode bridge

 port link-type trunk

 undo port trunk permit vlan 1

 port trunk permit vlan 1000 2000

#

·     PE B:

#

vlan 1000

#

vlan 2000

#

interface GigabitEthernet1/0/1

 port link-mode bridge

 port access vlan 2000

 qinq enable

#

interface GigabitEthernet1/0/2

 port link-mode bridge

 port access vlan 1000

 qinq enable

#

interface GigabitEthernet1/0/3

 port link-mode bridge

 port link-type trunk

 undo port trunk permit vlan 1

 port trunk permit vlan 1000 2000

#

#

Example: Configuring one-to-two VLAN mapping

Network configuration

As shown in Figure 2:

·     Customer A and Customer B each have two branches that require Layer 2 connectivity over the service provider network.

·     Both customers have three types of traffic. For each customer, the service provider assigns one SVLAN by traffic type.

Configure one-to-two VLAN mapping on each customer-side port of PE A and PE B to meet the following requirements:

·     The service provider adds an SVLAN tag to packets from customer networks based on the traffic type, as described in Table 1 and Figure 3.

·     The SVLAN tag uses the same 802.1p priority as the CVLAN tag.

Figure 2 Network diagram

 

Table 1 VLAN mapping table

Traffic type

CVLANs

SVLAN

Customer A

 

 

Video

31 to 40

1003

Voice

21 to 30

1002

Data

10 to 20

1001

Customer B

 

 

Storage

36 to 40

2003

Voice

26 to 35

2002

Data

15 to 25

2001

 

Figure 3 Required traffic pattern in the service provider network

 

Analysis

To support multiple SVLANs and send traffic to the customer networks with the SVLAN tag removed, perform the following tasks on the customer-side ports:

1.     Configure the link type of the ports as hybrid.

2.     Assign the ports to the SVLANs as untagged VLAN members.

For the SVLAN tag to use the same 802.1p priority as the CVLAN tag, configure the customer-side port to use the 802.1p priority in incoming packets for priority mapping.

Applicable hardware and software versions

The following matrix shows the hardware and software versions to which this configuration example is applicable:

 

Hardware

Software version

S6812 switch series

S6813 switch series

Release 66xx

S6550XE-HI switch series

Release 6008 and later

S6525XE-HI switch series

Release 6008 and later

S5850 switch series

Release 8005 and later

S5570S-EI switch series

Release 11xx

S5560X-EI switch series

Release 63xx, Release 65xx, Release 66xx

S5560X-HI switch series

Release 63xx, Release 65xx, Release 66xx

S5500V2-EI switch series

Release 63xx, Release 65xx, Release 66xx

MS4520V2-30F switch

Release 63xx, Release 65xx, Release 66xx

MS4520V2-30C switch

MS4520V2-54C switch

Release 65xx, Release 66xx

MS4520V2-28S switch

MS4520V2-24TP switch

Release 63xx

S6520X-HI switch series

S6520X-EI switch series

Release 63xx, Release 65xx, Release 66xx

S6520X-SI switch series

S6520-SI switch series

Release 63xx, Release 65xx, Release 66xx

S5000-EI switch series

Release 63xx, Release 65xx, Release 66xx

MS4600 switch series

Release 63xx, Release 65xx, Release 66xx

ES5500 switch series

Release 63xx, Release 65xx, Release 66xx

S5560S-EI switch series

S5560S-SI switch series

Release 63xx

S5500V3-24P-SI switch

S5500V3-48P-SI switch

Release 63xx

S5500V3-SI switch series (except S5500V3-24P-SI and S5500V3-48P-SI)

Release 11xx

S5170-EI switch series

Release 11xx

S5130S-HI switch series

S5130S-EI switch series

S5130S-SI switch series

S5130S-LI switch series

Release 63xx

S5120V2-SI switch series

S5120V2-LI switch series

Release 63xx

S5120V3-EI switch series

Release 11xx

S5120V3-36F-SI switch

S5120V3-28P-HPWR-SI switch

S5120V3-54P-PWR-SI switch

Release 11xx

S5120V3-SI switch series (except S5120V3-36F-SI, S5120V3-28P-HPWR-SI, and S5120V3-54P-PWR-SI)

Release 63xx

S5120V3-LI switch series

Release 63xx

S3600V3-EI switch series

Release 11xx

S3600V3-SI switch series

Release 11xx

S3100V3-EI switch series

S3100V3-SI switch series

Release 63xx

S5110V2 switch series

Release 63xx

S5110V2-SI switch series

Release 63xx

S5000V3-EI switch series

S5000V5-EI switch series

Release 63xx

S5000E-X switch series

S5000X-EI switch series

Release 63xx

E128C switch

E152C switch

E500C switch series

E500D switch series

Release 63xx

MS4320V2 switch series

MS4320V3 switch series

MS4300V2 switch series

MS4320 switch series

MS4200 switch series

Release 63xx

WS5850-WiNet switch series

Release 63xx

WS5820-WiNet switch series

WS5810-WiNet switch series

Release 63xx

WAS6000 switch series

Release 63xx

IE4300-12P-AC switch

IE4300-12P-PWR switch

IE4300-M switch series

IE4320 switch series

Release 63xx

 

Restrictions and guidelines

When you configure ports on the forwarding path of double-tagged packets across the service provider network, follow these restrictions and guidelines:

·     Set the MTU to a minimum of 1504 bytes for each port.

·     Configure all ports to allow double-tagged packets to pass through without removing the SVLAN tag.

Procedures

Configuring PE A

1.     Create CVLANs and SVLANs:

# Create CVLANs 10 to 40.

<PE_A> system-view

[PE_A] vlan 10 to 40

# Create SVLANs 1001 through 1003 and SVLANs 2001 through 2003.

[PE_A] vlan 1001 to 1003

[PE_A] vlan 2001 to 2003

2.     Configure the customer-side port GigabitEthernet 1/0/1:

# Configure the port as a hybrid port.

[PE_A] interface gigabitethernet 1/0/1

[PE_A-GigabitEthernet1/0/1] port link-type hybrid

# Assign the port to CVLANs 10 through 40 as a tagged VLAN member.

[PE_A-GigabitEthernet1/0/1] port hybrid vlan 10 to 40 tagged

# Assign the port to SVLANs 1001 through 1003 as an untagged VLAN member.

[PE_A-GigabitEthernet1/0/1] port hybrid vlan 1001 to 1003 untagged

# Remove the port from VLAN 1.

[PE_A-GigabitEthernet1/0/1] undo port hybrid vlan 1

# Configure one-to-two VLAN mapping to add SVLAN tag 1001 to traffic from VLANs 10 through 20.

[PE_A-GigabitEthernet1/0/1] vlan mapping nest range 10 to 20 nested-vlan 1001

# Configure one-to-two VLAN mapping to add SVLAN tag 1002 to traffic from VLANs 21 through 30.

[PE_A-GigabitEthernet1/0/1] vlan mapping nest range 21 to 30 nested-vlan 1002

# Configure one-to-two VLAN mapping to add SVLAN tag 1003 to traffic from VLANs 31 through 40.

[PE_A-GigabitEthernet1/0/1] vlan mapping nest range 31 to 40 nested-vlan 1003

# Configure the port to use the 802.1p priority in incoming packets for priority mapping.

[PE_A-GigabitEthernet1/0/1] qos trust dot1p

[PE_A-GigabitEthernet1/0/1] quit

3.     Configure the customer-side port GigabitEthernet 1/0/2:

# Configure the port as a hybrid port.

[PE_A] interface gigabitethernet 1/0/2

[PE_A-GigabitEthernet1/0/2] port link-type hybrid

# Assign the port to CVLANs 15 through 40 as a tagged VLAN member.

[PE_A-GigabitEthernet1/0/2] port hybrid vlan 15 to 40 tagged

# Assign the port to SVLANs 2001 through 2003 as an untagged VLAN member.

[PE_A-GigabitEthernet1/0/2] port hybrid vlan 2001 to 2003 untagged

# Remove the port from VLAN 1.

[PE_A-GigabitEthernet1/0/2] undo port hybrid vlan 1

# Configure one-to-two VLAN mapping to add SVLAN tag 2001 to traffic from VLANs 15 through 25.

[PE_A-GigabitEthernet1/0/2] vlan mapping nest range 15 to 25 nested-vlan 2001

# Configure one-to-two VLAN mapping to add SVLAN tag 2002 to traffic from VLANs 26 through 35.

[PE_A-GigabitEthernet1/0/2] vlan mapping nest range 26 to 35 nested-vlan 2002

# Configure one-to-two VLAN mapping to add SVLAN tag 2003 to traffic from VLANs 36 through 40.

[PE_A-GigabitEthernet1/0/2] vlan mapping nest range 36 to 40 nested-vlan 2003

# Configure the port to use the 802.1p priority in incoming packets for priority mapping.

[PE_A-GigabitEthernet1/0/2] qos trust dot1p

[PE_A-GigabitEthernet1/0/2] quit

4.     Configure the service provider-side port GigabitEthernet 1/0/3:

# Configure the port as a trunk port.

[PE_A] interface gigabitethernet 1/0/3

[PE_A-GigabitEthernet1/0/3] port link-type trunk

# Remove the port from VLAN 1.

[PE_A-GigabitEthernet1/0/3] undo port trunk permit vlan 1

# Assign the port to SVLANs 1001 through 1003 and SVLANs 2001 through 2003.

[PE_A-GigabitEthernet1/0/3] port trunk permit vlan 1001 to 1003 2001 to 2003

[PE_A-GigabitEthernet1/0/3] quit

Configuring PE B

1.     Create CVLANs and SVLANs:

# Create CVLANs 10 to 40.

<PE_B> system-view

[PE_B] vlan 10 to 40

# Create SVLANs 1001 through 1003 and SVLANs 2001 through 2003.

[PE_B] vlan 1001 to 1003

[PE_B] vlan 2001 to 2003

2.     Configure the customer-side port GigabitEthernet 1/0/1:

# Configure the port as a hybrid port.

[PE_B] interface gigabitethernet 1/0/1

[PE_B-GigabitEthernet1/0/1] port link-type hybrid

# Assign the port to CVLANs 15 through 40 as a tagged VLAN member.

[PE_B-GigabitEthernet1/0/1] port hybrid vlan 15 to 40 tagged

# Assign the port to SVLANs 2001 through 2003 as an untagged VLAN member.

[PE_B-GigabitEthernet1/0/1] port hybrid vlan 2001 to 2003 untagged

# Remove the port from VLAN 1.

[PE_B-GigabitEthernet1/0/1] undo port hybrid vlan 1

# Configure one-to-two VLAN mapping to add SVLAN tag 2001 to traffic from VLANs 15 through 25.

[PE_B-GigabitEthernet1/0/1] vlan mapping nest range 15 to 25 nested-vlan 2001

# Configure one-to-two VLAN mapping to add SVLAN tag 2002 to traffic from VLANs 26 through 35.

[PE_B-GigabitEthernet1/0/1] vlan mapping nest range 26 to 35 nested-vlan 2002

# Configure one-to-two VLAN mapping to add SVLAN tag 2003 to traffic from VLANs 36 through 40.

[PE_B-GigabitEthernet1/0/1] vlan mapping nest range 36 to 40 nested-vlan 2003

# Configure the port to use the 802.1p priority in incoming packets for priority mapping.

[PE_B-GigabitEthernet1/0/1] qos trust dot1p

[PE_B-GigabitEthernet1/0/1] quit

3.     Configure the customer-side port GigabitEthernet 1/0/2:

# Configure the port as a hybrid port.

[PE_B] interface gigabitethernet 1/0/2

[PE_B-GigabitEthernet1/0/2] port link-type hybrid

# Assign the port to CVLANs 10 through 40 as a tagged VLAN member.

[PE_B-GigabitEthernet1/0/2] port hybrid vlan 10 to 40 tagged

# Assign the port to SVLANs 1001 through 1003 as an untagged VLAN member.

[PE_B-GigabitEthernet1/0/2] port hybrid vlan 1001 to 1003 untagged

# Remove the port from VLAN 1.

[PE_B-GigabitEthernet1/0/2] undo port hybrid vlan 1

# Configure one-to-two VLAN mapping to add SVLAN tag 1001 to traffic from VLANs 10 through 20.

[PE_B-GigabitEthernet1/0/2] vlan mapping nest range 10 to 20 nested-vlan 1001

# Configure one-to-two VLAN mapping to add SVLAN tag 1002 to traffic from VLANs 21 through 30.

[PE_B-GigabitEthernet1/0/2] vlan mapping nest range 21 to 30 nested-vlan 1002

# Configure one-to-two VLAN mapping to add SVLAN tag 1003 to traffic from VLANs 31 through 40.

[PE_B-GigabitEthernet1/0/2] vlan mapping nest range 31 to 40 nested-vlan 1003

# Configure the port to use the 802.1p priority in incoming packets for priority mapping.

[PE_B-GigabitEthernet1/0/2] qos trust dot1p

[PE_B-GigabitEthernet1/0/2] quit

4.     Configure the service provider-side port GigabitEthernet 1/0/3:

# Configure the port as a trunk port.

[PE_B] interface gigabitethernet 1/0/3

[PE_B-GigabitEthernet1/0/3] port link-type trunk

# Remove the port from VLAN 1.

[PE_B-GigabitEthernet1/0/3] undo port trunk permit vlan 1

# Assign the port to SVLANs 1001 through 1003 and SVLANs 2001 through 2003.

[PE_B-GigabitEthernet1/0/3] port trunk permit vlan 1001 to 1003 2001 to 2003

[PE_B-GigabitEthernet1/0/3] quit

Configuring devices between PE A and PE B

# Set the MTU to a minimum of 1504 bytes for each port on the path of double-tagged packets. (Details not shown.)

# Configure all ports on the forwarding path to allow packets from VLANs 1001 through 1003 and VLANs 2001 through 2003 to pass through without removing the SVLAN tag. (Details not shown.)

Verifying the configuration

1.     Verify VLAN mapping information:

# Verify VLAN mapping information on PE A.

[PE_A] display vlan mapping

Interface GigabitEthernet1/0/1:

  Outer VLAN    Inner VLAN    Translated Outer VLAN    Translated Inner VLAN

  10-20         N/A           1001                     10-20

  21-30         N/A           1002                     21-30

  31-40         N/A           1003                     31-40

Interface GigabitEthernet1/0/2:

  Outer VLAN    Inner VLAN    Translated Outer VLAN    Translated Inner VLAN

  15-25         N/A           2001                     15-25

  26-35         N/A           2002                     26-35

  36-40         N/A           2003                     36-40

# Verify VLAN mapping information on PE B.

[PE_B] display vlan mapping

Interface GigabitEthernet1/0/1:

  Outer VLAN    Inner VLAN    Translated Outer VLAN    Translated Inner VLAN

  15-25         N/A           2001                     15-25

  26-35         N/A           2002                     26-35

  36-40         N/A           2003                     36-40

Interface GigabitEthernet1/0/2:

  Outer VLAN    Inner VLAN    Translated Outer VLAN    Translated Inner VLAN

  10-20         N/A           1001                     10-20

  21-30         N/A           1002                     21-30

  31-40         N/A           1003                     31-40

2.     Verify that PCs of the same customer in a CVLAN can ping each other across the service provider network. (Details not shown.)

3.     Verify that PCs of different customers in a CVLAN cannot communicate at Layer 2. The ARP tables on one customer's PCs do not contain entries for MAC addresses of the other customer's PCs. (Details not shown.)

Configuration files

IMPORTANT

IMPORTANT:

Support for the port link-mode bridge command depends on the device model.

 

·     PE A:

#

vlan 10 to 40

#

vlan 1001 to 1003

#

vlan 2001 to 2003

#

interface GigabitEthernet1/0/1

 port link-type hybrid

 undo port hybrid vlan 1

 port hybrid vlan 10 to 40 tagged

 port hybrid vlan 1001 to 1003 untagged

 vlan mapping nest range 10 to 20 nested-vlan 1001

 vlan mapping nest range 21 to 30 nested-vlan 1002

 vlan mapping nest range 31 to 40 nested-vlan 1003

 qos trust dot1p

#

interface GigabitEthernet1/0/2

 port link-type hybrid

 undo port hybrid vlan 1

 port hybrid vlan 15 to 40 tagged

 port hybrid vlan 2001 to 2003 untagged

 vlan mapping nest range 15 to 25 nested-vlan 2001

 vlan mapping nest range 26 to 35 nested-vlan 2002

 vlan mapping nest range 36 to 40 nested-vlan 2003

 qos trust dot1p

#

interface GigabitEthernet1/0/3

 port link-type trunk

 undo port trunk permit vlan 1

 port trunk permit vlan 1001 to 1003 2001 to 2003

#

·     PE B:

#

vlan 10 to 40

#

vlan 1001 to 1003

#

vlan 2001 to 2003

#

interface GigabitEthernet1/0/1

 port link-type hybrid

 undo port hybrid vlan 1

 port hybrid vlan 15 to 40 tagged

 port hybrid vlan 2001 to 2003 untagged

 vlan mapping nest range 15 to 25 nested-vlan 2001

 vlan mapping nest range 26 to 35 nested-vlan 2002

 vlan mapping nest range 36 to 40 nested-vlan 2003

 qos trust dot1p

#

interface GigabitEthernet1/0/2

 port link-type hybrid

 undo port hybrid vlan 1

 port hybrid vlan 10 to 40 tagged

 port hybrid vlan 1001 to 1003 untagged

 vlan mapping nest range 10 to 20 nested-vlan 1001

 vlan mapping nest range 21 to 30 nested-vlan 1002

 vlan mapping nest range 31 to 40 nested-vlan 1003

 qos trust dot1p

#

interface GigabitEthernet1/0/3

 port link-type trunk

 undo port trunk permit vlan 1

 port trunk permit vlan 1001 to 1003 2001 to 2003

#

Example: Configuring QoS policies for SVLAN tagging and 802.1p priority marking

Network configuration

As shown in Figure 4:

·     Customer A and Customer B each have two branches that require Layer 2 connectivity over the service provider network.

·     Both customers have three types of traffic and require different transmission priorities for the three types of traffic.

Apply a QoS policy to each customer-side port on PE A and PE B to meet the following requirements:

·     Separate the traffic by customer and traffic type.

·     Assign different 802.1p priority values to the traffic flows.

Figure 4 Network diagram

 

Table 2 shows the VLAN and 802.1p priority assignment scheme. For each customer, the service provider assigns one SVLAN by traffic type. Figure 5 shows the expected traffic transmission pattern after the QoS policies are applied to customer-side ports.

Table 2 VLAN and traffic priority assignment

Traffic type

CVLANs

SVLAN

Traffic priority

Customer A:

 

 

 

Video

31 to 40

1003

High

Voice

21 to 30

1002

Medium

Data

10 to 20

1001

Low

Customer B:

 

 

 

Storage

36 to 40

2003

High

Voice

26 to 35

2002

Medium

Data

15 to 25

2001

Low

 

Figure 5 Expected traffic pattern in the service provider network

 

Analysis

For the customer-side ports to support multiple SVLANs and send traffic to the customer site with the SVLAN tag removed, you must perform the following tasks:

1.     Configure the link type as hybrid on the customer-side ports.

2.     Assign the ports to the SVLANs as untagged VLAN members.

To change the 802.1p priority for a class of traffic, use the remark dot1p action. By default, the 802.1p priority in the SVLAN tag added by a QinQ-enabled port depends on the priority trust mode on the port.

·     If the 802.1p priority in frames is trusted, the device copies the 802.1p priority in the CVLAN tag to the SVLAN tag.

·     If port priority is trusted, the port priority is used as the 802.1p priority in the SVLAN tag. For untagged incoming frames, the port encapsulates the port priority as the 802.1p priority in the SVLAN tag.

Applicable hardware and software versions

The following matrix shows the hardware and software versions to which this configuration example is applicable:

 

Hardware

Software version

S6812 switch series

S6813 switch series

Release 66xx

S6550XE-HI switch series

Release 6008 and later

S6525XE-HI switch series

Release 6008 and later

S5850 switch series

Release 8005 and later

S5570S-EI switch series

Release 11xx

S5560X-EI switch series

Release 63xx, Release 65xx, Release 66xx

S5560X-HI switch series

Release 63xx, Release 65xx, Release 66xx

S5500V2-EI switch series

Release 63xx, Release 65xx, Release 66xx

MS4520V2-30F switch

Release 63xx, Release 65xx, Release 66xx

MS4520V2-30C switch

MS4520V2-54C switch

Release 65xx, Release 66xx

MS4520V2-28S switch

MS4520V2-24TP switch

Release 63xx

S6520X-HI switch series

S6520X-EI switch series

Release 63xx, Release 65xx, Release 66xx

S6520X-SI switch series

S6520-SI switch series

Release 63xx, Release 65xx, Release 66xx

S5000-EI switch series

Release 63xx, Release 65xx, Release 66xx

MS4600 switch series

Release 63xx, Release 65xx, Release 66xx

ES5500 switch series

Release 63xx, Release 65xx, Release 66xx

S5560S-EI switch series

S5560S-SI switch series

Not supported

S5500V3-24P-SI switch

S5500V3-48P-SI switch

Not supported

S5500V3-SI switch series (except S5500V3-24P-SI and S5500V3-48P-SI)

Release 11xx

S5170-EI switch series

Release 11xx

S5130S-HI switch series

S5130S-EI switch series

S5130S-SI switch series

S5130S-LI switch series

Not supported

S5120V2-SI switch series

S5120V2-LI switch series

Not supported

S5120V3-EI switch series

Release 11xx

S5120V3-36F-SI switch

S5120V3-28P-HPWR-SI switch

S5120V3-54P-PWR-SI switch

Release 11xx

S5120V3-SI switch series (except S5120V3-36F-SI, S5120V3-28P-HPWR-SI, and S5120V3-54P-PWR-SI)

Not supported

S5120V3-LI switch series

Not supported

S3600V3-EI switch series

Release 11xx

S3600V3-SI switch series

Release 11xx

S3100V3-EI switch series

S3100V3-SI switch series

Not supported

S5110V2 switch series

Not supported

S5110V2-SI switch series

Not supported

S5000V3-EI switch series

S5000V5-EI switch series

Not supported

S5000E-X switch series

S5000X-EI switch series

Not supported

E128C switch

E152C switch

E500C switch series

E500D switch series

Not supported

MS4320V2 switch series

MS4320V3 switch series

MS4300V2 switch series

MS4320 switch series

MS4200 switch series

Not supported

WS5850-WiNet switch series

Not supported

WS5820-WiNet switch series

WS5810-WiNet switch series

Not supported

WAS6000 switch series

Not supported

 

Restrictions and guidelines

When you configure an SVLAN tagging QoS policy, follow these restrictions and guidelines:

·     Use the nest action for SVLAN tagging. You can configure only one nest action in the traffic behavior for a traffic class.

·     You must apply the QoS policy to the inbound direction of customer-side ports.

·     If an incoming frame does not match the QoS policy, the port adds the PVID tag to the frame as the SVLAN tag.

For QinQ frames to travel across the service provider network, follow these restrictions and guidelines:

·     Set the MTU to a minimum of 1504 bytes for each port on the path of QinQ frames. This value is the sum of the default Ethernet interface MTU (1500 bytes) and the length (4 bytes) of a CVLAN tag. The CVLAN tag of QinQ frames is treated as part of the payload during transmission.

·     Configure all the ports on the forwarding path to allow frames from VLANs 1001 through 1003 and VLANs 2001 through 2003 to pass through without removing the VLAN tag.

Procedures

Configuring PE A

1.     Create SVLANs 1001 through 1003 and SVLANs 2001 through 2003.

<PE_A> system-view

[PE_A] vlan 1001 to 1003

[PE_A] vlan 2001 to 2003

2.     Configure the customer-side port GigabitEthernet 1/0/1:

# Configure the port as a hybrid port.

[PE_A] interface gigabitethernet 1/0/1

[PE_A-GigabitEthernet1/0/1] port link-type hybrid

# Remove the port from VLAN 1.

[PE_A-GigabitEthernet1/0/1] undo port hybrid vlan 1

# Assign the port to SVLANs 1001 through 1003 as an untagged VLAN member.

[PE_A-GigabitEthernet1/0/1] port hybrid vlan 1001 to 1003 untagged

# Enable QinQ on the port.

[PE_A-GigabitEthernet1/0/1] qinq enable

# Configure the port to trust the 802.1p priority of frames.

[PE_A-GigabitEthernet1/0/1] qos trust dot1p

[PE_A-GigabitEthernet1/0/1] quit

3.     Configure the customer-side port GigabitEthernet 1/0/2:

# Configure the port as a hybrid port.

[PE_A] interface gigabitethernet 1/0/2

[PE_A-GigabitEthernet1/0/2] port link-type hybrid

# Remove the port from VLAN 1.

[PE_A-GigabitEthernet1/0/2] undo port hybrid vlan 1

# Assign the port to SVLANs 2001 through 2003 as an untagged VLAN member.

[PE_A-GigabitEthernet1/0/2] port hybrid vlan 2001 to 2003 untagged

# Enable QinQ on the port.

[PE_A-GigabitEthernet1/0/2] qinq enable

# Configure the port to trust the 802.1p priority of frames.

[PE_A-GigabitEthernet1/0/2] qos trust dot1p

[PE_A-GigabitEthernet1/0/2] quit

3.     Configure the service provider-side port GigabitEthernet 1/0/3:

# Configure the port as a trunk port.

[PE_A] interface gigabitethernet 1/0/3

[PE_A-GigabitEthernet1/0/3] port link-type trunk

# Remove the port from VLAN 1.

[PE_A-GigabitEthernet1/0/3] undo port trunk permit vlan 1

# Assign the port to SVLANs 1001 through 1003 and SVLANs 2001 through 2003.

[PE_A-GigabitEthernet1/0/3] port trunk permit vlan 1001 to 1003 2001 to 2003

[PE_A-GigabitEthernet1/0/3] quit

4.     Configure QoS policies for SVLAN tagging and 802.1p priority marking:

# Create the class customer_A_pc to match traffic from CVLANs 10 through 20 (data traffic) for Customer A.

[PE_A] traffic classifier customer_A_pc

[PE_A-classifier-customer_A_pc] if-match customer-vlan-id 10 to 20

[PE_A-classifier-customer_A_pc] quit

# Create the classes customer_A_voice and customer_A_video to match Customer A's voice traffic and video traffic, respectively.

[PE_A] traffic classifier customer_A_voice

[PE_A-classifier-customer_A_voice] if-match customer-vlan-id 21 to 30

[PE_A-classifier-customer_A_voice] quit

[PE_A] traffic classifier customer_A_video

[PE_A-classifier-customer_A_video] if-match customer-vlan-id 31 to 40

[PE_A-classifier-customer_A_video] quit

# Configure SVLAN tagging and 802.1p priority marking actions for Customer A's three traffic types.

[PE_A] traffic behavior customer_A_pc

[PE_A-behavior-customer_A_pc] nest top-most vlan 1001

[PE_A-behavior-customer_A_pc] remark dot1p 3

[PE_A-behavior-customer_A_pc] quit

[PE_A] traffic behavior customer_A_voice

[PE_A-behavior-customer_A_voice] nest top-most vlan 1002

[PE_A-behavior-customer_A_voice] remark dot1p 5

[PE_A-behavior-customer_A_voice] quit

[PE_A] traffic behavior customer_A_video

[PE_A-behavior-customer_A_video] nest top-most vlan 1003

[PE_A-behavior-customer_A_video] remark dot1p 7

[PE_A-behavior-customer_A_video] quit

# Create the QoS policy customer_A for Customer A, and associate the classes with their respective behaviors in the QoS policy.

[PE_A] qos policy customer_A

[PE_A-qospolicy-customer_A] classifier customer_A_pc behavior customer_A_pc

[PE_A-qospolicy-customer_A] classifier customer_A_voice behavior customer_A_voice

[PE_A-qospolicy-customer_A] classifier customer_A_video behavior customer_A_video

[PE_A-qospolicy-customer_A] quit

# Apply the QoS policy customer_A to the inbound direction of GigabitEthernet 1/0/1.

[PE_A] interface gigabitethernet 1/0/1

[PE_A-GigabitEthernet1/0/1] qos apply policy customer_A inbound

[PE_A-GigabitEthernet1/0/1] quit

# Create traffic classes for matching Customer B's three traffic types.

[PE_A] traffic classifier customer_B_pc

[PE_A-classifier-customer_B_pc] if-match customer-vlan-id 15 to 25

[PE_A-classifier-customer_B_pc] quit

[PE_A] traffic classifier customer_B_voice

[PE_A-classifier-customer_B_voice] if-match customer-vlan-id 26 to 35

[PE_A-classifier-customer_B_voice] quit

[PE_A] traffic classifier customer_B_storage

[PE_A-classifier-customer_B_storage] if-match customer-vlan-id 36 to 40

[PE_A-classifier-customer_B_storage] quit

# Configure SVLAN tagging and 802.1p priority marking behaviors for Customer B's traffic types.

[PE_A] traffic behavior customer_B_pc

[PE_A-behavior-customer_B_pc] nest top-most vlan 2001

[PE_A-behavior-customer_B_pc] remark dot1p 3

[PE_A-behavior-customer_B_pc] quit

[PE_A] traffic behavior customer_B_voice

[PE_A-behavior-customer_B_voice] nest top-most vlan 2002

[PE_A-behavior-customer_B_voice] remark dot1p 5

[PE_A-behavior-customer_B_voice] quit

[PE_A] traffic behavior customer_B_storage

[PE_A-behavior-customer_B_storage] nest top-most vlan 2003

[PE_A-behavior-customer_B_storage] remark dot1p 7

[PE_A-behavior-customer_B_storage] quit

# Create the QoS policy customer_B for Customer B, and associate the classes with their respective behaviors in the QoS policy.

[PE_A] qos policy customer_B

[PE_A-qospolicy-customer_B] classifier customer_B_pc behavior customer_B_pc

[PE_A-qospolicy-customer_B] classifier customer_B_voice behavior customer_B_voice

[PE_A-qospolicy-customer_B] classifier customer_B_storage behavior customer_B_storage

[PE_A-qospolicy-customer_B] quit

# Apply the QoS policy customer_B to the inbound direction of GigabitEthernet 1/0/2.

[PE_A] interface gigabitethernet 1/0/2

[PE_A-GigabitEthernet1/0/2] qos apply policy customer_B inbound

[PE_A-GigabitEthernet1/0/2] quit

Configuring PE B

1.     Create SVLANs 1001 through 1003 and SVLANs 2001 through 2003.

<PE_B> system-view

[PE_B] vlan 1001 to 1003

[PE_B] vlan 2001 to 2003

2.     Configure the customer-side port GigabitEthernet 1/0/1:

# Configure the port as a hybrid port.

[PE_B] interface gigabitethernet 1/0/1

[PE_B-GigabitEthernet1/0/1] port link-type hybrid

# Remove the port from VLAN 1.

[PE_B-GigabitEthernet1/0/1] undo port hybrid vlan 1

# Assign the port to SVLANs 2001 through 2003 as an untagged VLAN member.

[PE_B-GigabitEthernet1/0/1] port hybrid vlan 2001 to 2003 untagged

# Enable QinQ on the port.

[PE_B-GigabitEthernet1/0/1] qinq enable

# Configure the port to trust the 802.1p priority of frames.

[PE_B-GigabitEthernet1/0/1] qos trust dot1p

[PE_B-GigabitEthernet1/0/1] quit

3.     Configure the customer-side port GigabitEthernet 1/0/2:

# Configure the port as a hybrid port.

[PE_B] interface gigabitethernet 1/0/2

[PE_B-GigabitEthernet1/0/2] port link-type hybrid

# Remove the port from VLAN 1.

[PE_B-GigabitEthernet1/0/2] undo port hybrid vlan 1

# Assign the port to SVLANs 1001 through 1003 as an untagged VLAN member.

[PE_B-GigabitEthernet1/0/2] port hybrid vlan 1001 to 1003 untagged

# Enable QinQ on the port.

[PE_B-GigabitEthernet1/0/2] qinq enable

# Configure the port to trust the 802.1p priority of frames.

[PE_B-GigabitEthernet1/0/2] qos trust dot1p

[PE_B-GigabitEthernet1/0/2] quit

4.     Configure the service provider-side port GigabitEthernet 1/0/3:

# Configure the port as a trunk port.

[PE_B] interface gigabitethernet 1/0/3

[PE_B-GigabitEthernet1/0/3] port link-type trunk

# Remove the port from VLAN 1.

[PE_B-GigabitEthernet1/0/3] undo port trunk permit vlan 1

# Assign the port to SVLANs 1001 through 1003 and SVLANs 2001 through 2003.

[PE_B-GigabitEthernet1/0/3] port trunk permit vlan 1001 to 1003 2001 to 2003

[PE_B-GigabitEthernet1/0/3] quit

5.     Configure QoS policies for SVLAN tagging and 802.1p priority marking:

# Create traffic classes for matching Customer A's traffic types.

[PE_B] traffic classifier customer_A_pc

[PE_B-classifier-customer_A_pc] if-match customer-vlan-id 10 to 20

[PE_B-classifier-customer_A_pc] quit

[PE_B] traffic classifier customer_A_voice

[PE_B-classifier-customer_A_voice] if-match customer-vlan-id 21 to 30

[PE_B-classifier-customer_A_voice] quit

[PE_B] traffic classifier customer_A_video

[PE_B-classifier-customer_A_video] if-match customer-vlan-id 31 to 40

[PE_B-classifier-customer_A_video] quit

# Configure SVLAN tagging and 802.1p priority marking behaviors for Customer A's three traffic types.

[PE_B] traffic behavior customer_A_pc

[PE_B-behavior-customer_A_pc] nest top-most vlan 1001

[PE_B-behavior-customer_A_pc] remark dot1p 3

[PE_B-behavior-customer_A_pc] quit

[PE_B] traffic behavior customer_A_voice

[PE_B-behavior-customer_A_voice] nest top-most vlan 1002

[PE_B-behavior-customer_A_voice] remark dot1p 5

[PE_B-behavior-customer_A_voice] quit

[PE_B] traffic behavior customer_A_video

[PE_B-behavior-customer_A_video] nest top-most vlan 1003

[PE_B-behavior-customer_A_video] remark dot1p 7

[PE_B-behavior-customer_A_video] quit

# Create the QoS policy customer_A for Customer A, and associate the classes with their respective behaviors in the QoS policy.

[PE_B] qos policy customer_A

[PE_B-qospolicy-customer_A] classifier customer_A_pc behavior customer_A_pc

[PE_B-qospolicy-customer_A] classifier customer_A_voice behavior customer_A_voice

[PE_B-qospolicy-customer_A] classifier customer_A_video behavior customer_A_video

[PE_B-qospolicy-customer_A] quit

# Apply the QoS policy customer_A to the inbound direction of GigabitEthernet 1/0/2.

[PE_B] interface gigabitethernet 1/0/2

[PE_B-GigabitEthernet1/0/2] qos apply policy customer_A inbound

[PE_B-GigabitEthernet1/0/2] quit

# Create traffic classes for matching Customer B's three traffic types.

[PE_B] traffic classifier customer_B_pc

[PE_B-classifier-customer_B_pc] if-match customer-vlan-id 15 to 25

[PE_B-classifier-customer_B_pc] quit

[PE_B] traffic classifier customer_B_voice

[PE_B-classifier-customer_B_voice] if-match customer-vlan-id 26 to 35

[PE_B-classifier-customer_B_voice] quit

[PE_B] traffic classifier customer_B_storage

[PE_B-classifier-customer_B_storage] if-match customer-vlan-id 36 to 40

[PE_B-classifier-customer_B_storage] quit

# Configure SVLAN tagging and 802.1p priority marking behaviors for Customer B's three traffic types.

[PE_B] traffic behavior customer_B_pc

[PE_B-behavior-customer_B_pc] nest top-most vlan 2001

[PE_B-behavior-customer_B_pc] remark dot1p 3

[PE_B-behavior-customer_B_pc] quit

[PE_B] traffic behavior customer_B_voice

[PE_B-behavior-customer_B_voice] nest top-most vlan 2002

[PE_B-behavior-customer_B_voice] remark dot1p 5

[PE_B-behavior-customer_B_voice] quit

[PE_B] traffic behavior customer_B_storage

[PE_B-behavior-customer_B_storage] nest top-most vlan 2003

[PE_B-behavior-customer_B_storage] remark dot1p 7

[PE_B-behavior-customer_B_storage] quit

# Create the QoS policy customer_B for Customer B, and associate the classes with their respective behaviors in the QoS policy.

[PE_B] qos policy customer_B

[PE_B-qospolicy-customer_B] classifier customer_B_pc behavior customer_B_pc

[PE_B-qospolicy-customer_B] classifier customer_B_voice behavior customer_B_voice

[PE_B-qospolicy-customer_B] classifier customer_B_storage behavior customer_B_storage

[PE_B-qospolicy-customer_B] quit

# Apply the QoS policy customer_B to the inbound direction of GigabitEthernet 1/0/1.

[PE_B] interface gigabitethernet 1/0/1

[PE_B-GigabitEthernet1/0/1] qos apply policy customer_B inbound

[PE_B-GigabitEthernet1/0/1] quit

Configuring devices between PE A and PE B

# Set the MTU to a minimum of 1504 bytes for each port on the path of QinQ frames. (Details not shown.)

# Configure all ports on the path between PE A and PE B allow frames from VLANs 1001 through 1003 and VLANs 2001 through 2003 to pass through without removing the VLAN tag. (Details not shown.)

Verifying the configuration

# Verify the configuration on each port. This example uses GigabitEthernet 1/0/1 of PE A.

[PE_A] interface gigabitethernet 1/0/1

[PE_A-GigabitEthernet1/0/1] display this

#

interface GigabitEthernet1/0/1

 port link-mode bridge

 port link-type hybrid

 undo port hybrid vlan 1

 port hybrid vlan 1001 to 1003 untagged

 qinq enable

 qos trust dot1p

 qos apply policy customer_A inbound

#

Return

[PE_A-GigabitEthernet1/0/1] quit

# Verify the QoS configuration on each port. This example uses GigabitEthernet 1/0/1 of PE A.

[PE_A] display qos policy interface gigabitethernet 1/0/1

Interface: GigabitEthernet1/0/1

 

  Direction: Inbound

 

  Policy: customer_A

   Classifier: customer_A_pc

     Operator: AND

     Rule(s) :

      If-match customer-vlan-id 10 to 20

     Behavior: customer_A_pc

      Nesting:

        Nest top-most vlan-id 1001

      Marking:

        Remark dot1p 3

   Classifier: customer_A_voice

     Operator: AND

     Rule(s) :

      If-match customer-vlan-id 21 to 30

     Behavior: customer_A_voice

      Nesting:

        Nest top-most vlan-id 1002

      Marking:

        Remark dot1p 5

   Classifier: customer_A_video

     Operator: AND

     Rule(s) :

      If-match customer-vlan-id 31 to 40

     Behavior: customer_A_video

      Nesting:

        Nest top-most vlan-id 1003

      Marking:

        Remark dot1p 7

Configuration files

IMPORTANT

IMPORTANT:

Support for the port link-mode bridge command depends on the device model.

 

·     PE A:

#

vlan 1001 to 1003

#

vlan 2001 to 2003

#

traffic classifier customer_A_pc operator and

 if-match customer-vlan-id 10 to 20

#

traffic classifier customer_A_voice operator and

 if-match customer-vlan-id 21 to 30

#

traffic classifier customer_A_video operator and

 if-match customer-vlan-id 31 to 40

#

traffic classifier customer_B_pc operator and

 if-match customer-vlan-id 15 to 25

#

traffic classifier customer_B_voice operator and

 if-match customer-vlan-id 26 to 35

#

traffic classifier customer_B_storage operator and

 if-match customer-vlan-id 36 to 40

#

traffic behavior customer_A_pc

 nest top-most vlan 1001

 remark dot1p 3

#

traffic behavior customer_A_voice

 nest top-most vlan 1002

 remark dot1p 5

#

traffic behavior customer_A_video

 nest top-most vlan 1003

 remark dot1p 7

#

traffic behavior customer_B_pc

 nest top-most vlan 2001

 remark dot1p 3

#

traffic behavior customer_B_voice

 nest top-most vlan 2002

 remark dot1p 5

#

traffic behavior customer_B_storage

 nest top-most vlan 2003

 remark dot1p 7

#

qos policy customer_A

 classifier customer_A_pc behavior customer_A_pc

 classifier customer_A_voice behavior customer_A_voice

 classifier customer_A_video behavior customer_A_video

#

qos policy customer_B

 classifier customer_B_pc behavior customer_B_pc

 classifier customer_B_voice behavior customer_B_voice

 classifier customer_B_storage behavior customer_B_storage

#

interface GigabitEthernet1/0/1

 port link-mode bridge

 port link-type hybrid

 undo port hybrid vlan 1

 port hybrid vlan 1001 to 1003 untagged

 qinq enable

 qos trust dot1p

 qos apply policy customer_A inbound

#

interface GigabitEthernet1/0/2

 port link-mode bridge

 port link-type hybrid

 undo port hybrid vlan 1

 port hybrid vlan 2001 to 2003 untagged

 qinq enable

 qos trust dot1p

 qos apply policy customer_B inbound

#

interface GigabitEthernet1/0/3

 port link-mode bridge

 port link-type trunk

 undo port trunk permit vlan 1

 port trunk permit vlan 1001 to 1003 2001 to 2003

#

·     PE B:

#

vlan 1001 to 1003

#

vlan 2001 to 2003

#

traffic classifier customer_A_pc operator and

 if-match customer-vlan-id 10 to 20

#

traffic classifier customer_A_voice operator and

 if-match customer-vlan-id 21 to 30

#

traffic classifier customer_A_video operator and

 if-match customer-vlan-id 31 to 40

#

traffic classifier customer_B_pc operator and

 if-match customer-vlan-id 15 to 25

#

traffic classifier customer_B_voice operator and

 if-match customer-vlan-id 26 to 35

#

traffic classifier customer_B_storage operator and

 if-match customer-vlan-id 36 to 40

#

traffic behavior customer_A_pc

 nest top-most vlan 1001

 remark dot1p 3

#

traffic behavior customer_A_voice

 nest top-most vlan 1002

 remark dot1p 5

#

traffic behavior customer_A_video

 nest top-most vlan 1003

 remark dot1p 7

#

traffic behavior customer_B_pc

 nest top-most vlan 2001

 remark dot1p 3

#

traffic behavior customer_B_voice

 nest top-most vlan 2002

 remark dot1p 5

#

traffic behavior customer_B_storage

 nest top-most vlan 2003

 remark dot1p 7

#

qos policy customer_A

 classifier customer_A_pc behavior customer_A_pc

 classifier customer_A_voice behavior customer_A_voice

 classifier customer_A_video behavior customer_A_video

#

qos policy customer_B

 classifier customer_B_pc behavior customer_B_pc

 classifier customer_B_voice behavior customer_B_voice

 classifier customer_B_storage behavior customer_B_storage

#

interface GigabitEthernet1/0/1

 port link-mode bridge

 port link-type hybrid

 undo port hybrid vlan 1

 port hybrid vlan 2001 to 2003 untagged

 qinq enable

 qos trust dot1p

 qos apply policy customer_B inbound

#

interface GigabitEthernet1/0/2

 port link-mode bridge

 port link-type hybrid

 undo port hybrid vlan 1

 port hybrid vlan 1001 to 1003 untagged

 qinq enable

 qos trust dot1p

 qos apply policy customer_A inbound

#

interface GigabitEthernet1/0/3

 port link-mode bridge

 port link-type trunk

 undo port trunk permit vlan 1

 port trunk permit vlan 1001 to 1003 2001 to 2003

#

Example: Configuring one-to-one VLAN mapping

Network configuration

As shown in Figure 6:

·     Each household subscribes to PC, VoD, and VoIP services, and obtains the IP address through DHCP.

·     On the home gateways, PC, VoD, and VoIP service traffic is assigned to VLANs 1, 2, and 3, respectively.

To isolate traffic of the same service type from different households, configure one-to-one VLAN mapping on the wiring-closet switches. This feature assigns one VLAN to each type of traffic from each household.

Figure 6 Network diagram

 

 

Applicable hardware and software versions

The following matrix shows the hardware and software versions to which this configuration example is applicable:

 

Hardware

Software version

S6812 switch series

S6813 switch series

Release 66xx

S6550XE-HI switch series

Release 6008 and later

S6525XE-HI switch series

Release 6008 and later

S5850 switch series

Release 8005 and later

S5570S-EI switch series

Release 11xx

S5560X-EI switch series

Release 63xx, Release 65xx, Release 66xx

S5560X-HI switch series

Release 63xx, Release 65xx, Release 66xx

S5500V2-EI switch series

Release 63xx, Release 65xx, Release 66xx

MS4520V2-30F switch

Release 63xx, Release 65xx, Release 66xx

MS4520V2-30C switch

MS4520V2-54C switch

Release 65xx, Release 66xx

MS4520V2-28S switch

MS4520V2-24TP switch

Release 63xx

S5000-EI switch series

Release 63xx, Release 65xx, Release 66xx

MS4600 switch series

Release 63xx, Release 65xx, Release 66xx

ES5500 switch series

Release 63xx, Release 65xx, Release 66xx

S5560S-EI switch series

S5560S-SI switch series

Release 63xx, Release 65xx

S5500V3-24P-SI switch

S5500V3-48P-SI switch

Release 63xx

S5500V3-SI switch series (except S5500V3-24P-SI and S5500V3-48P-SI)

Release 11xx

S5170-EI switch series

Release 11xx

S5130S-HI switch series

S5130S-EI switch series

S5130S-SI switch series

S5130S-LI switch series

Release 63xx, Release 65xx

S5120V2-SI switch series

S5120V2-LI switch series

Release 63xx

S5120V3-EI switch series

Release 11xx

S5120V3-36F-SI switch

S5120V3-28P-HPWR-SI switch

S5120V3-54P-PWR-SI switch

Release 11xx

S5120V3-SI switch series (except S5120V3-36F-SI, S5120V3-28P-HPWR-SI, and S5120V3-54P-PWR-SI)

Release 63xx

S5120V3-LI switch series

Release 63xx

S3600V3-EI switch series

Release 11xx

S3600V3-SI switch series

Release 11xx

S3100V3-EI switch series

S3100V3-SI switch series

Release 63xx

S5110V2 switch series

Release 63xx

S5110V2-SI switch series

Release 63xx

S5000V3-EI switch series

S5000V5-EI switch series

Release 63xx

S5000E-X switch series

S5000X-EI switch series

Release 63xx

E128C switch

E152C switch

E500C switch series

E500D switch series

Release 63xx

MS4320V2 switch series

MS4320V3 switch series

MS4300V2 switch series

MS4320 switch series

MS4200 switch series

Release 63xx

WS5850-WiNet switch series

Release 63xx

WS5820-WiNet switch series

WS5810-WiNet switch series

Release 63xx

WAS6000 switch series

Release 63xx

IE4300-12P-AC switch

IE4300-12P-PWR switch

IE4300-M switch series

IE4320 switch series

Release 63xx

 

Procedures

Configuring Switch A

# Create the original VLANs 2 and 3. (VLAN 1 is the system default VLAN and already exists.)

<SwitchA> system-view

[SwitchA] vlan 2 to 3

# Create the translated VLANs 101 through 102, 201 through 202, and 301 through 302.

[SwitchA] vlan 101 to 102

[SwitchA] vlan 201 to 202

[SwitchA] vlan 301 to 302

# Configure the customer-side port GigabitEthernet 1/0/1 as a trunk port.

[SwitchA] interface gigabitethernet 1/0/1

[SwitchA-GigabitEthernet1/0/1] port link-type trunk

# Assign GigabitEthernet 1/0/1 to the original VLANs and translated VLANs.

[SwitchA-GigabitEthernet1/0/1] port trunk permit vlan 1 2 3 101 201 301

# Configure one-to-one VLAN mapping on GigabitEthernet 1/0/1 to map VLANs 1, 2, and 3 to VLANs 101, 201, and 301, respectively.

[SwitchA-GigabitEthernet1/0/1] vlan mapping 1 translated-vlan 101

[SwitchA-GigabitEthernet1/0/1] vlan mapping 2 translated-vlan 201

[SwitchA-GigabitEthernet1/0/1] vlan mapping 3 translated-vlan 301

[SwitchA-GigabitEthernet1/0/1] quit

# Configure the customer-side port GigabitEthernet 1/0/2 as a trunk port.

[SwitchA] interface gigabitethernet 1/0/2

[SwitchA-GigabitEthernet1/0/2] port link-type trunk

# Assign GigabitEthernet 1/0/2 to the original VLANs and translated VLANs.

[SwitchA-GigabitEthernet1/0/2] port trunk permit vlan 1 2 3 102 202 302

# Configure one-to-one VLAN mapping on GigabitEthernet 1/0/2 to map VLANs 1, 2, and 3 to VLANs 102, 202, and 302, respectively.

[SwitchA-GigabitEthernet1/0/2] vlan mapping 1 translated-vlan 102

[SwitchA-GigabitEthernet1/0/2] vlan mapping 2 translated-vlan 202

[SwitchA-GigabitEthernet1/0/2] vlan mapping 3 translated-vlan 302

[SwitchA-GigabitEthernet1/0/2] quit

# Configure the network-side port GigabitEthernet 1/0/3 as a trunk port.

[SwitchA] interface gigabitethernet 1/0/3

[SwitchA-GigabitEthernet1/0/3] port link-type trunk

# Remove GigabitEthernet 1/0/3 from VLAN 1 and assign GigabitEthernet 1/0/3 to the translated VLANs.

[SwitchA-GigabitEthernet1/0/3] undo port trunk permit vlan 1

[SwitchA-GigabitEthernet1/0/3] port trunk permit vlan 101 201 301 102 202 302

[SwitchA-GigabitEthernet1/0/3] quit

Configuring Switch B

# Configure Switch B in the same way Switch A is configured. (Details not shown.)

Verifying the configuration

# Verify VLAN mapping information on the wiring-closet switches, for example, Switch A.

[SwitchA] display vlan mapping

Interface gigabitethernet1/0/1:

  Outer VLAN    Inner VLAN    Translated Outer VLAN    Translated Inner VLAN

  1             N/A           101                      N/A

  2             N/A           201                      N/A

  3             N/A           301                      N/A

Interface gigabitethernet1/0/2:

  Outer VLAN    Inner VLAN    Translated Outer VLAN    Translated Inner VLAN

  1             N/A           102                      N/A

  2             N/A           202                      N/A

  3             N/A           302                      N/A

Configuration files

·     Switch A:

#

vlan 1

#

vlan 2 to 3

#

vlan 101 to 102

#

vlan 201 to 202

#

vlan 301 to 302

#

interface gigabitethernet1/0/1

 port link-type trunk

 port trunk permit vlan 1 to 3 101 201 301

 vlan mapping 1 translated-vlan 101

 vlan mapping 2 translated-vlan 201

 vlan mapping 3 translated-vlan 301

#

interface gigabitethernet1/0/2

 port link-type trunk

 port trunk permit vlan 1 to 3 102 202 302

 vlan mapping 1 translated-vlan 102

 vlan mapping 2 translated-vlan 202

 vlan mapping 3 translated-vlan 302

#

interface gigabitethernet1/0/3

 port link-type trunk

 port trunk permit vlan 1 101 to 102 201 to 202 301 to 302

#

·     Switch B:

#

vlan 1

#

vlan 2 to 3

#

vlan 103 to 104

#

vlan 203 to 204

#

vlan 303 to 304

#

interface gigabitethernet1/0/1

 port link-type trunk

 port trunk permit vlan 1 to 3 103 203 303

 vlan mapping 1 translated-vlan 103

 vlan mapping 2 translated-vlan 203

 vlan mapping 3 translated-vlan 303

#

interface gigabitethernet1/0/2

 port link-type trunk

 port trunk permit vlan 1 to 3 104 204 304

 vlan mapping 1 translated-vlan 104

 vlan mapping 2 translated-vlan 204

 vlan mapping 3 translated-vlan 304

#

interface gigabitethernet1/0/3

 port link-type trunk

 port trunk permit vlan 1 103 to 104 203 to 204 303 to 304

#

Example: Configuring many-to-one VLAN mapping

Network configuration

As shown in Figure 7:

·     Create VLAN 2, VLAN 3, and VLAN 4 on the wiring-closet switches to isolate traffic of the same service type from different households.

·     Configure many-to-one VLAN mappings on the campus switch. This feature assigns the same type of traffic from different households to one VLAN.

Figure 7 Network diagram

 

Applicable hardware and software versions

The following matrix shows the hardware and software versions to which this configuration example is applicable:

 

Hardware

Software version

S6812 switch series

S6813 switch series

Release 66xx

S6550XE-HI switch series

Release 6008 and later

S6525XE-HI switch series

Release 6008 and later

S5850 switch series

Release 8005 and later

S5570S-EI switch series

Release 11xx

S5560X-EI switch series

Release 65xx, Release 66xx

S5560X-HI switch series

Release 65xx, Release 66xx

S5500V2-EI switch series

Release 65xx, Release 66xx

MS4520V2-30F switch

Release 65xx, Release 66xx

MS4520V2-30C switch

MS4520V2-54C switch

Release 65xx, Release 66xx

MS4520V2-28S switch

MS4520V2-24TP switch

Not supported

S6520X-HI switch series

S6520X-EI switch series

Release 65xx, Release 66xx

S6520X-SI switch series

S6520-SI switch series

Release 65xx, Release 66xx

S5000-EI switch series

Release 65xx, Release 66xx

MS4600 switch series

Release 65xx, Release 66xx

ES5500 switch series

Release 65xx, Release 66xx

S5560S-EI switch series

S5560S-SI switch series

Not supported

S5500V3-24P-SI switch

S5500V3-48P-SI switch

Not supported

S5500V3-SI switch series (except S5500V3-24P-SI and S5500V3-48P-SI)

Release 11xx

S5170-EI switch series

Release 11xx

S5130S-HI switch series

S5130S-EI switch series

S5130S-SI switch series

S5130S-LI switch series

Not supported

S5120V2-SI switch series

S5120V2-LI switch series

Not supported

S5120V3-EI switch series

Release 11xx

S5120V3-36F-SI switch

S5120V3-28P-HPWR-SI switch

S5120V3-54P-PWR-SI switch

Release 11xx

S5120V3-SI switch series (except S5120V3-36F-SI, S5120V3-28P-HPWR-SI, and S5120V3-54P-PWR-SI)

Not supported

S5120V3-LI switch series

Not supported

S3600V3-EI switch series

Release 11xx

S3600V3-SI switch series

Release 11xx

S3100V3-EI switch series

S3100V3-SI switch series

Not supported

S5110V2 switch series

Not supported

S5110V2-SI switch series

Not supported

S5000V3-EI switch series

Not supported

S5000E-X switch series

S5000X-EI switch series

Not supported

E128C switch

E152C switch

E500C switch series

E500D switch series

Not supported

MS4320V2 switch series

MS4320V3 switch series

MS4300V2 switch series

MS4320 switch series

MS4200 switch series

Not supported

WS5850-WiNet switch series

Not supported

WS5820-WiNet switch series

WS5810-WiNet switch series

Not supported

WAS6000 switch series

Not supported

IE4300-12P-AC switch

IE4300-12P-PWR switch

IE4300-M switch series

IE4320 switch series

Not supported

 

Procedures

Configuring Switch A

# Create VLAN 2 as an original VLAN.

<SwitchA> system-view

[SwitchA] vlan 2

# Assign GigabitEthernet 1/0/1 and GigabitEthernet 1/0/2 to VLAN 2.

[SwitchA] interface range gigabitethernet 1/0/1 to gigabitethernet 1/0/2

[SwitchA-if-range] port access vlan 2

Configuring Switch B and Switch C

Configure Switch B and Switch C in the same way Switch A is configured. (Details not shown.)

Configuring Switch D

# Create VLANs 2, 3, and 4 as original VLANs.

[SwitchD] vlan 2 to 4

# Assign GigabitEthernet 1/0/1 to VLAN 2, GigabitEthernet 1/0/2 to VLAN 3, and GigabitEthernet 1/0/3 to VLAN 4.

[SwitchD] interface ten-gigabitethernet 1/0/1

[SwitchD-GigabitEthernet1/0/1] port access vlan 2

[SwitchD-GigabitEthernet1/0/1] quit

[SwitchD] interface ten-gigabitethernet 1/0/2

[SwitchD-GigabitEthernet1/0/2] port access vlan 3

[SwitchD-GigabitEthernet1/0/2] quit

[SwitchD] interface ten-gigabitethernet 1/0/3

[SwitchD-GigabitEthernet1/0/3] port access vlan 4

[SwitchD-GigabitEthernet1/0/3] quit

# Configure GigabitEthernet 1/0/4 as a trunk port and assign it to the original VLANs.

[SwitchD] interface ten-gigabitethernet 1/0/4

[SwitchD-GigabitEthernet1/0/4] port link-type trunk

[SwitchD-GigabitEthernet1/0/4] port trunk permit vlan 2 to 4

Configuring Switch E

# Configure the customer-side port (GigabitEthernet 1/0/1) as a trunk port, and assign it to the original VLANs.

[SwitchE] interface gigabitethernet 1/0/1

[SwitchE-GigabitEthernet1/0/1] port link-type trunk

[SwitchE-GigabitEthernet1/0/1] port trunk permit vlan 2 to 4

# Configure many-to-one VLAN mapping on GigabitEthernet 1/0/1, which replaces VLAN tag 2 through VLAN tag 4 with VLAN tag 10.

[SwitchE-GigabitEthernet1/0/1] vlan mapping uni range 2 to 4 translated-vlan 10

Verifying the configuration

# Verify VLAN mapping information on Switch E.

[SwitchE] display vlan mapping

Interface GigabitEthernet1/0/1:

  Outer VLAN    Inner VLAN    Translated Outer VLAN    Translated Inner VLAN

  2-4           N/A           10                       N/A

Configuration files

·     Switch A:

#

vlan 1

#

vlan 2

#

interface GigabitEthernet1/0/1

 port link-mode bridge

 port access vlan 2

#

interface GigabitEthernet1/0/2

 port link-mode bridge

 port access vlan 2

#

·     Switch B:

#

vlan 1

#

vlan 3

#

interface GigabitEthernet1/0/1

 port link-mode bridge

 port access vlan 3

#

interface GigabitEthernet1/0/2

 port link-mode bridge

 port access vlan 3

#

·     Switch C:

#

vlan 1

#

vlan 4

#

interface GigabitEthernet1/0/1

 port link-mode bridge

 port access vlan 4

#

interface GigabitEthernet1/0/2

 port link-mode bridge

 port access vlan 4

#

·     Switch D:

#

vlan 1

#

vlan 2 to 4

#

interface GigabitEthernet1/0/1

 port link-mode bridge

 port access vlan 2

#

interface GigabitEthernet1/0/2

 port link-mode bridge

 port access vlan 3

#

interface GigabitEthernet1/0/3

 port link-mode bridge

 port access vlan 4

#

interface GigabitEthernet1/0/4

 port link-mode bridge

 port link-type trunk

 port trunk permit vlan 1 to 4

#

·     Switch E:

#

vlan 1

#

vlan 2 to 4

#

interface GigabitEthernet1/0/1

 port link-mode bridge

 port link-type trunk

 port trunk permit vlan 1 to 4

 vlan mapping uni range 2 to 4 translated-vlan 10

#

Example: Configuring two-to-two VLAN mapping

Network configuration

As shown in Figure 8:

·     A company assigns its branch sites (Site 1 and Site 2) to VLAN 10, and the headquarters provides services in VLAN 30.

·     Service provider A uses SVLAN 100 to transmit VLAN 10 traffic for the branch sites.

·     Service provider B uses SVLAN 200 to transmit VLAN 30 traffic for the headquarters.

Configure two-to-two VLAN mapping to permit the two branch sites to access VLAN 30 of the headquarters without changing their VLAN assignment.

Figure 8 Network diagram

 

Applicable hardware and software versions

The following matrix shows the hardware and software versions to which this configuration example is applicable:

 

Hardware

Software version

S6812 switch series

S6813 switch series

Release 66xx

S6550XE-HI switch series

Release 6008 and later

S6525XE-HI switch series

Release 6008 and later

S5850 switch series

Release 8005 and later

S5570S-EI switch series

Release 11xx

S5560X-EI switch series

Release 63xx, Release 65xx, Release 66xx

S5560X-HI switch series

Release 63xx, Release 65xx, Release 66xx

S5500V2-EI switch series

Release 63xx, Release 65xx, Release 66xx

MS4520V2-30F switch

Release 63xx, Release 65xx, Release 66xx

MS4520V2-30C switch

MS4520V2-54C switch

Release 65xx, Release 66xx

MS4520V2-28S switch

MS4520V2-24TP switch

Release 63xx

S6520X-HI switch series

S6520X-EI switch series

Release 63xx, Release 65xx, Release 66xx

S6520X-SI switch series

S6520-SI switch series

Release 63xx, Release 65xx, Release 66xx

S5000-EI switch series

Release 63xx, Release 65xx, Release 66xx

MS4600 switch series

Release 63xx, Release 65xx, Release 66xx

ES5500 switch series

Release 63xx, Release 65xx, Release 66xx

S5560S-EI switch series

S5560S-SI switch series

Not supported

S5500V3-24P-SI switch

S5500V3-48P-SI switch

Not supported

S5500V3-SI switch series (except S5500V3-24P-SI and S5500V3-48P-SI)

Release 11xx

S5170-EI switch series

Release 11xx

S5130S-HI switch series

S5130S-EI switch series

S5130S-SI switch series

S5130S-LI switch series

Not supported

S5120V2-SI switch series

S5120V2-LI switch series

Not supported

S5120V3-EI switch series

Release 11xx

S5120V3-36F-SI switch

S5120V3-28P-HPWR-SI switch

S5120V3-54P-PWR-SI switch

Release 11xx

S5120V3-SI switch series (except S5120V3-36F-SI, S5120V3-28P-HPWR-SI, and S5120V3-54P-PWR-SI)

Not supported

S5120V3-LI switch series

Not supported

S3600V3-EI switch series

Release 11xx

S3600V3-SI switch series

Release 11xx

S3100V3-EI switch series

S3100V3-SI switch series

Not supported

S5110V2 switch series

Not supported

S5110V2-SI switch series

Not supported

S5000V3-EI switch series

S5000V5-EI switch series

Not supported

S5000E-X switch series

S5000X-EI switch series

Not supported

E128C switch

E152C switch

E500C switch series

E500D switch series

Not supported

MS4320V2 switch series

MS4320V3 switch series

MS4300V2 switch series

MS4320 switch series

MS4200 switch series

Not supported

WS5850-WiNet switch series

Not supported

WS5820-WiNet switch series

WS5810-WiNet switch series

Not supported

WAS6000 switch series

Not supported

IE4300-12P-AC switch

IE4300-12P-PWR switch

IE4300-M switch series

IE4320 switch series

Not supported

 

Restrictions and guidelines

Configure two-to-two VLAN mapping on one of the edge devices between the two service provider networks. This example uses Switch C.

Procedures

Configuring Switch A

# Create CVLAN 10 and SVLAN 100.

<SwitchA> system-view

[SwitchA] vlan 10

[SwitchA-vlan10] quit

[SwitchA] vlan 100

[SwitchA-vlan100] quit

# Configure a one-to-two VLAN mapping on the customer-side port (GigabitEthernet 1/0/1) to add SVLAN tag 100 to packets from VLAN 10.

[SwitchA] interface gigabitethernet 1/0/1

[SwitchA-GigabitEthernet1/0/1] vlan mapping nest single 10 nested-vlan 100

# Configure GigabitEthernet 1/0/1 as a hybrid port.

[SwitchA-GigabitEthernet1/0/1] port link-type hybrid

# Assign GigabitEthernet 1/0/1 to VLAN 10 as a tagged member.

[SwitchA-GigabitEthernet1/0/1] port hybrid vlan 10 tagged

# Assign GigabitEthernet 1/0/1 to VLAN 100 as an untagged member.

[SwitchA-GigabitEthernet1/0/1] port hybrid vlan 100 untagged

# Remove GigabitEthernet 1/0/1 from VLAN 1.

[SwitchA-GigabitEthernet1/0/1] undo port hybrid vlan 1

[SwitchA-GigabitEthernet1/0/1] quit

# Configure the network-side port GigabitEthernet 1/0/2 as a trunk port.

[SwitchA] interface gigabitethernet 1/0/2

[SwitchA-GigabitEthernet1/0/2] port link-type trunk

# Assign GigabitEthernet 1/0/2 to VLAN 100.

[SwitchA-GigabitEthernet1/0/2] port trunk permit vlan 100

# Remove GigabitEthernet 1/0/2 from VLAN 1.

[SwitchA-GigabitEthernet1/0/2] undo port trunk permit vlan 1

[SwitchA-GigabitEthernet1/0/2] quit

Configuring Switch B

# Create CVLAN 10 and SVLAN 100.

<SwitchB> system-view

[SwitchB] vlan 10

[SwitchB-vlan10] quit

[SwitchB] vlan 100

[SwitchB-vlan100] quit

# Configure a one-to-two VLAN mapping on the customer-side port (GigabitEthernet 1/0/3) to add SVLAN tag 100 to packets from VLAN 10.

[SwitchB] interface gigabitethernet 1/0/3

[SwitchB-GigabitEthernet1/0/3] vlan mapping nest single 10 nested-vlan 100

# Configure GigabitEthernet 1/0/3 as a hybrid port.

[SwitchB] interface gigabitethernet 1/0/3

[SwitchB-GigabitEthernet1/0/3] port link-type hybrid

# Assign GigabitEthernet 1/0/3 to VLAN 10 as a tagged member.

[SwitchB-GigabitEthernet1/0/3] port hybrid vlan 10 tagged

# Assign GigabitEthernet 1/0/3 to VLAN 100 as an untagged member.

[SwitchB-GigabitEthernet1/0/3] port hybrid vlan 100 untagged

# Remove GigabitEthernet 1/0/3 from VLAN 1.

[SwitchB-GigabitEthernet1/0/3] undo port hybrid vlan 1

[SwitchB-GigabitEthernet1/0/3] quit

# Configure GigabitEthernet 1/0/1 as a trunk port.

[SwitchB] interface gigabitethernet 1/0/1

[SwitchB-GigabitEthernet1/0/1] port link-type trunk

# Assign GigabitEthernet 1/0/1 to VLAN 100.

[SwitchB-GigabitEthernet1/0/1] port trunk permit vlan 100

# Remove GigabitEthernet 1/0/1 from VLAN 1.

[SwitchB-GigabitEthernet1/0/1] undo port trunk permit vlan 1

[SwitchB-GigabitEthernet1/0/1] quit

# Configure GigabitEthernet 1/0/2 as a trunk port.

[SwitchB] interface gigabitethernet 1/0/2

[SwitchB-GigabitEthernet1/0/2] port link-type trunk

# Assign GigabitEthernet 1/0/2 to VLAN 100.

[SwitchB-GigabitEthernet1/0/2] port trunk permit vlan 100

# Remove GigabitEthernet 1/0/2 from VLAN 1.

[SwitchB-GigabitEthernet1/0/2] undo port trunk permit vlan 1

[SwitchB-GigabitEthernet1/0/2] quit

Configuring Switch C

# Create SVLANs 100 and 200.

<SwitchC> system-view

[SwitchC] vlan 100

[SwitchC-vlan100] quit

[SwitchC] vlan 200

[SwitchC-vlan200] quit

# Configure GigabitEthernet 1/0/1 as a trunk port.

[SwitchC] interface gigabitethernet 1/0/1

[SwitchC-GigabitEthernet1/0/1] port link-type trunk

# Assign GigabitEthernet 1/0/1 to VLANs 100 to 200.

[SwitchC-GigabitEthernet1/0/1] port trunk permit vlan 100 200

# Remove GigabitEthernet 1/0/1 from VLAN 1.

[SwitchC-GigabitEthernet1/0/1] undo port trunk permit vlan 1

# Configure a two-to-two VLAN mapping on GigabitEthernet 1/0/1 to map SVLAN 100 and CVLAN 10 to SVLAN 200 and CVLAN 30.

[SwitchC-GigabitEthernet1/0/1] vlan mapping tunnel 100 10 translated-vlan 200 30

[SwitchC-GigabitEthernet1/0/1] quit

# Configure GigabitEthernet 1/0/2 as a trunk port.

[SwitchC] interface gigabitethernet 1/0/2

[SwitchC-GigabitEthernet1/0/2] port link-type trunk

# Assign GigabitEthernet 1/0/2 to VLAN 200.

[SwitchC-GigabitEthernet1/0/2] port trunk permit vlan 200

# Remove GigabitEthernet 1/0/2 from VLAN 1.

[SwitchC-GigabitEthernet1/0/2] undo port trunk permit vlan 1

[SwitchC-GigabitEthernet1/0/2] quit

Configuring Switch D

# Create CVLAN 30 and SVLAN 200.

<SwitchD> system-view

[SwitchD] vlan 30

[SwitchD-vlan30] quit

[SwitchD] vlan 200

[SwitchD-vlan200] quit

# Configure the link type of GigabitEthernet 1/0/1 as trunk.

[SwitchD] interface gigabitethernet 1/0/1

[SwitchD-GigabitEthernet1/0/1] port link-type trunk

# Assign GigabitEthernet 1/0/1 to VLAN 200.

[SwitchD-GigabitEthernet1/0/1] port trunk permit vlan 200

# Remove GigabitEthernet 1/0/1 from VLAN 1.

[SwitchD-GigabitEthernet1/0/1] undo port trunk permit vlan 1

[SwitchD-GigabitEthernet1/0/1] quit

# Configure GigabitEthernet 1/0/2 as a hybrid port.

[SwitchD] interface gigabitethernet 1/0/2

[SwitchD-GigabitEthernet1/0/2] port link-type hybrid

# Assign GigabitEthernet 1/0/2 to VLAN 30 as a tagged member.

[SwitchD-GigabitEthernet1/0/2] port hybrid vlan 30 tagged

# Assign GigabitEthernet 1/0/2 to VLAN 200 as an untagged member.

[SwitchD-GigabitEthernet1/0/2] port hybrid vlan 200 untagged

# Remove GigabitEthernet 1/0/2 from VLAN 1.

[SwitchD-GigabitEthernet1/0/2] undo port hybrid vlan 1

[SwitchD-GigabitEthernet1/0/2] quit

# Configure a one-to-two VLAN mapping on the customer-side port (GigabitEthernet 1/0/2) to add SVLAN tag 200 to packets from VLAN 30.

[SwitchD] interface gigabitethernet 1/0/2

[SwitchD-GigabitEthernet1/0/2] vlan mapping nest single 30 nested-vlan 200

[SwitchD-GigabitEthernet1/0/2] quit

Verifying the configuration

# Verify VLAN mapping information on Switch C.

[SwitchC] display vlan mapping

Interface GigabitEthernet1/0/1:

  Outer VLAN    Inner VLAN    Translated Outer VLAN    Translated Inner VLAN

  100           10            200                      30

Configuration files

IMPORTANT

IMPORTANT:

Support for the port link-mode bridge command depends on the device model.

 

·     Switch A:

#

vlan 10

vlan 100

#

interface GigabitEthernet1/0/1

 port link-type hybrid

 port hybrid vlan 10 tagged

 port hybrid vlan 100 untagged

 vlan mapping nest single 10 nested-vlan 100

#

interface GigabitEthernet1/0/2

 port link-type trunk

 undo port trunk permit vlan 1

 port trunk permit vlan 100

·     Switch B:

#

vlan 10

vlan 100

#

interface GigabitEthernet1/0/1

 port link-type trunk

 undo port trunk permit vlan 1

 port trunk permit vlan 100

#

interface GigabitEthernet1/0/2

 port link-type trunk

 undo port trunk permit vlan 1

 port trunk permit vlan 100

#

interface GigabitEthernet1/0/3

 port link-type hybrid

 port hybrid vlan 10 tagged

 port hybrid vlan 100 untagged

 vlan mapping nest single 10 nested-vlan 100

·     Switch C:

#

vlan 100

#

vlan 200

#

interface GigabitEthernet1/0/1

 port link-type trunk

 undo port trunk permit vlan 1

 port trunk permit vlan 100 200

 vlan mapping tunnel 100 10 translated-vlan 200 30

#

interface GigabitEthernet1/0/2

 port link-type trunk

 undo port trunk permit vlan 1

 port trunk permit vlan 200

#

·     Switch D:

#

vlan 30

vlan 200

#

interface GigabitEthernet1/0/1

 port link-type trunk

 undo port trunk permit vlan 1

 port trunk permit vlan 200

#

interface GigabitEthernet1/0/2

 port link-type hybrid

 port hybrid vlan 30 tagged

 port hybrid vlan 200 untagged

 vlan mapping nest single 30 nested-vlan 200

#

Example: Modifying the CVLAN ID through QoS marking

Network configuration

As shown in Figure 9:

·     Company A uses CVLANs 10 and 20 to transmit voice traffic and data traffic, respectively.

·     Company B uses CVLANs 30 and 40 to transmit voice traffic and data traffic, respectively.

·     The service provider uses SVLANs 100 and 200 to transmit these two companies' voice and data traffic, respectively.

To provide Layer 2 connectivity for the voice and data traffic between the two companies, configure QoS CVLAN marking on PE A and PE B.

Figure 9 Network diagram

 

Analysis

To meet the network requirements, you must perform the following tasks:

·     To add different SVLAN tags to voice and data traffic, use the nest action for SVLAN tagging on the customer-side ports of PE A and PE B.

·     To provide Layer 2 connectivity for the traffic from different CVLANs, configure QoS CVLAN marking on the service provider-side ports of PE A and PE B.

Applicable hardware and software versions

The following matrix shows the hardware and software versions to which this configuration example is applicable:

 

Hardware

Software version

S6812 switch series

S6813 switch series

Release 66xx

S6550XE-HI switch series

Release 6008 and later

S6525XE-HI switch series

Release 6008 and later

S5850 switch series

Release 8005 and later

S5570S-EI switch series

Release 11xx

S5560X-EI switch series

Not supported

S5560X-HI switch series

Release 63xx, Release 65xx, Release 66xx

S5500V2-EI switch series

Not supported

S6520X-HI switch series

S6520X-EI switch series

Release 63xx, Release 65xx, Release 66xx

S6520X-SI switch series

S6520-SI switch series

Release 63xx, Release 65xx, Release 66xx

S5000-EI switch series

Release 63xx, Release 65xx, Release 66xx

MS4600 switch series

Release 63xx, Release 65xx, Release 66xx

ES5500 switch series

Release 63xx, Release 65xx, Release 66xx

S5560S-EI switch series

S5560S-SI switch series

Not supported

S5500V3-24P-SI switch

S5500V3-48P-SI switch

Not supported

S5500V3-SI switch series (except S5500V3-24P-SI and S5500V3-48P-SI)

Release 11xx

S5170-EI switch series

Release 11xx

S5130S-HI switch series

S5130S-EI switch series

S5130S-SI switch series

S5130S-LI switch series

Not supported

S5120V2-SI switch series

S5120V2-LI switch series

Not supported

S5120V3-EI switch series

Release 11xx

S5120V3-36F-SI switch

S5120V3-28P-HPWR-SI switch

S5120V3-54P-PWR-SI switch

Release 11xx

S5120V3-SI switch series (except S5120V3-36F-SI, S5120V3-28P-HPWR-SI, and S5120V3-54P-PWR-SI)

Not supported

S5120V3-LI switch series

Not supported

S3600V3-EI switch series

Release 11xx

S3600V3-SI switch series

Release 11xx

S3100V3-EI switch series

S3100V3-SI switch series

Not supported

S5110V2 switch series

Not supported

S5110V2-SI switch series

Not supported

S5000V3-EI switch series

S5000V5-EI switch series

Not supported

S5000E-X switch series

S5000X-EI switch series

Not supported

E128C switch

E152C switch

E500C switch series

E500D switch series

Not supported

MS4520V2 switch series

Not supported

MS4320V2 switch series

MS4320V3 switch series

MS4300V2 switch series

MS4320 switch series

MS4200 switch series

Not supported

WS5850-WiNet switch series

Not supported

WS5820-WiNet switch series

WS5810-WiNet switch series

Not supported

WAS6000 switch series

Not supported

IE4300-12P-AC switch

IE4300-12P-PWR switch

IE4300-M switch series

IE4320 switch series

Not supported

 

Procedures

Configuring PE A

1.     Create the CVLANs and SVLANs.

<PE_A> system-view

[PE_A] vlan 10

[PE_A-vlan10] quit

[PE_A] vlan 20

[PE_A-vlan20] quit

[PE_A] vlan 100

[PE_A-vlan100] quit

[PE_A] vlan 200

[PE_A-vlan200] quit

[PE_A] vlan 30

[PE_A-vlan30] quit

[PE_A] vlan 40

[PE_A-vlan40] quit

2.     Configure the customer-side port GigabitEthernet1/0/1:

# Configure the port as a hybrid port.

[PE_A] interface gigabitethernet 1/0/1

[PE_A-GigabitEthernet1/0/1] port link-type hybrid

# Configure the port as an untagged VLAN member of VLANs 100 and 200.

[PE_A-GigabitEthernet1/0/1] port hybrid vlan 100 200 untagged

# Remove the port from VLAN 1.

[PE_A-GigabitEthernet1/0/1] undo port hybrid vlan 1

[PE_A-GigabitEthernet1/0/1] quit

# Create the class A10 to match frames with CVLAN 10.

[PE_A] traffic classifier A10

[PE_A-classifier-A10] if-match customer-vlan-id 10

[PE_A-classifier-A10] quit

# Configure the traffic behavior P100 to tag packets with SVLAN 100.

[PE_A] traffic behavior P100

[PE_A-behavior-P100] nest top-most vlan 100

[PE_A-behavior-P100] quit

# Create the class A20 to match frames with CVLAN 20.

[PE_A] traffic classifier A20

[PE_A-classifier-A20] if-match customer-vlan-id 20

[PE_A-classifier-A20] quit

# Configure the traffic behavior P200 to tag packets with SVLAN 200.

[PE_A] traffic behavior P200

[PE_A-behavior-P200] nest top-most vlan 200

[PE_A-behavior-P200] quit

# Create the QoS policy qinq to associate the traffic classes A10 and A20 with the traffic behaviors P100 and P200, respectively.

[PE_A] qos policy qinq

[PE_A-qospolicy-qinq] classifier A10 behavior P100

[PE_A-qospolicy-qinq] classifier A20 behavior P200

[PE_A-qospolicy-qinq] quit

# Enable QinQ in the port.

[PE_A-GigabitEthernet1/0/1] qinq enable

# Apply the QoS policy to the inbound direction of the port.

[PE_A-GigabitEthernet1/0/1] qos apply policy qinq inbound

[PE_A-GigabitEthernet1/0/1] quit

3.     Configure the service network-side port GigabitEthernet1/0/2:

# Configure the port as a trunk port.

[PE_A] interface gigabitethernet 1/0/2

[PE_A-GigabitEthernet1/0/2] port link-type trunk

# Assign the port to VLANs 100 and 200.

[PE_A-GigabitEthernet1/0/2] port trunk permit vlan 100 200

# Remove the port from VLAN 1.

[PE_A-GigabitEthernet1/0/2] undo port trunk permit vlan 1

[PE_A-GigabitEthernet1/0/2] quit

# Create the class A100 to match frames with CVLAN 10 and SVLAN 100.

[PE_A] traffic classifier A100

[PE_A-classifier-A100] if-match customer-vlan-id 10

[PE_A-classifier-A100] if-match service-vlan-id 100

[PE_A-classifier-A100] quit

# Configure the traffic behavior T100 to mark matching traffic with CVLAN 30.

[PE_A] traffic behavior T100

[PE_A-behavior-T100] remark customer-vlan-id 30

[PE_A-behavior-T100] quit

# Create the class A200 to match frames with CVLAN 20 and SVLAN 200.

[PE_A] traffic classifier A200

[PE_A-classifier-A200] if-match customer-vlan-id 20

[PE_A-classifier-A200] if-match service-vlan-id 200

[PE_A-classifier-A200] quit

# Configure the traffic behavior T200 to mark matching traffic with CVLAN 40.

[PE_A] traffic behavior T200

[PE_A-behavior-T200] remark customer-vlan-id 40

[PE_A-behavior-T200] quit

# Create the QoS policy vlanmapping to associate the traffic classes A100 and A200 with the traffic behaviors T100 and T200, respectively.

[PE_A] qos policy vlanmapping

[PE_A-qospolicy-vlanmapping] classifier A100 behavior T100

[PE_A-qospolicy-vlanmapping] classifier A200 behavior T200

[PE_A-qospolicy-vlanmapping] quit

# Apply the QoS policy to the outbound direction of the port.

[PE_A-GigabitEthernet1/0/2] qos apply policy vlanmapping outbound

[PE_A-GigabitEthernet1/0/2] quit

Configuring PE B

1.     Create the CVLANs and SVLANs.

<PE_B> system-view

[PE_B] vlan 30

[PE_B-vlan30] quit

[PE_B] vlan 40

[PE_B-vlan40] quit

[PE_B] vlan 100

[PE_B-vlan100] quit

[PE_B] vlan 200

[PE_B-vlan200] quit

[PE_B] vlan 10

[PE_B-vlan10] quit

[PE_B] vlan 20

[PE_B-vlan20] quit

2.     Configure the customer-side port GigabitEthernet1/0/1:

# Configure the port as a hybrid port.

[PE_B] interface gigabitethernet 1/0/1

[PE_B-GigabitEthernet1/0/1] port link-type hybrid

# Assign the port to VLANs 100 and 200 as an untagged VLAN member.

[PE_B-GigabitEthernet1/0/1] port hybrid vlan 100 200 untagged

# Remove the port from VLAN 1.

[PE_B-GigabitEthernet1/0/1] undo port hybrid vlan 1

[PE_B-GigabitEthernet1/0/1] quit

# Create the class A30 to match frames with CVLAN 30.

[PE_B] traffic classifier A30

[PE_B-classifier-A30] if-match customer-vlan-id 30

[PE_B-classifier-A30] quit

# Configure the traffic behavior P100 to tag packets with SVLAN 100.

[PE_B] traffic behavior P100

[PE_B-behavior-P100] nest top-most vlan 100

[PE_B-behavior-P100] quit

# Create the class A40 to match frames with CVLAN 40.

[PE_B] traffic classifier A40

[PE_B-classifier-A40] if-match customer-vlan-id 40

[PE_B-classifier-A40] quit

# Configure the traffic behavior P200 to tag packets with SVLAN 200.

[PE_B] traffic behavior P200

[PE_B-behavior-P200] nest top-most vlan 200

[PE_B-behavior-P200] quit

# Create the QoS policy qinq to associate the traffic classes A30 and A40 with the traffic behaviors P100 and P200, respectively.

[PE_B] qos policy qinq

[PE_B-qospolicy-qinq] classifier A30 behavior P100

[PE_B-qospolicy-qinq] classifier A40 behavior P200

[PE_B-qospolicy-qinq] quit

# Enable QinQ on the port.

[PE_B-GigabitEthernet1/0/1] qinq enable

# Apply the QoS policy to the inbound direction of the port.

[PE_B-GigabitEthernet1/0/1] qos apply policy qinq inbound

[PE_B-GigabitEthernet1/0/1] quit

3.     Configure the service provider-side port GigabitEthernet 1/0/2:

# Configure the port as a trunk port.

[PE_B] interface gigabitethernet 1/0/2

[PE_B-GigabitEthernet1/0/2] port link-type trunk

# Assign the port to VLANs 100 and 200.

[PE_B-GigabitEthernet1/0/2] port trunk permit vlan 100 200

# Remove the port from VLAN 1.

[PE_B-GigabitEthernet1/0/2] undo port trunk permit vlan 1

[PE_B-GigabitEthernet1/0/2] quit

# Create the class A100 to match frames with CVLAN 30 and SVLAN 100.

[PE_B] traffic classifier A100

[PE_B-classifier-A100] if-match customer-vlan-id 30

[PE_B-classifier-A100] if-match service-vlan-id 100

[PE_B-classifier-A100] quit

# Configure the traffic behavior T100 to mark matching traffic with CVLAN 10.

[PE_B] traffic behavior T100

[PE_B-behavior-T100] remark customer-vlan-id 10

[PE_B-behavior-T100] quit

# Create the class A200 to match frames with CVLAN 40 and SVLAN 200.

[PE_B] traffic classifier A200

[PE_B-classifier-A200] if-match customer-vlan-id 40

[PE_B-classifier-A200] if-match service-vlan-id 200

[PE_B-classifier-A200] quit

# Configure the traffic behavior T200 to mark matching traffic with CVLAN 20.

[PE_B] traffic behavior T200

[PE_B-behavior-T200] remark customer-vlan-id 20

[PE_B-behavior-T200] quit

# Create the QoS policy vlanmapping to associate the traffic classes A100 and A200 with the traffic behaviors T100 and T200, respectively.

[PE_B] qos policy vlanmapping

[PE_B-qospolicy-vlanmapping] classifier A100 behavior T100

[PE_B-qospolicy-vlanmapping] classifier A200 behavior T200

[PE_B-qospolicy-vlanmapping] quit

# Apply the QoS policy to the outbound direction of the port.

[PE_B] interface gigabitethernet 1/0/2

[PE_B-GigabitEthernet1/0/2] qos apply policy vlanmapping outbound

[PE_B-GigabitEthernet1/0/2] quit

Configuring devices between PE A and PE B

# Set the MTU to a minimum of 1504 bytes for each port on the path of double-tagged frames. (Details not shown.)

# Configure the ports between PE A and PE B to allow frames from VLANs 100 and 200 to pass through tagged. (Details not shown.)

Verifying the configuration

# Verify configuration on the customer-side ports on PE A and PE B. This example uses GigabitEthernet 1/0/1 of PE A.

[PE_A] interface gigabitethernet 1/0/1

[PE_A-GigabitEthernet1/0/1] display this

#

interface GigabitEthernet1/0/1

 port link-mode bridge

 port link-type hybrid

 undo port hybrid vlan 1

 port hybrid vlan 100 200 untagged

 qinq enable

 qos apply policy qinq inbound

#

return

# Verify the QoS nesting configuration on the customer-side ports on PE A and PE B. This example uses GigabitEthernet 1/0/1 of PE A.

[PE_A] display qos policy interface gigabitethernet 1/0/1

 

Interface: GigabitEthernet1/0/1

 

  Direction: Inbound

 

  Policy: qinq

   Classifier: A10

     Operator: AND

     Rule(s) :

      If-match customer-vlan-id 10

     Behavior: P100

      Nesting:

        Nest top-most vlan-id 100

   Classifier: A20

     Operator: AND

     Rule(s) :

      If-match customer-vlan-id 20

     Behavior: P200

      Nesting:

        Nest top-most vlan-id 200

# Verify the QoS marking configuration on the service provider-side ports on PE A and PE B. This example uses GigabitEthernet 1/0/2 of PE A.

[PE_A] display qos policy interface gigabitethernet 1/0/2

 

Interface: GigabitEthernet1/0/2

 

  Direction: Outbound

 

  Policy: vlanmapping

   Classifier: A100

     Operator: AND

     Rule(s) :

      If-match customer-vlan-id 10

      If-match service-vlan-id 100

     Behavior: T100

      Marking:

        Remark Customer VLAN ID 30

   Classifier: A200

     Operator: AND

     Rule(s) :

      If-match customer-vlan-id 20

      If-match service-vlan-id 200

     Behavior: T200

      Marking:

        Remark Customer VLAN ID 40

Configuration files

IMPORTANT

IMPORTANT:

Support for the port link-mode bridge command depends on the device model.

 

·     PE A:

#

vlan 10

#

vlan 20

#

vlan 30

#

vlan 40

#

vlan 100

#

vlan 200

#

traffic classifier A10 operator and

 if-match customer-vlan-id 10

#

traffic classifier A20 operator and

 if-match customer-vlan-id 20

#

traffic classifier A100 operator and

 if-match customer-vlan-id 10

 if-match service-vlan-id 100

#

traffic classifier A200 operator and

 if-match customer-vlan-id 20

 if-match service-vlan-id 200

#

traffic behavior P100

 nest top-most vlan 100

#

traffic behavior P200

 nest top-most vlan 200

#

traffic behavior T100

 remark customer-vlan-id 30

#

traffic behavior T200

 remark customer-vlan-id 40

#

qos policy qinq

 classifier A10 behavior P100

 classifier A20 behavior P200

#

qos policy vlanmapping

 classifier A100 behavior T100

 classifier A200 behavior T200

#

interface GigabitEthernet1/0/1

 port link-mode bridge

 port link-type hybrid

 undo port hybrid vlan 1

 port hybrid vlan 100 200 untagged

 qinq enable

 qos apply policy qinq inbound

#

interface GigabitEthernet1/0/2

 port link-mode bridge

 port link-type trunk

 undo port trunk permit vlan 1

 port trunk permit vlan 100 200

 qos apply policy vlanmapping outbound

#

·     PE B:

#

vlan 10

#

vlan 20

#

vlan 30

#

vlan 40

#

vlan 100

#

vlan 200

#

traffic classifier A30 operator and

 if-match customer-vlan-id 30

#

traffic classifier A40 operator and

 if-match customer-vlan-id 40

#

traffic classifier A100 operator and

 if-match customer-vlan-id 30

 if-match service-vlan-id 100

#

traffic classifier A200 operator and

 if-match customer-vlan-id 40

 if-match service-vlan-id 200

#

traffic behavior P100

 nest top-most vlan 100

#

traffic behavior P200

 nest top-most vlan 200

#

traffic behavior T100

 remark customer-vlan-id 10

#

traffic behavior T200

 remark customer-vlan-id 20

#

qos policy qinq

 classifier A30 behavior P100

 classifier A40 behavior P200

#

qos policy vlanmapping

 classifier A100 behavior T100

 classifier A200 behavior T200

#

interface GigabitEthernet1/0/1

 port link-mode bridge

 port link-type hybrid

 undo port hybrid vlan 1

 port hybrid vlan 100 200 untagged

 qinq enable

 qos apply policy qinq inbound

#

interface GigabitEthernet1/0/2

 port link-mode bridge

 port link-type trunk

 undo port trunk permit vlan 1

 port trunk permit vlan 100 200

 qos apply policy vlanmapping outbound

#

  • Cloud & AI
  • InterConnect
  • Intelligent Computing
  • Security
  • SMB Products
  • Intelligent Terminal Products
  • Product Support Services
  • Technical Service Solutions
All Services
  • Resource Center
  • Policy
  • Online Help
All Support
  • Become a Partner
  • Partner Resources
  • Partner Business Management
All Partners
  • Profile
  • News & Events
  • Online Exhibition Center
  • Contact Us
All About Us
新华三官网