Lecture 12 DHCP, ARP
Lecture 12 DHCP, ARP
• DHCP
• What is DHCP?
• How DHCP works?
• Steps of DHCP
• ARP
• What is ARP?
• How ARP works?
• ARP cache timeout
• Advantage and Disadvantage
What is DHCP
BOOTP cannot handle these situations because the binding between the
physical and IP addresses is static and fixed in a table until changed by the
administrator. BOOTP is a static configuration protocol.
DHCP
The Dynamic Host Configuration Protocol (DHCP) has been devised to provide
static and dynamic address allocation that can be manual or automatic.
Static Address Allocation: In this capacity DHCP acts as BOOTP does. It is
backward compatible with BOOTP, which means a host running the BOOTP
client can request a static address from a DHCP server. A DHCP server has a
database that statically binds physical addresses to IP addresses.
Dynamic Address Allocation: DHCP has a second database with a pool of
available IP addresses. This second database makes DHCP dynamic. When a
DHCP client requests a temporary IP address, the DHCP server goes to the
pool of available (unused) IP addresses and assigns an IP address for a
negotiable period of time.
DHCP process explained
Steps of DHCP: INIT State
DHCPDISCOVER is a request
message with the
DHCPDISCOVER option.
Steps of DHCP: SELECTING
State
After sending the DHCPDISCOVER
message, the client goes to the
selecting state.
In networking it is necessary for the sender to know the IP address and the
Physical address of the receiver for successful communication. If the MAC
address of the receiver is unknown to the sender; it uses Address Resolution
Protocol (ARP) protocol to identify the specific MAC address of the receiver.
ARP Request
PC – A PC – B PC- C
IP Add. : 10.0.0.5 IP Add. : 10.0.0.3 IP Add. : 10.0.0.1
MAC Add. MAC Add. MAC Add.
:AA:AA:AA:AA:AA :BB:BB:BB:BB:BB:BB :CC:CC:CC:CC:CC:CC
In the above scenario there are three computers in a single network. PC-A
wants to communicate with PC-C. But it only knows the IP address of PC-C.
So, PC-A will take the help of ARP to get the MAC address of PC-C.
ARP Request (cont.)
Packet (Network layer):
10.0.0.5 10.0.0.1 I want to know the MAC address of that
interface who’s ip address is 10.0.0.1
After making the ARP request frame PC-A will broadcast the frame in the
network. Assume that PC-B have got the frame it will read the header of the
frame and find out the physical address (FFFF:FFFF:FFFF) as destination MAC
address. Which means it’s a broadcast MAC address and the frame is for
everyone in that network. Therefore, PC-B will take the frame to the network
layer. In the network layer when the destination IP address is checked. There will
be a mismatch as PC-B doesn’t hold the ip address 10.0.0.1.
ARP Reply
On the other hand, when PC-C will get the frame it will read the header of the
frame and find out the physical address (FFFF:FFFF:FFFF) as destination
address. So, PC-C will transfer it to network layer. In network layer the host will
check the destination IP and finds out that it matches with its own IP address.
Therefore, PC-C will start reading the content of the packet. And it will make an
ARP reply frame and send it back to PC- A.
ARP Reply (cont.)
:CC:CC:CC:CC:CC: :AA:AA:AA:AA
CC :AA
ARP Example
ARP Cache Timeout
ARP Cache Timeout (cont.)
ARP Cache Timeout (cont.)
Advantage/Disadvantage
References