Supported Platforms
Example: Configuring Global Liveness Detection for DHCP Relay Agent Clients
This example shows how to configure liveness detection for DHCP relay agent subscribers using Bidirectional Forwarding Detection (BFD) as the liveness detection method.
Requirements
- Juniper Networks MX Series routers.
- Junos OS Release 12.1R1 or later.
- Configure DHCP relay agent. See Extended DHCP Relay Agent Overview.
Overview
In this example, you configure liveness detection for DHCP relay agent subscribers by completing the following operations:
- Enable liveness detection globally for DHCP relay subscribers.
- Specify BFD as the liveness detection method for all dynamically created DHCP relay subscribers.
- Configure BFD-specific statements to define how the protocol behaves.
- Configure the action the router takes when a liveness detection failure occurs.
![]() | Note: This example explains how to configure liveness detection for a DHCPv4 network. Liveness detection is also supported for DHCPv6 configurations. To configure DHCPv6 liveness detection, include the liveness-detection statement, and any subsequent configuration statements, at the [edit forwarding-options dhcp-relay dhcpv6] or [edit forwarding-options dhcp-relay dhcpv6 group group-name] hierarchy level. |
Configuration
Step-by-Step Procedure
To configure liveness detection for DHCP relay:
- Specify that you want to configure liveness detection. [edit forwarding-options dhcp-relay]user@host# edit liveness-detection
- Specify that you want to configure the liveness detection
method.[edit forwarding-options dhcp-relay liveness-detection]user@host# edit method
- Specify BFD as the liveness detection method that you
want DHCP to use.[edit forwarding-options dhcp-relay liveness-detection method]user@host# edit bfd
- Configure the detection time threshold (in milliseconds)
at which a trap is produced.[edit forwarding-options dhcp-relay liveness-detection method bfd]user@host# set detection-time threshold 50000
- Configure the time (in milliseconds) for which BFD holds
a session up notification.[edit forwarding-options dhcp-relay liveness-detection method bfd]user@host# set holddown-interval 50
- Configure the BFD minimum transmit and receive interval
(in milliseconds).[edit forwarding-options dhcp-relay liveness-detection method bfd]user@host# set minimum-interval 45000
- Configure the minimum receive interval (in milliseconds).[edit forwarding-options dhcp-relay liveness-detection method bfd]user@host# set minimum-receive-interval 60000
- Configure a multiplier value for the detection time.[edit forwarding-options dhcp-relay liveness-detection method bfd]user@host# set multiplier 100
- Disable the ability for BFD interval timers to change
or adapt to network situations.[edit forwarding-options dhcp-relay liveness-detection method bfd]user@host# set no-adaptation
- Configure the BFD session mode.[edit forwarding-options dhcp-relay liveness-detection method bfd]user@host# set session-mode automatic
- Configure the threshold and minimum interval for the BFD
transmit interval.[edit forwarding-options dhcp-relay liveness-detection method bfd]user@host# set transmit-interval threshold 60000 minimum-interval 45000
- Configure the BFD protocol version you want to detect.[edit forwarding-options dhcp-relay liveness-detection method bfd]user@host# set version automatic
- Configure the action the router takes when a liveness
detection failure occurs. In this example, the failure action is to
clear the client session only when a liveness detection failure occurs
and the local interface is detected as being up.[edit forwarding-options dhcp-relay liveness-detection]user@host# edit failure-action action
Results
From configuration mode, confirm your configuration by entering the show forwarding-options command. If the output does not display the intended configuration, repeat the instructions in this example to correct it. The following output also shows a range of configured interfaces in group frankfurt.
If you are done configuring the device, enter commit from configuration mode.