Some times ago there was a task to configure selective QinQ for our client. On site interaction we have qtech qsw-8200 (aggregation switch from OEM vendor, http://www.qtech.ru/catalog/corporate/213/info.htm). On the end site – Mikrotik 951.
Settings on qtech.
1. Increase MTU:
mtu 10218
2. Service vlan (provider tag) – vlan 40
vlan40
name S-VLAN
3. Customers vlan’s that needs to be encapsulated
vlan 41
name C1-VLAN
vlan 42
name C2-vlan
4. Other transit vlan’s
vlan 43,44,45
5. Next, create a class to which the policy will apply thereafter hanging the second tag:
class-map C
match vlan 41,42
6. Create a policy that adds one more tag
policy-map P
class-map C
add s-vid 40
7.Customer on interface ethernet 1/0/1
interface Ethernet 1/0/1
service-policy input P
switchport mode hybrid
switchport hybrid allowed vlan add 40 untag //for removing provider tag
switchport hybrid allowed vlan add 43,44,45
8. Uplink interface
interface ethernet 1/0/24
switchport mode hybrid
switchport hybrid allowed vlan 42,43,44,45