This article describes how to configure, verify, and troubleshoot global DHCP relay service.
For other topics, go to the SRX Getting Started main page.
Configure global DHCP relay service on SRX devices.
This section contains the following:
An SRX Series device can act as a DHCP client, DHCP server, and DHCP relay agent at the same time, but you cannot configure more than one DHCP role on a single interface.For information about configuring the device as a DHCP server, see KB15754 - SRX Getting Started - Configure DHCP Server [juniper.net] .For information about configuring the device as a DHCP client, see KB15753 - SRX Getting Started - Configure DHCP Client [juniper.net] .Note : This article contains an example for configuring DHCP Relay Agent with a single server. For an example on configuring DHCP Relay Agent with Multiple Clients and Servers, refer to DHCP Relay Agent Configuration with Multiple Clients and Servers .
The following lists the traffic flow when a DHCP DISCOVER message is sent:
Note: This example does not use every option available for DHCP relay configuration. For information about additional DHCP relay configuration options in J-Web, see Configuring BOOTP or DHCP Relay with Quick Configuration , and Configuring DHCP with a Configuration Editor .
.
To configure an SRX Series device as a relay agent to forward incoming requests from BOOTP or DHCP clients to a BOOTP or DHCP server:
user@host# set forwarding-options helpers bootp description "Global DHCP relay service"
user@host# set forwarding-options helpers bootp server 192.18.24.38
user@host # set forwarding-options helpers bootp maximum-hop-count 4
user@host
set forwarding-options helpers bootp maximum-hop-count 4
user@host# set forwarding-options helpers bootp interface fe-0/0/7.0
user@host# set security zones security-zone trust interfaces fe-0/0/7 host-inbound-traffic system-services dhcp user@host# set security zones security-zone untrust interfaces fe-0/0/8 host-inbound-traffic system-services dhcp
user@host# set security zones security-zone untrust address-book address DHCP-server 192.18.24.38
user@host# set security policies from-zone trust to-zone untrust policy DHCP-request match source- address anyuser@host# set security policies from-zone trust to-zone untrust policy DHCP-request match destination-address DHCP-serveruser@host# set security policies from-zone trust to-zone untrust policy DHCP-request match application anyuser@host# set security policies from-zone trust to-zone untrust policy DHCP-request then permituser@host# set security policies from-zone untrust to-zone trust policy DHCP-reply match source-address DHCP-serveruser@host# set security policies from-zone untrust to-zone trust policy DHCP-reply match destination-address anyuser@host# set security policies from-zone untrust to-zone trust policy DHCP-reply match application anyuser@host# set security policies from-zone untrust to-zone trust policy DHCP-reply then permit
Administration Guide for Security Devices - See 'Configuring a DHCP Relay Agent' and 'Example: Configuring the Device as a BOOTP or DHCP Relay Agent'
To verify that the DHCP relay configuration, use the following operational mode command:
user@host> show system services dhcp relay-statistics
user@host>
Please note:
CLI command in operational mode: root> restart dhcp-service
To check the status of the service in shell. root@:~ # ps aux | grep dhcp.