can someone help me to solved my router 1 as relay agent dhcp.Currently user 5 that connect from switch 1 is not being able to get dhcp ip address. My router 2 as dhcp server pool and user 3 ,4 is successfully get the dhcp ip.The problem from user 5 that not getting dhcp ip from relay agent R1.
R2-dhcp server
ip dhcp excluded-address 192.168.30.1 192.168.30.10
ip dhcp pool R2-LAN30
network 192.168.30.0 255.255.255.0
default-router 192.168.30.1
dns-server 172.21.50.100
R1-dhcp relay agent
interface GigabitEthernet0/0
ip address 10.10.20.2 255.255.255.252
duplex auto
speed auto
!
interface GigabitEthernet1/0
ip address 10.10.20.9 255.255.255.252
duplex auto
speed auto
!
interface FastEthernet2/0
no ip address
duplex auto
speed auto
!
interface FastEthernet2/0.10
encapsulation dot1Q 10
ip address 192.168.10.1 255.255.255.0
!
interface FastEthernet2/0.20
encapsulation dot1Q 20
ip address 192.168.20.1 255.255.255.0
!
interface FastEthernet3/0
ip address 192.168.30.2 255.255.255.0
ip helper-address 10.10.20.10
duplex auto
speed auto
!
R1 -int ip brief
R1#show ip int brief
Interface IP-Address OK? Method Status Protocol
GigabitEthernet0/0 10.10.20.2 YES manual up up
GigabitEthernet1/0 10.10.20.9 YES manual up up
FastEthernet2/0 unassigned YES manual up up
FastEthernet2/0.10 192.168.10.1 YES manual up up
FastEthernet2/0.20 192.168.20.1 YES manual up up
FastEthernet3/0 192.168.30.2 YES manual up up
Serial4/0 unassigned YES NVRAM administratively down down
Serial5/0 unassigned YES NVRAM administratively down down
R2 -int ip brief
R2#sh ip int brief
Interface IP-Address OK? Method Status Protocol
GigabitEthernet0/0 10.10.20.6 YES manual up up
GigabitEthernet1/0 10.10.20.10 YES manual up up
FastEthernet2/0 192.168.30.1 YES manual up up
FastEthernet3/0 unassigned YES NVRAM administratively down down
Serial4/0 unassigned YES NVRAM administratively down down
Serial5/0 unassigned YES NVRAM administratively down down
Step 7: Configure DHCPv4
Configure a R2 as a DHCP Server to enable IP address can be assigned dynamically to user 3 and user 4 which IP address is VLAN 30. Make sure you exclude the first 10 addresses from the R2 LAN 192.168.30.0/24.
Create a DHCP pool named R2-LAN 30 (case-sensitive).
Configure R1 as a DHCP relay agent so that user 5 also can be assigned IP address dynamically.Verify DHCP bindings using command R2# show ip dhcp binding.Verify that User 3 and user 4 are assigned with the correct IP address and can ping each other and all other devices.
{}
function or just hitCtrl-k
.