It is not exactly a battle DNS vs DHCP, we need both types of servers for our daily internet use. They are not direct competitors; they both work with IP addresses but in a different way.
The IP (internet protocol) address is the unique number configuration (or numbers and symbols in IP v6) that serves as a computer’s ID on the internet. Other devices use this number to communicate with that computer.
In the past, network administrators were assigning the IP addresses for each of the connected devices. This was not practical, and it took too much time. To make the process easier, DHCP (dynamic host configuration protocol) was invented. It works in a centralized way, using the server-client model. The DHCP server dynamically and automatically provides IP addresses to every newly connected device. The administrators need to set up the server and then it will do its magic.
If you want to know a bit more about the DHCP, you can read a full article HERE.
DNS (Domain Name System) also works with IP addresses for people’s convenience but in another way. As we said before, each device on the internet has its unique address. The same goes for the websites (domains). We, the people, don’t want to remember a different number combination for every site we like. We simply want to puts the most natural thing – its name. However, the name is not an address. The DNS kicks in here. It receives this name and searches the internet for the location of the name server, where it finds the information about the location of the data (the IP address). This process is called Domain Name Resolution. We recommend you this article about DNS if you want to understand it better.
DNS vs DHCP
Here we have made a comparison table for some of the more important parameters of the two:
|Purpose||Resolving domains||Assigning IP’s to the host|
|Features||Translates the written names of domains to IP addresses||Provides the IP addresses of the host, router, name server and subnet mask of the computer.|
|Purpose||You can use it for locating the Active Directory domain servers||It can provide IP to host for limited time|
|Port that it uses||53||67 and 68|
|Method of working||Decentralized||Centralized|
|Benefit||Eliminates the need to keep in mind all the IP addresses||Very reliable method of assigning IP addresses|
As you see, the two have a very different purpose but yet both of them are very useful for us, the people. There is no rivalry DNS vs DHCP. The internet is a complicated place, but technologies like DNS and DHCP makes it easy for us. We hope that after reading this article, you understand it a bit better.