On the network shown in Figure 1 and Figure 2, the Dynamic Host Configuration Protocol (DHCP) server function is configured on termination sub-interfaces, so that the sub-interfaces can assign IP addresses to users.
The DHCP server function can be configured on a sub-interface for Dot1q VLAN tag termination or sub-interface for QinQ VLAN tag termination, based on whether the user packets received by a PE contain one or two VLAN tags.
If the user packets contain one tag, the sub-interface that has the DHCP server function configured is a sub-interface for Dot1q VLAN tag termination.
If the user packets contain double tags, the sub-interface that has the DHCP server function configured is a sub-interface for QinQ VLAN tag termination.
On the network shown in Figure 1, the user packet received by the DHCP server carries a single tag. To enable the sub-interface for Dot1q VLAN tag termination on the DHCP server to assign an IP address to a DHCP client, configure the DHCP server function on the sub-interface for Dot1q VLAN tag termination.
On the network shown in Figure 2, the switch has selective QinQ configured, and the user packet received by the DHCP server carries double tags. To enable the sub-interface for QinQ VLAN tag termination on the DHCP server to assign an IP address to a DHCP client, configure the DHCP server function on the sub-interface for QinQ VLAN tag termination.