The DHCP server must be configured with an appropriate scope of IP addresses and TCP/IP parameters for clients within each subnet. For example, the administrator must configured the DHCP server with an IP address range and subnet mask. The administrator must also set the lease duration time dependant on the organisations requirements. For example, if the organisation only has a limited number of IP addresses available and a large number of devices or clients that join and leave the network regularly, then the administrator may wish to reduce the time of the lease so that DHCP returns unused addresses for redistribution.
Read more: One Stop MOS
Finally, the administrator should configure the DHCP server to exclude static IP addresses present on the network from scope. For example, you may choose to exclude a certain IP address range from the scope of DHCP and utilise this address space for statically assigned servers on the network, if appropriate.
The interactions between client and server can be broadly compared to that of a TCP/IP connection. The client utilises a DHCPDiscover command to search for the DHCP server on the network. This is achieved by broadcasting the message to a specific subnet where the servers reside. The DHCP Server should pick up this command and issue a DHCPOffer command back to the client, which offers an IP address as configured by the administrator. The client then responds with a DHCPRequest command that requests the IP address offered and finally the server issues a DHCPPAck message to finalise the terms of the lease. This can be easily compared with shopping or an auction, as the seller you put out your product to a specific market, a potential buyer see’s the advert and comes back with an “offer” and you as the seller accept or decline and then the sale is finalised by the buyer presenting cash.
What’s DHCP? And why it’s recommended to use it? Imagine that you’re working as a SysAdmin for a large company with 500 desktop computers; you need to set to each desktop computer IP address, subnet mask, default gateway, DNS servers, and other network settings. How could you do that?
If you’ll try to perform this task manually you’re probably going to waste a lot of time on sitting on each computer 5-10 minutes, beside time, you can for example accidentally enter wrong IP address to few clients, or to type the same IP address to few clients too.
In order to solve these “problems” you can use Dynamic Host Configuration Protocol (or DHCP) in your network.
DHCP allows you to manage the networks’ IP addresses scopes and other TCP/IP settings like DNS, Default Gateway, etc. from central place, this central place called DHCP server. Beside the management, if there’s any problem you don’t need to run between your clients, you just need to connect to your server and to check the DHCP settings, as I mentioned – the DHCP works from central place, so if there’s a problem, it’s probably from the server, so you know where to go in case of problem and your saving time.
Know more: what does lan mean
The DHCP server can provide easily IP addresses to clients automatically so you don’t even need to configure and set options in the client side, all you need is to setup DHCP server, configure scope options and some other TCP/IP settings in the server side and that’s it. You can provide to your clients IP addresses from the selected range that you’ve configured and some other TCP/IP options.
Without entering to the related technical information (DORA process) the DHCP client request from the DHCP server IP address for a while, the length of time that the DHCP client can use the dynamic IP address that the DHCP Server provided can be called lease, just like the name: lease means that the client “rent” an IP address for a specific time from the DHCP server, if the client wants to continue using the specific IP address the client needs to re-assign the address by renew the lease, this will happen before the expiration time of the lease if the client is still in the network.
More in depth, the DHCP service works by using the DORA (Discover, Offer, Request and Acknowledgment) process (you can trace on the whole process using a network monitor utility):