🌐 DHCP (Dynamic Host Configuration Protocol)
🌐 DHCP (Dynamic Host Configuration Protocol)
🧠 Top 5 Key Points
-
Automatic IP Assignment:
DHCP automatically assigns IP addresses, subnet masks, gateways, and DNS servers to clients, reducing manual configuration. -
Centralized Management:
All IP configuration settings are managed by a DHCP server, simplifying administration in large networks. -
Leased IP Addresses:
Clients receive IPs for a limited lease period — after which they can renew or release them. -
Uses UDP Ports:
-
UDP Port 67: Server side
-
UDP Port 68: Client side
-
-
Message Types:
Key DHCP message types: Discover → Offer → Request → Acknowledge (DORA).
⚙️ Technical Summary
| Feature | Description |
|---|---|
| OSI Layer | Application Layer |
| Protocol Type | UDP |
| Default Port | 67 (Server), 68 (Client) |
| Purpose | IP address auto-assignment |
| Process | DORA (Discover, Offer, Request, Acknowledge) |
🧰 Packet Tracer Lab — DHCP Configuration
🎯 Goal:
Set up a Router as DHCP Server to automatically assign IPs to clients in a LAN.
🖥️ Network Topology
IP Plan
| Device | Interface | IP Address | Purpose |
|---|---|---|---|
| Router (R1) | G0/0 | 192.168.10.1 | Default Gateway & DHCP Server |
| PC1 | DHCP | Assigned automatically | |
| PC2 | DHCP | Assigned automatically |
🪜 Step-by-Step Configuration
🔹 1. Configure Router Interface
🔹 2. Configure DHCP Pool
🔹 3. Exclude Router IP Address
(Prevents the DHCP server from assigning the router’s own IP.)
🔹 4. Verify DHCP Configuration
🔹 5. Configure PCs
In Packet Tracer:
-
Click PC → Desktop → IP Configuration
-
Select DHCP
-
PC automatically gets an IP address (e.g.,
192.168.10.6,192.168.10.7).
🔹 6. Test Connectivity
-
On PC1, open Command Prompt → ping 192.168.10.1
✅ Should succeed (gateway reachable). -
On PC1, ping PC2’s IP (both dynamically assigned).
✅ Should also succeed.
💡 Troubleshooting Tips
| Issue | Fix |
|---|---|
| PCs not receiving IP | Check if DHCP service is enabled on router |
| Same IP for all PCs | Ensure enough IPs in the pool |
| No ping | Check cabling and interfaces (use no shutdown) |
🧠 Learning Summary
| Concept | Description |
|---|---|
| DHCP Role | Assign IP addresses automatically |
| DHCP Messages | DORA (Discover, Offer, Request, Acknowledge) |
| Default Gateway | Assigned via DHCP |
| Exclusion | Prevents assigning reserved IPs |
| Verification | show ip dhcp binding |
Comments
Post a Comment