SlideShare a Scribd company logo
1 of 15
What is DHCP and How DHCP Works?
(DHCPFundamentalsExplained)
Computer networks can be of any form like a LAN, WAN etc. If you are connected to a
local LAN or an internet connection, the IP addresses form the basis
of communication over computer networks. An IP address is the identity of a host or a
computer device while connected to any network.
In most of the cases when you connect your computer to a LAN or internet, you’ll notice
that the IP address and other information like subnet mask etc are assigned to your
computer automatically. Have you ever thought about how this happens? Well, in this
article we will understand the concept of DHCP that forms the basis of this functionality.
What is DHCP?
DHCP stands for Dynamic Host Configuration Protocol.
As the name suggests, DHCP is used to control the network configuration of a host
through a remote server. DHCP functionality comes installed as a default feature in most
of the contemporary operating systems. DHCP is an excellent alternative to the time -
consuming manual configuration of network settings on a host or a network device.
DHCP works on a client-server model. Being a protocol, it has it’s own set of messages
that are exchanged between client and server. Here is the header information of DHCP :
FIELD OCTETS DESCRIPTION
op 1 Type of message
htype 1 type of hardware address
hlen 1 length of hardware address
hops 1 used in case of relay agents. Clients sets them to 0.
xid 4 Transaction ID used by the client and server for a session.
secs 2
Time elapsed (in seconds) since the client requested the
process
flags 2 Flags
ciaddr 4 Client IP address.
yiaddr 4 The IP address assigned by server to the client
siaddr 4 Server IP address.
giaddr 4 IP address of the relay agent.
chaddr 16 Hardware address of the client.
sname 64 Host name of the server.
file 128 Boot file name.
options var Additional options
Understanding DHCP helps in debugging many network related problems. Read our
articles onwireshark and Journey of a packet on network to enhance your understanding
on network and network debugging tools.
In the next section, we will cover the working of this protocol.
How DHCP Works?
Before learning the process through which DHCP achieves it’s goal, we first have to
understand the different messages that are used in the process.
1. DHCPDISCOVER
It is a DHCP message that marks the beginning of a DHCP interaction between client and
server. This message is sent by a client (host or device connected to a network) that is
connected to a local subnet. It’s a broadcast message that uses 255.255.255.255 as
destination IP address while the source IP address is 0.0.0.0
2. DHCPOFFER
It is DHCP message that is sent in response to DHCPDISCOVER by a DHCP server to DHCP
client. This message contains the network configuration settings for the client that sent
the DHCPDISCOVER message.
3. DHCPREQUEST
This DHCP message is sent in response to DHCPOFFER indicating that the client has
accepted the network configuration sent in DHCPOFFER message from the server.
4. DHCPACK
This message is sent by the DHCP server in response to DHCPREQUEST recieved from the
client. This message marks the end of the process that started with DHCPDISCOVER. The
DHCPACK message is nothing but an acknowledgement by the DHCP server that
authorizes the DHCP client to start using the network configuration it received from the
DHCP server earlier.
5. DHCPNAK
This message is the exact opposite to DHCPACK described above. This message is sent by
the DHCP server when it is not able to satisfy the DHCPREQUEST message from the client.
6. DHCPDECLINE
This message is sent from the DHCP client to the server in case the client finds that the IP
address assigned by DHCP server is already in use.
7. DHCPINFORM
This message is sent from the DHCP client in case the IP address is statica lly configured
on the client and only other network settings or configurations are desired to be
dynamically acquired from DHCP server.
8. DHCPRELEASE
This message is sent by the DHCP client in case it wants to terminate the lease of network
address it has be provided by DHCP server.
Now as we know about the various DHCP messages, it’s time to go through the the
complete DHCP process to give a better Idea of how DHCP works. Note that the steps
mentioned below assume that DHCP functionality is enabled by default on the client side.
Here are the steps :
Step 1: When the client computer (or device) boots up or is connected to a network, a
DHCPDISCOVER message is sent from the client to the server. As there is no network
configuration information on the client so the message is sent with 0.0.0.0 as source
address and 255.255.255.255 as destination address. If the DHCP server is on local subnet
then it directly receives the message or in case it is on different subnet then a relay
agent connected on client’s subnet is used to pass on the request to DHCP server. The
transport protocol used for this message is UDP and the port number used is 67. The
client enters the initializing stage during this step.
Step 2: When the DHCP server receives the DHCPDISCOVER reque st message then it
replies with a DHCPOFFER message. As already explained, this message contains all the
network configuration settings required by the client. For example, the yaddr field of the
message will contain the IP address to be assigned to client. Similarly the the subnet
mask and gateway information is filled in the options field. Also, the server fills in the
client MAC address in the chaddr field. This message is sent as a broadcast
(255.255.255.255) message for the client to receive it directl y or if DHCP server is in
different subnet then this message is sent to the relay agent that takes care of whether
the message is to be passed as unicast or broadcast. In this case also, UDP protocol is
used at the transport layer with destination port as 68. The client enters selecting stage
during this step
Step 3: The client forms a DHCPREQUEST message in reply to DHCPOFFER message and
sends it to the server indicating it wants to accept the network configuration sent in the
DHCPOFFER message. If there were multiple DHCP servers that received DHCPDISCOVER
then client could receive multiple DHCPOFFER messages. But, the client replies to only
one of the messages by populating the server identification field with the IP address of a
particular DHCP server. All the messages from other DHCP servers are implicitly declined.
The DHCPREQUEST message will still contain the source address as 0.0.0.0 as the client is
still not allowed to use the IP address passed to it through DHCPOFFER message. The
client enters requesting stage during this step.
Step 4: Once the server receives DHCPREQUEST from the client, it sends the DHCPACK
message indicating that now the client is allowed to use the IP address assigned to it. The
client enters the bound state during this step.
The Concept of Lease
With all the necessary information on how DHCP works, one should also know that the
IP address assigned by DHCP server to DHCP client is on a lease. After the lease expires
the DHCP server is free to assign the same IP address to any o ther host or device
requesting for the same. For example, keeping lease time 8-10 hours is helpful in case of
PC’s that are shut down at the end of the day. So, lease has to be renewed from time to
time. The DHCP client tries to renew the lease after half of the lease time has expired.
This is done by the exchange of DHCPREQUEST and DHCPACK messages. While doing all
this, the client enters the renewing stage.
Step by step diagram
DHCP SERVER
DHCP Server Guaidlines using CISCO PACKET TRACER
DHCP Server Guaidlines using CISCO PACKET TRACER
DHCP Server Guaidlines using CISCO PACKET TRACER
DHCP Server Guaidlines using CISCO PACKET TRACER
DHCP Server Guaidlines using CISCO PACKET TRACER
DHCP Server Guaidlines using CISCO PACKET TRACER
DHCP Server Guaidlines using CISCO PACKET TRACER
DHCP Server Guaidlines using CISCO PACKET TRACER
DHCP Server Guaidlines using CISCO PACKET TRACER
DHCP Server Guaidlines using CISCO PACKET TRACER

More Related Content

What's hot

4G and 5g network
4G and 5g  network4G and 5g  network
4G and 5g networkAk Pandit
 
Setting up a home network
Setting up a home networkSetting up a home network
Setting up a home networkclcewing
 
Routers.ppt
Routers.pptRouters.ppt
Routers.pptkirbadh
 
Wireless security presentation
Wireless security presentationWireless security presentation
Wireless security presentationMuhammad Zia
 
Packet Tracer Tutorial # 1
Packet Tracer Tutorial # 1Packet Tracer Tutorial # 1
Packet Tracer Tutorial # 1Abdul Basit
 
LoRaWAN in Depth
LoRaWAN in DepthLoRaWAN in Depth
LoRaWAN in DepthAPNIC
 
VPN (virtual private network)
VPN (virtual private network) VPN (virtual private network)
VPN (virtual private network) Netwax Lab
 
5G Technology ppt.pdf
5G Technology ppt.pdf5G Technology ppt.pdf
5G Technology ppt.pdfGaurav203517
 
Cisco Packet Tracer Overview
Cisco Packet Tracer OverviewCisco Packet Tracer Overview
Cisco Packet Tracer OverviewAli Usman
 
VPN - Virtual Private Network
VPN - Virtual Private NetworkVPN - Virtual Private Network
VPN - Virtual Private NetworkPeter R. Egli
 
5G Mobile Technology-By TAHMID RONGON
5G Mobile Technology-By TAHMID RONGON5G Mobile Technology-By TAHMID RONGON
5G Mobile Technology-By TAHMID RONGONTahmid Rongon
 
Wi-Gig (Wireless Gigabit Alliance) ppt
Wi-Gig (Wireless Gigabit Alliance) pptWi-Gig (Wireless Gigabit Alliance) ppt
Wi-Gig (Wireless Gigabit Alliance) pptAbida Zama
 

What's hot (20)

IPV6 ADDRESS
IPV6 ADDRESSIPV6 ADDRESS
IPV6 ADDRESS
 
4G and 5g network
4G and 5g  network4G and 5g  network
4G and 5g network
 
Setting up a home network
Setting up a home networkSetting up a home network
Setting up a home network
 
Routers.ppt
Routers.pptRouters.ppt
Routers.ppt
 
Introduction to Software Defined Networking (SDN)
Introduction to Software Defined Networking (SDN)Introduction to Software Defined Networking (SDN)
Introduction to Software Defined Networking (SDN)
 
Wifi & 802.11 Standards
Wifi & 802.11 StandardsWifi & 802.11 Standards
Wifi & 802.11 Standards
 
Wireless security presentation
Wireless security presentationWireless security presentation
Wireless security presentation
 
SD WAN
SD WANSD WAN
SD WAN
 
Packet Tracer Tutorial # 1
Packet Tracer Tutorial # 1Packet Tracer Tutorial # 1
Packet Tracer Tutorial # 1
 
Ipsec
IpsecIpsec
Ipsec
 
5g technology ppt
5g technology ppt5g technology ppt
5g technology ppt
 
LoRaWAN in Depth
LoRaWAN in DepthLoRaWAN in Depth
LoRaWAN in Depth
 
VPN (virtual private network)
VPN (virtual private network) VPN (virtual private network)
VPN (virtual private network)
 
Vpn presentation
Vpn presentationVpn presentation
Vpn presentation
 
Ethernet
EthernetEthernet
Ethernet
 
5G Technology ppt.pdf
5G Technology ppt.pdf5G Technology ppt.pdf
5G Technology ppt.pdf
 
Cisco Packet Tracer Overview
Cisco Packet Tracer OverviewCisco Packet Tracer Overview
Cisco Packet Tracer Overview
 
VPN - Virtual Private Network
VPN - Virtual Private NetworkVPN - Virtual Private Network
VPN - Virtual Private Network
 
5G Mobile Technology-By TAHMID RONGON
5G Mobile Technology-By TAHMID RONGON5G Mobile Technology-By TAHMID RONGON
5G Mobile Technology-By TAHMID RONGON
 
Wi-Gig (Wireless Gigabit Alliance) ppt
Wi-Gig (Wireless Gigabit Alliance) pptWi-Gig (Wireless Gigabit Alliance) ppt
Wi-Gig (Wireless Gigabit Alliance) ppt
 

Viewers also liked

Wan technologies
Wan technologiesWan technologies
Wan technologiesOnline
 
Wide area network (wan)
Wide area network (wan)Wide area network (wan)
Wide area network (wan)Raaz Shrestha
 
Local area network
Local area networkLocal area network
Local area networkSEDYK
 
Ccna Presentation
Ccna PresentationCcna Presentation
Ccna Presentationbcdran
 
Lan, man and wan ppt final
Lan, man and wan ppt finalLan, man and wan ppt final
Lan, man and wan ppt finalArushi Garg
 

Viewers also liked (9)

Dhcp with cisco
Dhcp with ciscoDhcp with cisco
Dhcp with cisco
 
Dhcp cisco
Dhcp ciscoDhcp cisco
Dhcp cisco
 
Chapter 10 - DHCP
Chapter 10 - DHCPChapter 10 - DHCP
Chapter 10 - DHCP
 
Ccna notes
Ccna notesCcna notes
Ccna notes
 
Wan technologies
Wan technologiesWan technologies
Wan technologies
 
Wide area network (wan)
Wide area network (wan)Wide area network (wan)
Wide area network (wan)
 
Local area network
Local area networkLocal area network
Local area network
 
Ccna Presentation
Ccna PresentationCcna Presentation
Ccna Presentation
 
Lan, man and wan ppt final
Lan, man and wan ppt finalLan, man and wan ppt final
Lan, man and wan ppt final
 

Similar to DHCP Server Guaidlines using CISCO PACKET TRACER

6 understanding DHCP
6 understanding DHCP6 understanding DHCP
6 understanding DHCPHameda Hurmat
 
Investigation of dhcp packets using wireshark
Investigation of dhcp packets using wiresharkInvestigation of dhcp packets using wireshark
Investigation of dhcp packets using wiresharkjpratt59
 
DHCP (dynamic host configuration protocol)
DHCP (dynamic host configuration protocol)DHCP (dynamic host configuration protocol)
DHCP (dynamic host configuration protocol)Netwax Lab
 
dynamichost configuration protocol
dynamichost configuration protocoldynamichost configuration protocol
dynamichost configuration protocolrajisri2
 
Dynamic Host Configuration Protocol ( DHCP).pptx
Dynamic Host Configuration Protocol ( DHCP).pptxDynamic Host Configuration Protocol ( DHCP).pptx
Dynamic Host Configuration Protocol ( DHCP).pptxSYEDASGARAHMED1
 
DYNAMIC HOST CONFIGURATION PROTOCOL
DYNAMIC HOST CONFIGURATION PROTOCOLDYNAMIC HOST CONFIGURATION PROTOCOL
DYNAMIC HOST CONFIGURATION PROTOCOLVENKATESHAN A S
 
DHCP in windows server 2012
DHCP in windows server 2012DHCP in windows server 2012
DHCP in windows server 2012Abaady Sahal
 
Networking DHCP server Setup Reports
Networking DHCP server Setup ReportsNetworking DHCP server Setup Reports
Networking DHCP server Setup ReportsJiaul Hasan Jony
 
Durai presentation of dhcp
Durai presentation of dhcpDurai presentation of dhcp
Durai presentation of dhcpduraimurugan89
 
Dhcp server configuration
Dhcp server configurationDhcp server configuration
Dhcp server configurationUttamAgarwal9
 

Similar to DHCP Server Guaidlines using CISCO PACKET TRACER (20)

DHCP
DHCPDHCP
DHCP
 
zuiqui_DHC.ppt
zuiqui_DHC.pptzuiqui_DHC.ppt
zuiqui_DHC.ppt
 
6 understanding DHCP
6 understanding DHCP6 understanding DHCP
6 understanding DHCP
 
Investigation of dhcp packets using wireshark
Investigation of dhcp packets using wiresharkInvestigation of dhcp packets using wireshark
Investigation of dhcp packets using wireshark
 
DHCP (dynamic host configuration protocol)
DHCP (dynamic host configuration protocol)DHCP (dynamic host configuration protocol)
DHCP (dynamic host configuration protocol)
 
dynamichost configuration protocol
dynamichost configuration protocoldynamichost configuration protocol
dynamichost configuration protocol
 
A1803020108
A1803020108A1803020108
A1803020108
 
Configuring a DHCP Server
Configuring a DHCP Server Configuring a DHCP Server
Configuring a DHCP Server
 
DHCP.pptx
DHCP.pptxDHCP.pptx
DHCP.pptx
 
Dynamic Host Configuration Protocol ( DHCP).pptx
Dynamic Host Configuration Protocol ( DHCP).pptxDynamic Host Configuration Protocol ( DHCP).pptx
Dynamic Host Configuration Protocol ( DHCP).pptx
 
Dhcp
DhcpDhcp
Dhcp
 
DYNAMIC HOST CONFIGURATION PROTOCOL
DYNAMIC HOST CONFIGURATION PROTOCOLDYNAMIC HOST CONFIGURATION PROTOCOL
DYNAMIC HOST CONFIGURATION PROTOCOL
 
14047721
1404772114047721
14047721
 
unit 2
unit 2unit 2
unit 2
 
DHCP in windows server 2012
DHCP in windows server 2012DHCP in windows server 2012
DHCP in windows server 2012
 
Networking DHCP server Setup Reports
Networking DHCP server Setup ReportsNetworking DHCP server Setup Reports
Networking DHCP server Setup Reports
 
Linux05 DHCP Server
Linux05 DHCP ServerLinux05 DHCP Server
Linux05 DHCP Server
 
Durai presentation of dhcp
Durai presentation of dhcpDurai presentation of dhcp
Durai presentation of dhcp
 
Dhcp server configuration
Dhcp server configurationDhcp server configuration
Dhcp server configuration
 
Wintel ppt for dhcp
Wintel ppt for dhcpWintel ppt for dhcp
Wintel ppt for dhcp
 

More from COMSATS Institute of Information Technology (10)

Data Hazard and Solution for Data Hazard
Data Hazard and Solution for Data HazardData Hazard and Solution for Data Hazard
Data Hazard and Solution for Data Hazard
 
Software Architecture
Software ArchitectureSoftware Architecture
Software Architecture
 
Software Architecture
Software ArchitectureSoftware Architecture
Software Architecture
 
Virtual memory, allocaton of frame & trashing
Virtual memory, allocaton of frame & trashingVirtual memory, allocaton of frame & trashing
Virtual memory, allocaton of frame & trashing
 
Virtual memory ,Allocaton of frame & Trashing
Virtual memory  ,Allocaton of frame & TrashingVirtual memory  ,Allocaton of frame & Trashing
Virtual memory ,Allocaton of frame & Trashing
 
Network cables-Imdad Hussain
Network cables-Imdad HussainNetwork cables-Imdad Hussain
Network cables-Imdad Hussain
 
COMUNICATION NETWORK NETWORK TOPOLOGY NETWORK CABLES NETWORK DEVICES
COMUNICATION NETWORK NETWORK TOPOLOGY NETWORK CABLES NETWORK DEVICESCOMUNICATION NETWORK NETWORK TOPOLOGY NETWORK CABLES NETWORK DEVICES
COMUNICATION NETWORK NETWORK TOPOLOGY NETWORK CABLES NETWORK DEVICES
 
DOC MS Microsoft windows
DOC MS Microsoft windowsDOC MS Microsoft windows
DOC MS Microsoft windows
 
Amdahl`s law -Processor performance
Amdahl`s law -Processor performanceAmdahl`s law -Processor performance
Amdahl`s law -Processor performance
 
Sequnce diagram for ONLINE EXAMINATION SYSTEM
Sequnce diagram for ONLINE EXAMINATION SYSTEMSequnce diagram for ONLINE EXAMINATION SYSTEM
Sequnce diagram for ONLINE EXAMINATION SYSTEM
 

Recently uploaded

Science 7 - LAND and SEA BREEZE and its Characteristics
Science 7 - LAND and SEA BREEZE and its CharacteristicsScience 7 - LAND and SEA BREEZE and its Characteristics
Science 7 - LAND and SEA BREEZE and its CharacteristicsKarinaGenton
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformChameera Dedduwage
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)eniolaolutunde
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introductionMaksud Ahmed
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxSayali Powar
 
Solving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxSolving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxOH TEIK BIN
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfsanyamsingh5019
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTiammrhaywood
 
MENTAL STATUS EXAMINATION format.docx
MENTAL     STATUS EXAMINATION format.docxMENTAL     STATUS EXAMINATION format.docx
MENTAL STATUS EXAMINATION format.docxPoojaSen20
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityGeoBlogs
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Krashi Coaching
 
Introduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher EducationIntroduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher Educationpboyjonauth
 
_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting Data_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting DataJhengPantaleon
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17Celine George
 
mini mental status format.docx
mini    mental       status     format.docxmini    mental       status     format.docx
mini mental status format.docxPoojaSen20
 
Class 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfClass 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfakmcokerachita
 
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxContemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxRoyAbrique
 
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...M56BOOKSTORE PRODUCT/SERVICE
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxpboyjonauth
 

Recently uploaded (20)

9953330565 Low Rate Call Girls In Rohini Delhi NCR
9953330565 Low Rate Call Girls In Rohini  Delhi NCR9953330565 Low Rate Call Girls In Rohini  Delhi NCR
9953330565 Low Rate Call Girls In Rohini Delhi NCR
 
Science 7 - LAND and SEA BREEZE and its Characteristics
Science 7 - LAND and SEA BREEZE and its CharacteristicsScience 7 - LAND and SEA BREEZE and its Characteristics
Science 7 - LAND and SEA BREEZE and its Characteristics
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy Reform
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
 
Solving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxSolving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptx
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdf
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
 
MENTAL STATUS EXAMINATION format.docx
MENTAL     STATUS EXAMINATION format.docxMENTAL     STATUS EXAMINATION format.docx
MENTAL STATUS EXAMINATION format.docx
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
 
Introduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher EducationIntroduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher Education
 
_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting Data_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting Data
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17
 
mini mental status format.docx
mini    mental       status     format.docxmini    mental       status     format.docx
mini mental status format.docx
 
Class 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfClass 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdf
 
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxContemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
 
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptx
 

DHCP Server Guaidlines using CISCO PACKET TRACER

  • 1. What is DHCP and How DHCP Works? (DHCPFundamentalsExplained) Computer networks can be of any form like a LAN, WAN etc. If you are connected to a local LAN or an internet connection, the IP addresses form the basis of communication over computer networks. An IP address is the identity of a host or a computer device while connected to any network. In most of the cases when you connect your computer to a LAN or internet, you’ll notice that the IP address and other information like subnet mask etc are assigned to your computer automatically. Have you ever thought about how this happens? Well, in this article we will understand the concept of DHCP that forms the basis of this functionality. What is DHCP? DHCP stands for Dynamic Host Configuration Protocol. As the name suggests, DHCP is used to control the network configuration of a host through a remote server. DHCP functionality comes installed as a default feature in most of the contemporary operating systems. DHCP is an excellent alternative to the time - consuming manual configuration of network settings on a host or a network device. DHCP works on a client-server model. Being a protocol, it has it’s own set of messages that are exchanged between client and server. Here is the header information of DHCP : FIELD OCTETS DESCRIPTION op 1 Type of message htype 1 type of hardware address hlen 1 length of hardware address hops 1 used in case of relay agents. Clients sets them to 0. xid 4 Transaction ID used by the client and server for a session. secs 2 Time elapsed (in seconds) since the client requested the process flags 2 Flags
  • 2. ciaddr 4 Client IP address. yiaddr 4 The IP address assigned by server to the client siaddr 4 Server IP address. giaddr 4 IP address of the relay agent. chaddr 16 Hardware address of the client. sname 64 Host name of the server. file 128 Boot file name. options var Additional options Understanding DHCP helps in debugging many network related problems. Read our articles onwireshark and Journey of a packet on network to enhance your understanding on network and network debugging tools. In the next section, we will cover the working of this protocol. How DHCP Works? Before learning the process through which DHCP achieves it’s goal, we first have to understand the different messages that are used in the process. 1. DHCPDISCOVER It is a DHCP message that marks the beginning of a DHCP interaction between client and server. This message is sent by a client (host or device connected to a network) that is connected to a local subnet. It’s a broadcast message that uses 255.255.255.255 as destination IP address while the source IP address is 0.0.0.0 2. DHCPOFFER It is DHCP message that is sent in response to DHCPDISCOVER by a DHCP server to DHCP client. This message contains the network configuration settings for the client that sent the DHCPDISCOVER message. 3. DHCPREQUEST This DHCP message is sent in response to DHCPOFFER indicating that the client has accepted the network configuration sent in DHCPOFFER message from the server. 4. DHCPACK
  • 3. This message is sent by the DHCP server in response to DHCPREQUEST recieved from the client. This message marks the end of the process that started with DHCPDISCOVER. The DHCPACK message is nothing but an acknowledgement by the DHCP server that authorizes the DHCP client to start using the network configuration it received from the DHCP server earlier. 5. DHCPNAK This message is the exact opposite to DHCPACK described above. This message is sent by the DHCP server when it is not able to satisfy the DHCPREQUEST message from the client. 6. DHCPDECLINE This message is sent from the DHCP client to the server in case the client finds that the IP address assigned by DHCP server is already in use. 7. DHCPINFORM This message is sent from the DHCP client in case the IP address is statica lly configured on the client and only other network settings or configurations are desired to be dynamically acquired from DHCP server. 8. DHCPRELEASE This message is sent by the DHCP client in case it wants to terminate the lease of network address it has be provided by DHCP server. Now as we know about the various DHCP messages, it’s time to go through the the complete DHCP process to give a better Idea of how DHCP works. Note that the steps mentioned below assume that DHCP functionality is enabled by default on the client side. Here are the steps :
  • 4. Step 1: When the client computer (or device) boots up or is connected to a network, a DHCPDISCOVER message is sent from the client to the server. As there is no network configuration information on the client so the message is sent with 0.0.0.0 as source address and 255.255.255.255 as destination address. If the DHCP server is on local subnet then it directly receives the message or in case it is on different subnet then a relay agent connected on client’s subnet is used to pass on the request to DHCP server. The transport protocol used for this message is UDP and the port number used is 67. The client enters the initializing stage during this step. Step 2: When the DHCP server receives the DHCPDISCOVER reque st message then it replies with a DHCPOFFER message. As already explained, this message contains all the network configuration settings required by the client. For example, the yaddr field of the message will contain the IP address to be assigned to client. Similarly the the subnet mask and gateway information is filled in the options field. Also, the server fills in the client MAC address in the chaddr field. This message is sent as a broadcast (255.255.255.255) message for the client to receive it directl y or if DHCP server is in different subnet then this message is sent to the relay agent that takes care of whether the message is to be passed as unicast or broadcast. In this case also, UDP protocol is used at the transport layer with destination port as 68. The client enters selecting stage during this step Step 3: The client forms a DHCPREQUEST message in reply to DHCPOFFER message and sends it to the server indicating it wants to accept the network configuration sent in the DHCPOFFER message. If there were multiple DHCP servers that received DHCPDISCOVER then client could receive multiple DHCPOFFER messages. But, the client replies to only one of the messages by populating the server identification field with the IP address of a particular DHCP server. All the messages from other DHCP servers are implicitly declined. The DHCPREQUEST message will still contain the source address as 0.0.0.0 as the client is still not allowed to use the IP address passed to it through DHCPOFFER message. The client enters requesting stage during this step. Step 4: Once the server receives DHCPREQUEST from the client, it sends the DHCPACK message indicating that now the client is allowed to use the IP address assigned to it. The client enters the bound state during this step. The Concept of Lease With all the necessary information on how DHCP works, one should also know that the IP address assigned by DHCP server to DHCP client is on a lease. After the lease expires the DHCP server is free to assign the same IP address to any o ther host or device requesting for the same. For example, keeping lease time 8-10 hours is helpful in case of PC’s that are shut down at the end of the day. So, lease has to be renewed from time to time. The DHCP client tries to renew the lease after half of the lease time has expired.
  • 5. This is done by the exchange of DHCPREQUEST and DHCPACK messages. While doing all this, the client enters the renewing stage. Step by step diagram DHCP SERVER