- by x32x01 ||
What is DHCP?
DHCP (Dynamic Host Configuration Protocol) automatically assigns network settings to devices when they connect. This means you don’t need to manually enter IP addresses for every device!What DHCP Provides
IP Address - Unique identifier for your device
Subnet Mask - Defines your network range
Default Gateway - Your path to the internet
DNS Server Address - Points your device to websites
DHCP DORA Process
Technical Details
- Protocol: UDP
- Ports:
- Server → 67
- Client → 68
What is DNS?
DNS (Domain Name System) works like the internet’s phonebook. It converts human-readable domain names into IP addresses so your browser can load websites.What DNS Does
Converts domain names like google.com
Into IP addresses like 142.250.xxx.xxx
DNS Lookup Types
Forward Lookup: Domain → IP
Reverse Lookup: IP → Domain
Technical Details
- Protocol: UDP (mostly)
- Port: 53
Why DHCP + DNS Work Perfectly Together
Fast connectivity
Reliable communication
User-friendly networking
Who Should Learn DHCP & DNS?
IT Support Engineers
Networking Students
CCNA Aspirants
Cybersecurity Enthusiasts
Example: Quick DHCP & DNS Check in Python
Python:
import socket
# DNS lookup example
hostname = 'google.com'
ip = socket.gethostbyname(hostname)
print(f"IP address of {hostname} is {ip}")
# Simple DHCP simulation (conceptual)
dhcp_info = {
"IP Address": "192.168.1.10",
"Subnet Mask": "255.255.255.0",
"Gateway": "192.168.1.1",
"DNS": "8.8.8.8"
}
print("DHCP Assigned Info:", dhcp_info)