Segment ID Support for DHCP Relay

Segment ID Support for DHCP Relay

This feature explains how a Cisco Nexus 7000 Series Switches perform the role of a DHCP relay in the DFA environment.


Note


A detailed explanation of the DHCP feature documentation for Cisco Nexus 7000 Series Switches is available in the Configuring DHCP chapter of the Cisco Nexus 7000 Series NX-OS Security Configuration Guide.

Guidelines and Limitations

  • You should know about the DHCPv4 relay, DHCPv6 relay, BDI, and segment ID functions.

Information About Segment ID Support for DHCP Relay

DHCP Relay Configuration Overview

Figure 1. DHCP relay configuration through a BDI

The illustration depicts a Cisco Nexus 7000 Series Switches in a DFA environment (Nexus 7000). The DHCP client (Host) seeking an IP address via DHCP is on the left side and the DHCP server that provides the IP address is on the right side (DHCP Server). Here, we configure the DHCP server address on a BDI of the Cisco Nexus 7000 Series Switch.

The following sections explain DHCP relay configuration:

  1. Enabling a Cisco Nexus 7000 Series Switch as a DHCP relay agent.
  2. Configuring a DHCP server address on the relay agent.
  3. Configuring the VPN option for the DHCP relay agent.

Enabling a Cisco Nexus 7000 Series Switch as a DHCP Relay Agent

Enabling a Device as a DHCPv4 Relay Agent

switch# configure terminal
switch(config)# feature dhcp
switch(config)# ip dhcp relay 

Enabling a Device as a DHCPv6 Relay Agent

switch# configure terminal
switch(config)# feature dhcp
switch(config)# ipv6 dhcp relay

Configuring a DHCP server address on the Relay Agent

Configuring a DHCPv4 Server Address on the Relay Agent

switch(config)# interface bdi 15
switch(config-if)# ip dhcp relay address 192.0.2.120 use-vrf management
  • The interface level configuration command (ip dhcp relay address) is used to configure or disable a server address on a BDI.
  • The use-vrf option is used to specify the VRF name of the server if the client and server are in different VRFs.

Configuring a DHCPv6 Server Address on the Relay Agent

switch(config)# interface bdi 15
switch(config-if)# ipv6 dhcp relay address 2001:DB8:1::1 use-vrf management2 
  • The interface level configuration command (ipv6 dhcp relay address) is used to configure or disable a server address on a BDI.
  • The use-vrf is used to specify the VRF name of the server if the client and server are in different VRFs.
  • The server address can either be a link scoped unicast or multicast address, or it can be a global or site local unicast or multicast address.
  • An interface is required when the DHCP server address is a link local address or multicast address. It is not allowed for a unicast address.
Important:

You should be able to ping the server (for the specified server address) from the specified VRF.

Configuring the VPN option for the Relay Agent

Attention: In a DFA environment, configuring the VPN option is mandatory since the DHCP server is always in a different VRF, typically in a management or default VRF.

Configuring the VPN option for the DHCPv4 Relay Agent

switch# configure terminal
switch(config)# ip dhcp relay information option
switch(config)# ip dhcp relay information option vpn
  • The global level VPN configuration command is used to enable or disable the DHCPv4 relay function across VRFs.

Configuring the VPN option for the DHCPv6 Relay Agent

switch# configure terminal
switch(config)# ipv6 dhcp relay option vpn
  • The global level configuration command is used to enable or disable the DHCPv6 relay function across VRFs. When this is enabled, and the DHCPv6 server is in a different VRF, the relay agent inserts a virtual selection sub option in the relay-forward message. By default, this is disabled.

After DHCP relay configuration on a device and assignment of a DHCP server address through a BDI, the network topology looks like this:

Figure 2. DHCP relay configuration and DHCP server address assignment through a BDI