Sie sind auf Seite 1von 4

 request that IP address from DHCP server  ==> Broadcast

 DHCP ACK is sent by client to acknowledge the request packet sent by DHCP
client ==> Unicast

There are other  DHCP messages which used between DHCP Server/Client to
avoid duplicate  and release the IP address:

 DHCP NAK sent by the server to the client in response to a DHCPREQUEST. If 


DHCP server does not agree to allocate the IP address requested by client in DHCP
request  message.
 DHCP RELEASE sent by the client to the server to give up an IP address lease.
 DHCP DECLINE sent by the client to the server in response to a DHCPACK. If
the client receives a DHCPACK, but, for some reason, is not satisfied with the lease
time and/or network parameters in the message
Discovery  ( Message type 1):
Below points to be noticed in Discovery message.

1. Source MAC address is the client mac address destination mac address is the
broadcast mac address in the Ethernet header.
2. Source(Client) IP is 0.0.0.0 and destination IP is broadcast (255.255.255.255).
3. Protocol used by DHCP is UDP and port no. 67.
4. Client mac address is also sent under the Bootstrap protocol.this mac address is the
same which will be updated on DHCP server to keep the record which IP is
assigned to which client.

Offer (Message type 2):


Offer message is the response form DHCP server on discovery message sent by
client.

1. Source mac is Server mac address and destination mac is client Mac address .
2. Source IP is the again DHCP server address and destination IP would be offered IP
address.

Request (message 3):


1. Source mac address is client mac address and destination mac address is the DHCP
Server mac address.
2. Source IP is 0.0.0.0 and destination IP address is broadcast IP address.

Ack (Message Type 5) :


This packet is the unicast since now IP has been assigned to client.

1. source IP  and mac are the server IP and mac.


2. destination ip and mac are the client IP and mac.

BAD Address:
Interesting part of DHCP  is what is BAD address and how does DHCP know that
an IP address is BAD address ? So In simple language BAD address is the
duplicate address available into LAN, mean that IP address is used on any device
configured manually. During the DORA (Discovery, Offer, Request and
Acknowledge) Process DHCP server perform some checks to avoid assigning
duplicate ip address to client. So basically process is quite straight forward. as
soon as DHCP server receive’s the discovery message it check for the available
pool and next available IP address into the pool. now keeping that next available IP
address in destination. it send ICMP request packet, if it get the response from any
client on that ICMP request it mark that IP address as BAD Address inside the
DHCP Pool and repeat the same process again.

In case still DHCP server assign an IP address already existing in LAN network.
Machine getting new IP address will always generate Gratuitous ARP  request to
avoid duplicate IP address.this Gratuitous ARP request will be sent three times in
every one second of interval. In case of it receive the response Gratuitous ARP .
Client machine will send DHCPDECLINE message to DHCP server and will repeat
DORA process again to get new IP address.

Note: Gratuitous ARP packet send by machine here will not impact ARP table
because it is request(ARP Code 1). mean that during the process of duplicate IP check
there will not be any impact for the traffic of existing machine.
Thank you for reading and I hope you have enjoyed reading this.

You can share your views in comment section. if you would like get update for my
upcoming blogs. You can follow this blog ….

Das könnte Ihnen auch gefallen