08-QinQ Command

Download


Chapter 1  QinQ Configuration Commands

1.1  QinQ Configuration Commands

1.1.1  display port vlan-vpn

Syntax

display port vlan-vpn

View

Any view

Parameter

None

Description

Use the display port vlan-vpn command to display the QinQ configuration of the current system.

Example

# Display the QinQ configuration of the current system.

<H3C> display port vlan-vpn

Ethernet3/0/4

 VLAN-VPN status: enabled

 VLAN-VPN VLAN: 1       

1.1.2  vlan-vpn enable

Syntax

vlan-vpn enable

undo vlan-vpn

View

Ethernet port view

Parameter

None

Description

Use the vlan-vpn enable command to enable the QinQ function for a port.

Use the undo vlan-vpn command to disable the QinQ function for a port.

By default, the QinQ function is disabled.

With the QinQ function enabled, a received packet is tagged with the default VLAN tag of the receiving port no matter whether or not the packet already carries a VLAN tag. If the packet already carries a VLAN tag, the packet becomes a double-tagged packet. Otherwise, the packet becomes a packet carrying the default VLAN tag of the port.

Example

# Enable the QinQ function for Ethernet1/0/1.

<H3C> system-view

System View: return to User View with Ctrl+Z.

[H3C] interface Ethernet 1/0/1

[H3C-Ethernet1/0/1] vlan-vpn enable

 


Chapter 2  Selective QinQ Configuration Commands

 

&  Note:

You can implement traffic-based selective QinQ on an S7500 switch by using ACLs and QoS techniques. Refer to the QoS part of this manual for related commands and operations.

 

2.1  Selective QinQ Configuration Commands

2.1.1  raw-vlan-id inbound

Syntax

raw-vlan-id inbound vlan-id-list

undo raw-vlan-id inbound { all | vlan-id-list }

View

QinQ view

Parameter

vlan-id-list: List of VLAN IDs. You need to provide this argument in the form of vlan-id-list = { vlan-id | [ to { vlan-id } ] } & <1-10>, where & <1-10> means that you can provide up to ten VLAN IDs/VLAN ID lists.

all: Specifies the packets of all the VLANs.

As for the vlan-id-list argument, the value of 1 to 4095 is not supported due to limited ACL resources.

Description

Use the raw-vlan-id inbound command to specify the outer VLAN tag to be inserted to the packets with the specified inner VLAN tags. This command is used in the inbound direction of the selective QinQ function on the port.

Use the undo raw-vlan-id inbound command to remove the configuration.

Note that the raw-vlan-id inbound command needs to be coupled by the vlan-vpn vid command.

Example

# Specify to insert the tag of VLAN 20 as the outer tag to the packets with their inner VLAN tags being the tags of VLAN 8 through VLAN 15 for Ethernet1/0/1.

<H3C> system-view

System View: return to User View with Ctrl+Z.

[H3C] interface Ethernet 1/0/1

[H3C-Ethernet1/0/1] vlan-vpn vid 20

[H3C-Ethernet1/0/1-vid-20] raw-vlan-id inbound 8 to 15

2.1.2  vlan-vpn vid

Syntax

vlan-vpn vid vlan-id [ flow-isolate all ]

undo vlan-vpn vid vlan-id [ flow-isolate all ]

View

Ethernet port view

Parameter

vlan-id: ID of the VLAN whose tag is to be inserted to matched packets as the outer VLAN tag.

flow-isolate all: Enables the data flow isolating function.

Description

Use the vlan-vpn vid command to configure the outer VLAN tag for a QinQ-enabled port. This command also leads you to QinQ view. A QinQ-enabled port inserts the user-defined outer VLAN tag to the received packets. You can use the raw-vlan-id inbound command to insert a specific outer VLAN tag to the packets with the specified inner VLAN tags.

Use the undo vlan-vpn vid command to remove the configuration.

With the flow-isolate all keyword specified, the data flow isolating function is enabled when the outer VLAN tag is being configured. With the data flow isolating function enabled, packets transmitted from a private network to the public network will not be broadcast to the other ports in the default VLAN of the receiving port.

Note that the vlan-vpn vid command needs to be coupled by the raw-vlan-id inbound command.

 

  Caution:

l      Before configuring this function, make sure that the vlan-vpn enable command is enabled. Moreover, this function must be configured on the ports receiving packets of private networks.

l      When the data flow isolating function is enabled, make sure that the uplink port and downlink port of the selective QinQ function do not reside in the same chip. Otherwise, communicate will fail.

 

Example

# Configure to insert the tag of VLAN 20 to the packets received on Ethernet1/0/1 as the outer VLAN tag.

<H3C> system-view

System View: return to User View with Ctrl+Z.

[H3C] interface Ethernet 1/0/1

[H3C-Ethernet1/0/1] vlan-vpn vid 20