In this article, we will learn about what is DHCP and how it Works, also about the purpose of DHCP, DHCP port used, DHCP request and DHCP process, DHCP DORA process,
What is DHCP
DHCP stands for Dynamic Host Configuration Protocol, DHCP is a network protocol that enables a server to assign an IP address to a computer automatically as per a defined scope configured in DHCP Server. DHCP centrally manages the network configurations Such as IP Address, subnet mask, default gateway, DNS server details rather than requiring network administrators to assigning IP addresses to all network devices manually. DHCP can be implemented in any size of the organization.
Purpose of DHCP
Every device on the network requires an IP address. This can be assigned statically or dynamically. When you have a smaller number of devices such as 5 or 10 you can assign an IP address manually, but when your organizations having large no devices it is not feasible or difficult to assign Network configuration manually. Then we require the DHCP server which assigns the network configuration to all network devices automatically. Also, we can Manage the Network Configuration automatically.
DHCP Process works in four phases.
1.Discovery -Server Discovery
2.Offer – IP Lease Offer
3.Request – IP Lease Request
4. Acknowledgment -IP lease Acknowledgment
This process is known as DORA Process.
Port used by DHCP
DHCP uses UDP port 67,68.
DHCP client uses UDP port 67
DHCP server uses UDP port 68
Let’s Understand DORA Process
The client sends out a DHCP Discover message to find about the DHCP server. DHCP discover message is a layer 2 broadcast as well as layer 3 broadcast.
Fields in DHCP Discover Message
Source IP: 0.0.0.0
Source MAC: MAC Address of Client
Destination MAC : FF:FF:FF:FF:FF:FF
The DHCP server receives the discovery message from the client and sent the offer message to the client. It contains a network configuration setting for the client like an IP address, Subnet default gateway, etc to be offered.
Response to Offer by the DHCP Server is indicating that the client has accepted the network configuration. It means that it will accept the offer by the DHCP server. The Request message sent by the client with destination address 255.255.255.255 and source address is IP address offered by the Client.
After the request message or accept the IP by DHCP SERVER, the server sent an ACK to the client. That the client that now you can start using the network
This Four Steps of DORA describes how DHCP assigns the DHCP Address
You Can check the assigned IP Configuration by Using the Command ipconfig in Command Prompt.
In Above Post you have Learn about Concept of DHCP, DORA process, the installation of DHCP server in Windows platform is also easy which will we learn in next Post