H3C S7500 Series Ethernet Switches Release 3135 DHCP Configuration Examples

DHCP Configuration Examples
H3C S7500 Series Ethernet Switches Release 3135 Chapter 2 Configuration Examples
2-6
2.2.3 Configuration Procedure
I. Configuring the DHCP relay agent
Figure 2-3 Network diagram for DHCP relay agent configuration
# Configure to forward the DHCP requests from the Office to the DHCP server in the
HQ.
<SwitchA> system-view
[SwitchA] dhcp-server 1 ip 192.168.0.3
[SwitchA] interface vlan-interface10
[SwitchA-Vlan-interface10] ip address 192.168.10.1 24
[SwitchA-Vlan-interface10] dhcp-server 1
# Configure to forward the DHCP requests from Lab2 to the Lab DHCP server.
[SwitchA-Vlan-interface10] quit
[SwitchA] dhcp-server 2 ip 192.168.17.1
[SwitchA] interface Vlan-interface 25
[SwitchA-Vlan-interface25] ip address 192.168.19.1 24
[SwitchA-Vlan-interface25] dhcp-server 2
# Configure the IP address of VLAN-interface 17 as 172.16.2.5/30 for forwarding DHCP
packets from the Lab DHCP Server to a non-local segment.
[SwitchA-Vlan-interface25] quit
[SwitchA] interface Vlan-interface 17
[SwitchA-Vlan-interface17] ip address 172.16.2.5 30
# Configure the address check function on the DHCP relay agent. Make sure you
configure the IP addresses and MAC addresses of the DHCP server in the lab and that
in the office as static entries for the security function. The addresses of these static
entries will not be checked.
[SwitchA-Vlan-interface17] quit
[SwitchA] dhcp-security static 192.168.10.3 0014-222c-aa69
[SwitchA] dhcp-security static 192.168.17.1 0010-5ce9-1dea
[SwitchA] interface Vlan-interface 10
[SwitchA-Vlan-interface10] address-check enable
[SwitchA-Vlan-interface10] quit
[SwitchA] interface vlan-interface 25
[SwitchA-Vlan-interface25] address-check enable
[SwitchA-Vlan-interface25] quit