221
[SwitchC-policy-p1] classifier c1 behavior b1 mode dot1q-tag-manipulation
[SwitchC-policy-p1] classifier c2 behavior b2 mode dot1q-tag-manipulation
[SwitchC-policy-p1] classifier c3 behavior b3 mode dot1q-tag-manipulation
[SwitchC-policy-p1] quit
[SwitchC] qos policy p2
[SwitchC-policy-p2] classifier c4 behavior b1 mode dot1q-tag-manipulation
[SwitchC-policy-p2] classifier c5 behavior b2 mode dot1q-tag-manipulation
[SwitchC-policy-p2] classifier c6 behavior b3 mode dot1q-tag-manipulation
[SwitchC-policy-p2] quit
# Assign customer-side port Ethernet 1/0/1 to CVLANs 101, 201, 301, 102, 202, 302, and
SVLANs 501 to 503. On this port, also enable customer-side QinQ, and apply uplink policy
p1
to
the incoming traffic.
[SwitchC] interface ethernet 1/0/1
[SwitchC-Ethernet1/0/1] port link-type trunk
[SwitchC-Ethernet1/0/1] port trunk permit vlan 101 201 301 102 202 302 501 502 503
[SwitchC-Ethernet1/0/1] qinq enable downlink
[SwitchC-Ethernet1/0/1] qos apply policy p1 inbound
[SwitchC-Ethernet1/0/1] quit
# Assign customer-side port Ethernet 1/0/2 to CVLANs 103, 203, 303, 104, 204, 304, and
SVLANs 501 to 503. On this port, also enable customer-side QinQ, and apply uplink policy
p2
to
the incoming traffic.
[SwitchC] interface ethernet 1/0/2
[SwitchC-Ethernet1/0/2] port link-type trunk
[SwitchC-Ethernet1/0/2] port trunk permit vlan 103 203 303 104 204 304 501 502 503
[SwitchC-Ethernet1/0/2] qinq enable downlink
[SwitchC-Ethernet1/0/2] qos apply policy p2 inbound
[SwitchC-Ethernet1/0/2] quit
# Assign network-side Ethernet 1/0/3 to SVLANs 501 to 503, set the port as a DHCP and ARP
trusted port, and enable network-side QinQ.
[SwitchC] interface ethernet 1/0/3
[SwitchC-Ethernet1/0/3] port link-type trunk
[SwitchC-Ethernet1/0/3] port trunk permit vlan 501 502 503
[SwitchC-Ethernet1/0/3] dhcp-snooping trust
[SwitchC-Ethernet1/0/3] arp detection trust
[SwitchC-Ethernet1/0/3] qinq enable uplink
4.
Configure Switch D:
# Enable DHCP snooping.
<SwitchD> system-view
[SwitchD] dhcp-snooping
# Assign port Ethernet 1/0/1 to SVLANs 501 to 503.
[SwitchD] interface ethernet 1/0/1
[SwitchD-Ethernet1/0/1] port link-type trunk
[SwitchD-Ethernet1/0/1] port trunk permit vlan 501 502 503