07-28-2015 02:16 PM - edited 03-05-2019 01:57 AM
Hello Team,
i have been trying to configure DHCP server on cisco 1941 router but with no success.
This is quite easy on other cisco routers with fastethernet interfaces but i am having a problem with configuring DHCP on gigabitethernet interfaces on cisco 1941.
Here is part of the configs
ip dhcp pool LAN
network 172.16.99.0 255.255.255.0
default-router 172.16.99.1
interface GigabitEthernet0/1
ip address 172.16.99.1 255.255.255.0
duplex auto
speed auto
However; a pc on the LAN cannot get IP dynamically
Anyone with idea please post here as soon as possible
07-28-2015 10:56 PM
Hi there,
Your configuration is already all well and good and you should be able to get an IP address through that.
Troubleshoot:
1. Verify if your PC/Computer settings are set to DHCP settings. a computer with no IP allocation and if set to pool from DHCP settings should have an IP of 169.254.X.X if wasn't able to get an IP from your DHCP server
2. Assign static IP address on your Laptop/PC, try to see if you can ping the IP of the g0/1 e.g., 172.16.99.1
There a big chance you cant ping that IP address considering you cant get an IP address. Of course, if you can't ping it, troubleshoot why ^_^
Once you get a ping response, try to get IP through DHCP.
Tips:
1. Dont forget to configure 'ip dhcp-exclude address' to set the range of IPs
2. Dont forget to configure 'dns-server' as well as 'lease-time' to further tweak your configuration
Rate for helpful posts :)
07-28-2015 11:34 PM
All clients on same VLAN ?
07-29-2015 12:49 AM
I would recommend also checking the LAN switch.
- make sure that all affected ports are in Spanning-tree forwarding state and not err-disabled and that your VLAN is in active state
- verify any security configuration that might interfere with normal DHCP operation, like DHCP snooping, dynamic ARP inspection or ACLs blocking UDP ports 67, 68
- check whether IP Helper is configured anywhere (e.g. on the SVI on the switch)
- Finally clear counters on the GigabitEthernet interface on the router and enable debuging:
debug ip dhcp server packet
Please post the output of the debug session
08-20-2015 01:24 AM
The switchport that connects to your router needs to be on the same VLAN as the clients needing an address. This is most likely your issue.
08-21-2015 08:04 AM
Hello,
As everyone else pointed out, the DHCP config seems good and the problem is most likely on the access switch (or switches), check the Trunking configuration on the uplinks and the vlan configuration on the access ports.
You can also do a debug ip dhcp server packet on the router to see if the router is getting the DHCP packets from the PC's, starting from the DHCP Discover.
08-21-2015 12:44 PM
Than you all for your replies.
I figured it out. I had 3 vlans on my switch.
I had not configured the subinterfaces on the router.
I configured the subinterfaces,
Configured the DHCP pools for each VLAN and i was good to go.
It worked out
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide