cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
3846
Views
0
Helpful
4
Replies

DHCP Relay in N9K

PROSENJIT GIRI
Level 1
Level 1

Hi,

I need to implement DHCP relay in DC environment. I am attaching DC network diagram. There are total 3 Vlan in one VRF (name: SAP_HANA). Three vlan subnets are mentioned below.

VRF: SAP_HANA

Vlan10: 172.16.10.0/24

Vlan11: 172.16.11.0/24

Vlan12: 172.16.12.0/24

DHCP server IP: 172.16.10.30/24

As per the requirement DHCP server is sitting in vlan 10 and host from vlan 11 and 12 want to get the IP address from DHCP server. Definitely I need to configure DHCP relay for Vlan 11 and 12. All vlans 10,11 and 12 are spanned across Primary DC to Secondary DC over DWDM (Layer 2) trunk link.

But I have my two doubts which are stated below.

(1) Do I need to configure DHCP relay vlan 11 and 12 for all four core switches (2 core switch in primary and 2 in Secondary)? so if my understanding is correct, SVI 11 and SVI 12 will be acting as a DHCP relay Agent.

(2)My SVI config for Primary core switch in primary DC is mentioned below.

interface Vlan11
description ** HANA Lan **

ip dhcp relay address 172.16.10.30

ip dhcp relay information trusted

ip dhcp relay source-interface vlan 11
no shutdown
vrf member SAP_HANA
ip address 172.16.11.2/24
hsrp version 2
hsrp 11
preempt
priority 200
ip 172.16.11.1

So the packet flow will be like this:

Source IP (any ip from Vlan 11) will send the broadcast massage to SVI 11 (172.16.11.1) -----> Once receive the Broadcast request from Host for DHCP IP,  SVI11 will be source IP and willl generate a DHCP Discover to DHCP server ---->DHCP will generate the DHCP Offer massage to SVI 11 ---> then SVI 11 will request for DHCP request ---> DHCP will provide the IP to SVI 11 and in this case SVI 11 as a relay agent will forward the IP to original host (part of a same VLAN) ---> After receiving the IP DHCP host will generate the DHCP ACK massage.

Kindly clarify me in case my understanding is wrong.

Regads

Giri P

4 Replies 4

dukenuk96
Level 3
Level 3

Hi

if you have SVIs (not just VLANs) and HSRP groups on all four core switches, then you need to configure DHCP relay on all of them, otherwise, if one of them will fail, no DHCP requests will be relayed.

Ok understood. But can you tell me about below configuration. Whether it is correct or wrong? interface Vlan11 description ** HANA Lan ** ip dhcp relay address 172.16.10.30 ip dhcp relay information trusted ip dhcp relay source-interface vlan 11 no shutdown vrf member SAP_HANA ip address 172.16.11.2/24 hsrp version 2 hsrp 11 preempt priority 200 ip 172.16.11.1

I can not say whether it is wrong or right, since do not know all your requirements, but one thing to think - what for do you use these commands "ip dhcp relay information trusted ip dhcp relay source-interface vlan 11"?

I am running into a similar problem and I was wondering the reason for having those two statements on the configuration.

 

thanks;

Review Cisco Networking for a $25 gift card