Description

This article describes how to configure an SRX device as a Relay Agent using the JDHCP daemon.

Symptoms

Starting with Junos 12.x, a significant enhancement has been implemented in the DHCP process, introducing a new daemon known as JDHCP. While it remains feasible to employ the legacy relay-agent configuration, a crucial consideration arises when configuring an SRX device to function as both a DHCP server and a DHCP relay-agent.

 

It is imperative to note that only one process—either DHCP or JDHCP—can operate at any given time. Hence, careful attention must be directed towards ensuring that the configuration aligns with the desired functionality.

Solution

Topology:

 

DHCP client--------------------ge-0/0/0.0(SRX-RELAY-AGENT)ge-0/0/1.0----------------------DHCP Server

 

  • Configure DHCP server group and add the IP addresses of the DHCP server belonging to the group.

set forwarding-options dhcp-relay server-group DHCP-SERVER 1.1.1.1 ----(DHCP server IP-address)

 

  • Set the DHCP server group as active server group.

set forwarding-options dhcp-relay active-server-group DHCP-SERVER

 

  • Configure an interface group and specify the DHCP relay interface for the group.

set forwarding-options dhcp-relay group relay interface ge-0/0/0.0

 

  • Configure the interface to allow dhcp services.

set security zones security-zone <zone-name> interfaces ge-0/0/0.0 host-inbound-traffic system-services dhcp

Above is the bare minimum configuration required in SRX to act as an relay-agent. However, it's essential to note that within the dhcp-relay hierarchy, you have a spectrum of additional options available to use as per your requirement.

Modification History

2024-02-29 : Article Created

2025-12-28 : Added host-inbound service command to allow dhcp services on interface