Sweshi's Tutorials

DHCP SERVER CONFIGURATION IN CENTOS LINUX

What is DHCP?

DHCP stands for Dynamic Host Configuration Protocol. It is a network protocol that is used to automatically assign and manage IP addresses and other network configuration information to devices on a TCP/IP network. DHCP eliminates the need for administrators to manually assign IP addresses to every device on a network, making it a more efficient and scalable solution.

How DHCP works
  • Request: When a device (such as a computer or smartphone) connects to a network, it sends a DHCP request to the network to obtain an IP address.
  • Offer: DHCP servers on the network respond to the request by offering an IP address along with other configuration parameters such as subnet mask, default gateway, and DNS server addresses.
  • Selection: The requesting device chooses one of the offered IP addresses and notifies the DHCP server of its selection.
  • Acknowledgment: The DHCP server acknowledges the selection and assigns the chosen IP address to the device. Additionally, it provides the device with the other configuration parameters.
Main Characteristics of DHCP
  • Client-Server architecture: A central server allocates network settings to client computers.
  • Types of network settings given: Allocation of the configuration parameters to the computer such as the IP address, network mask, default gateway, DNS server, domain name, etc.
  • Types of Allocation
    • Automatic Allocation - fixed IP address is assigned to the host connecting to the network based on the mac address. The machine will always be recieving the same IP.
    • Dynamic Allocation - assigning network settings for a fixed time only (lease of settings).

By automating the assignment of IP addresses and related network configuration information, DHCP simplifies network administration and reduces the chances of conflicts arising from manual address assignment. DHCP is commonly used in homes, businesses, and larger organizations to efficiently manage IP addresses within a network.