cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2512
Views
0
Helpful
7
Replies

Relay agent not relaying DHCP messages between DHCP and client.

Mitrixsen
Level 1
Level 1

Hello, everyone!

I was configuring a router to act as DHCPv4 to provide IP addressing to a computer. Everything worked well, therefore I have placed another router in my topology between the DHCP and the computer, to configure it as a relay agent. Here is my topology, everything is being built in Packet Tracer.

 

obrázok.png

I've added the helper-address to Router's Gig0/0/0 interface to make it relay the DHCP messages, however, it does not work. Whenever I set the PC to automatically get its IP addressing, it tells me that APIPA is being used and that DHCP failed. I must have made some sort of mistake with the relay agent.

obrázok.png

Configuration - DHCP Router

DHCP(config)#ip dhcp excluded-address 192.168.10.1
DHCP(config)#ip dhcp pool TEST
DHCP(dhcp-config)#network 192.168.10.0 255.255.255.0
DHCP(dhcp-config)#default-router 192.168.10.1
DHCP(dhcp-config)#dns-server 8.8.8.8
DHCP(dhcp-config)#domain-name testing.com
DHCP(dhcp-config)#exit

DHCP(config)#int G0/0/0
DHCP(config-if)#ip add 192.168.10.1 255.255.255.0
DHCP(config-if)#no shut
DHCP(config-if)#exit

 

Configuration - Relay Router

Router(config)#int range G0/0/0-1
Router(config-if-range)#no shut
Router(config-if-range)#exit

Router(config)#int G0/0/1
Router(config-if)#ip address dhcp
Router(config-if)#exit

Router(config)#int G0/0/0
Router(config-if)#ip helper-address 192.168.10.1
Router(config-if)#exit

 

If someone knows what did I do wrong, then please let me know. Thank you all in advance!

1 Accepted Solution

Accepted Solutions

We have quite limited information about this. There are things that we do not know which might impact our understanding of the situation. For example it is not clear whether interface G0/0/0 on router is configured with an IP address.

Based on what we know so far this is my understanding:

- there is a single DHCP scope configured.

- that scope is for 192.168.10.0.

- that scope works on the Ethernet connecting DHCP with router.

- that scope works and the router interface successfully learns an IP address.

- if interface G0/0/0 has an IP address it must be in a different subnet.

- if PC2 is connected in a different subnet then there needs to be a DHCP scope set up for that subnet. But we only know of a single DHCP scope.

- if interface G0/0/0 does not have an IP address then the configured helper address can not work because router is not processing IP on that interface.

HTH

Rick

View solution in original post

7 Replies 7

MichaelMcCoy
Level 1
Level 1

Just to be clear, 

 

Does the router titles "router" obtain a DHCP address on the Gi0/0/1 interface from the DHCP router?

Hi MichaelMcCoy, thank you so much for replying.

 

Yes, it does.

Router(config)#int G0/0/1
Router(config-if)#ip address dhcp
%DHCP-6-ADDRESS_ASSIGN: Interface GigabitEthernet0/0/1 assigned DHCP address 192.168.10.2, mask 255.255.255.0, hostname Router

return traffic, router which is DHCP Server must know how return traffic to LAN side.

We have quite limited information about this. There are things that we do not know which might impact our understanding of the situation. For example it is not clear whether interface G0/0/0 on router is configured with an IP address.

Based on what we know so far this is my understanding:

- there is a single DHCP scope configured.

- that scope is for 192.168.10.0.

- that scope works on the Ethernet connecting DHCP with router.

- that scope works and the router interface successfully learns an IP address.

- if interface G0/0/0 has an IP address it must be in a different subnet.

- if PC2 is connected in a different subnet then there needs to be a DHCP scope set up for that subnet. But we only know of a single DHCP scope.

- if interface G0/0/0 does not have an IP address then the configured helper address can not work because router is not processing IP on that interface.

HTH

Rick

Interface G0/0/0 did not have an IP, thus it did not work. Thank you very much for your help and tips. I will make sure to provide more information next time!

Thank you for the update. And for confirming that the interface did not have an IP address. I am glad that we were able to help you find the problem.  Thank you for marking this question as solved. This will help other participants in the community to identify discussions which have helpful information. This community is an excellent place to ask questions and to learn about networking. I hope to see you continue to be active in the community.

HTH

Rick

Hello,

 

post the zipped Packet Tracer  project (.pkt) file...