You are correct that at some point during the DHCP process, the IP addresses and MAC addresses of both server and client become known to each other, and it would make sense to use those so that the communication becomes unicast. Some of these DHCP messages can indeed be unicast as well, but that depends on the manufacturer and operating system being used. Take a look at this post that describes this situation in more detail:
Our server provides IP address to many network.
However one of the networks like 10.25.181.0/24 have issue. Unable to issue to IP address to the client when connected to LAN port. The event log shows there is no IP address available to lease in the scope. We have two dhcp server as have same config.
What is the reason to appear this BAD Address in the DHCP server ?
How to solve this bad address in the DHCP server ?
According to Microsoftâs technet forum, the âBAD_ADDRESSâ indicator is most often seen when an IP conflict is detected. This is confirmed by the description in your screenshot that says âThis address is already in useâ.
A DHCP server will typically try to ping an address several times before assigning it to a DHCP client. This is done to ensure that the address does not exist. If a response is received from the ping, then the address is considered in use, and is marked by the DHCP server as a bad address.
A duplicate address may be seen in the following cases:
If you have manually configured a device to have an IP address that is within the range of the DHCP serverâs address scope
If you have two DHCP servers on the network and they are not properly configured to function in a redundant manner
The DHCP server was recently rebooted, and it lost its bindings, and it is trying to provide already assigned addresses to new devices before the lease on the old devices has expired.
The Microsoft link also provides some other cases where this may occur. This information should help direct you in your troubleshooting.
Dear Laz,
Actually have one dhcp server only. Both have the same configuration.
I have removed all the BAD IP address that is displayed on both earlier and then connect new my laptop i get IP address 10.25.181.133.
And also noticed that the existing IP address also changed to today date except two reserved IP address. And some BAD ADDRESS also displayed.
How to resolve it ?
Why the DHCP lease expiration date have changed to today date ?
Except two reserve IP address.
Please help.
From the screenshot you have now shared, it looks like the DHCP server is now working correctly. I see that there are no more bad addresses, and it seems that the addresses are being leased correctly by the server.
The lease expiration shown in the screenshot depends upon the lease time provided for this scope. From the moment the address is given, the lease expiration time is calculated based on this lease time.
As for the bad addresses, if you still see some in the list, then this means that there are indeed duplicate addresses somewhere on the network provided either statically, or by a rogue DHCP server. According to this Microsoft technet thread:
After the DHCP client receives a lease from the DHCP server, the client sends an Address Resolution Protocol (ARP) request to the address that it has been assigned. If a reply to the ARP request is received, the client has detected a conflict and sends a DHCPDecline message to the DHCP server. The DHCP server attaches a BAD_ADDRESS value to the IP address in the scope for the length of the lease. The client then begins the lease process again, and is offered the next available address in the scope.
For the bad addresses, you must become a detective and figure out exactly where the duplicate addresses are.
This question is a little outside the scope of this lesson, or this forum, however, Iâll mention a couple of things I found in my brief research of the topic.
It looks like Cacti is not able to use the Windows Server DHCP logs in any way, for monitoring or even to parse them to get some pertinent information from them. There are however some other options which include:
using Nagios which has built-in plugins to monitor DHCP and to interact with Windows DHCP server for this purpose
Use Windows Event Viewer to parse and view important DHCP events
send the event logs for DHCP to a syslog server
If you are committed to using Cacti, then it does have a plugin that can receive syslog messages and parse and store them for display, and if you capture DHCP events using a syslog server, you can then send them to the Cacti server. Iâm not sure if this is more involved than you were looking for, but there it is.
Because this is outside the scope of these lessons, I suggest you take a look at some Microsoft technet documentation that you can find using your favourite search engine. The following link may help you get started.
What is the difference between DHCP Rebind and DHCP Renew. Please explain detail more about DHCP Inform, and other DHCP packets apart from the DORA ones
A DHCP renewal occurs when a DHCP lease expires. The DHCP host will contact the original leasing DHCP server and request a new lease. A renewal simply renews the lease time. The actual IP address and the MAC address in the server entry, and any DHCP options used all remain the same.
A rebinding is when a host will remove all network information it may have previously obtained from a DHCP server and will begin from scratch. This is essentially the same process as a host would use when it initially powers up. It sends out a broadcast asking for a DHCP server to respond and binds to the server that responds successfully. In this process, it relearns IP address, subnet mask gateway, DNS server, and any options that may be made available.
When a host attempts to perform a DHCP renew and it fails for some reason, it will then attempt a rebind.
DHCP Discover packet is Broadcast based on the 15th bit in the Flags Filed if it is 0x8000 it is broadcast. Why is it not possible that DHCP Server use Client MAC Address and Serverâs MAC Address and directly unicast to the Client instead of broadcasting.
If there are two DHCP Servers in the network on what basis the Client accepts one IP Address and rejects another IP Address? On what parameters that IP Address offered is rejected by Client.
Does DHCP Server work on First Come First Serve basis?
How many minimum DHCP Servers needed in Local area network? In order to maintain reliability and high availability.
Can we have multiple DHCP Servers providing the same IP Address Range in the same network?
Why DHCP Offer is Broadcast?
Why DHCP Request is Broadcast?
After completion of DHCP DORA Process the client sents GARP in the Local network to find if there is any Client assigned same IP. If there is response from any of the Client then the Client understands that there is duplicate IP. Now I see that client sends message to DHCP Server will it be Broadcast or Unicast and also fills DHCPDECLINE Message in the Packet. How DHCP Server understands that it should not assign the IP Declined to any other Client in the Local area network?
Does DHCP Server send periodical ARP Packets for the range of IP Addresses available at its end in the Local Area Network.
What if the one IP Address is declined by an Client due to one client in the Network assigned IP Statically i.e. (10.1.1.1) and DHCP Server assigned next available IP Address in itâs pool i.e. 10.1.1.2 and it was successful. Now the scenario is DHCP Scope is 10.1.1.0/24 you have all the possible IP Addresses assigned starting from 10.1.1.2 â 10.1.1.254 you are left with 10.1.1.1 IP Address which we had conflict will it be assigned or not.
Adding to 10th Question what if you have offered 10.1.1.2 IP Address to the client and it is successful why cannot server immediately try to assign back 10.1.1.1 again to other client who requests IP Address why is it not happening? By the way remaining IP Addresses are still available 10.1.1.3 â 10.1.1.254.
Does DHCP Server sees for the first available IP Address in its scope and starts assigning IP Addresses?
For example in the scope 10.1.1.0/24 first 5 IP Addresses are assigned successfully via DORA Process to clients (10.1.1.1 â 10.1.1.5). Next 5 IPâs (10.1.1.6 â 10.1.1.10) are rejected due to DHCPDECLINE messages from the client. Now DHCP Server assigned 10.1.1.11 to client and it is successful does DHCP Server start assigning to other client form 10.1.1.12 or will it try assigning form the rejected IP Addresses (10.1.1.6 â 10.1.1.10) on what basis it considers and offers?
If IP Address is given for lease for 24 hours and DHCP Server will make it unavailable in its records the client went down after 1 hour now DHCP Server will know client is down and how will it make available?
One DHCP server is typically enough. Since DHCP leases have some duration, even if a DHCP server fails, it does not immediately affect the current network. However, if you do want DHCP server backup, then having a second server (appropriately configured) should be more than enough.
No. Otherwise, you may run into duplicate IP addresses.
There is no such indication in the related RFC. However, some DHCP server vendors may choose to implement this process.
See link in number 8
See link in number 8
Typically yes, but different vendors may choose to implement it differently.
See answers to numbers 8 and 12
Note that the related RFCs are the best places to fully understand how DHCP and other protocols work. They are the definitive location from which you can get your most trustworthy information.
When a DHCP server issues an IP address to a client for the specified lease time, that address is reserved for that lease time regardless of whether the client is connected or not. For example, you may turn on your PC, and it may get an IP address with a lease time of 24 hours. You may turn off your PC an hour later. That IP address is still reserved in the DHCP server for that configured lease time. The server will not âdetectâ that the client is off line and give its address elsewhere.
This is typical DHCP server behavior, however, your DHCP server vendor may provide additional mechanisms that can configure different behavior, and you may find some environments where such behavior is useful.
For example, in a wireless environment where you have dozens or even hundreds of users connecting and disconnecting all the time, you would typically reduce lease times to a few hours. But some clients may inadvertently connect simply because, as someone is walking by, their smartphone briefly connects and disconnects (if theyâre set to automatically reconnect). In this case, you wouldnât want that address to be allocated for several hours. Your DHCP server may have the capability of saying âif an address is not active for X number of minutes, release it.â
So you see, different behaviors can be configured and be beneficial for various environments.
Hello.
I have a project of a CPE, a PE with vrfs and a DHCP_SERVER. When I activate ip address dhcp from the CPE, the DHCPDISCOVER goes to the PE, and through the ip helper-address goes to the DHCP_SERVER. The thing is that the OFFER comes back to the CPE, and the REQUEST reaches the server, but the ACK does not appear anywhere. It doesnât work with C3745 neither with C7200, but it does work with a VPC native of GNS3. I canât see the solution, appreciate some help.