To configure tunneling for egress traffic, use the set vlans dot1q-tunneling egress then service-vlan command in L2/L3 configuration mode. If a packet passes through the port, the service tag of the packet needs to be changed.
set vlans dot1q-tunneling egress tunnel-id then service-vlan vlan-id
The following example shows how to configure T0 tunneling. If a packet wants to pass through the port, the service tag of the packet needs to be replaced by 300: