65 
                 7052-0201-2013-1e02 
                 0201-9068-23 
10.1.1.132       2020-1220-1102-3021-  Jan 9 10:45:11 2015   Auto(C) 
                 7e52-0211-2025-3402 
                 0201-9068-9a 
10.1.1.133       2021-d012-0202-4221-  Jan 9 10:45:11 2015   Auto(C) 
                 8852-0203-2022-55e0 
                 3921-0104-31 
DHCP user class configuration example 
Network requirements 
As shown in Figure 26, the DHCP relay agent (Router A) forwards DHCP packets between DHCP 
clients and the DHCP server (Router B). Enable Router A to handle Option 82 so that it can add 
Option 82 in DHCP requests and then convey them to the DHCP server. 
Configure the address allocation scheme as follows: 
 
Assign IP addresses  To clients 
10.10.1.2 to 10.10.1.10  The DHCP request contains Option 82. 
10.10.1.11 to 10.10.1.26 
The hardware address in the request is six bytes long and 
begins with 
aabb-aabb-aab
. 
 
Router B assigns the DNS server address 10.10.1.20/24 and the gateway address 10.10.1.254/24 to 
clients on subnet 10.10.1.0/24. 
Figure 26 Network diagram 
 
 
Configuration procedure 
1.  Specify IP addresses for the interfaces on DHCP server. (Details not shown.) 
2.  Configure DHCP: 
# Enable DHCP and configure the DHCP server to handle Option 82. 
<RouterB> system-view 
[RouterB] dhcp enable 
[RouterB] dhcp server relay information enable 
# Enable the DHCP server on the interface GigabitEthernet1/0/1. 
[RouterB] interface gigabitethernet 1/0/1 
[RouterB-GigabitEthernet1/0/1] dhcp select server