How to Setup Windows DNS Server and Configuration on Windows 2022

How to Setup Windows DNS Server and Configuration on Windows 2022. In this post, we will introduce DNS server, it’s working process then move on to the DNS server setup and zone creation phase.

Primarily DNS server is highly important as, without it, you would not be able to find any website. It is a globally distributed service organized in a hierarchy with each section denoting a subdivision.

Let’s dive into this article blog about How to Setup Windows DNS Server and Configuration on Windows 2022.

What is DNS Server?

DNS servers are quite similar to phonebooks and are crucial part of the Internet. What DNS servers do is they help convert website names into IP addresses so that machines can understand the query and load the requested pages for users. Thus, making it easier and quicker for users to access them online.

In simple terms, the domain name system (DNS) is a naming database that stores information about domains and their corresponding IP addresses. It also translates human readable domain names into their corresponding IP addresses, IPv4 or IPv6, which are not easy for humans to remember and type out.

When someone types in a domain name like “www.google.com” in the browser, it sends a request to the DNS server for its corresponding IP address (usually an IPv4 address). The DNS server then checks its database for the requested domain name, finds it and returns its corresponding IP address back to the browser, which then uses this information to connect with the website.

A DNS server is a type of name server that responds to queries from other computers, such as web browsers and email clients. Organized is a hierarchical naming system for computers, services, or any resource connected to the Internet or a private network, it associates various information with domain names assigned to each of the participating entities.

There are different types of DNS servers, including recursive server, root name server, TLD server, and authoritative name server.

How Does a DNS Server Work?

Basically DNS converts the domain name into IP addresses for computers to read, understand and use. The minute a user types his query or domain into a browser, the DNS service translates the user type into Internet Protocol (IP) addresses understandable by the machine.

In return, the machine finds and delivers the requested webpage. This whole process of translating and discovering the requested data is referred to as DNS resolution.

DNS Resolution Process

Here are the following steps included in the DNS resolution process:

  • User types in his/her query or a domain name into the browser.
  • The Browser forwards the recursive DNS query or message to the network to discover the corresponding IP address.
  • The query is then passed to a recursive DNS server managed by ISP. Once the recursive DNS server receives the address, it looks for the page and loads it for the user.
  • In case the recursive DNS server fails to find the right answer to the user’s query, it will query other servers. Firstly, it will check with the DNS root name servers, then top level domain (TLD) name servers, and finally authoritative name servers.
  • These servers work together and redirect until they retrieve a DNS record containing the right answer for the requested query.
  • The recursive server also caches the information for the future. What it does it makes sure the next time a similar request occurs, it will respond directly rather than querying with a series of other servers.
  • In case the authoritative name servers also failed to find the information, an error message is returned to the user.

A domain name server (DNS) performs this entire process in a fraction of seconds. Consequently the DNS protocol is the set of rules for querying and updating these servers, which define how the Internet’s Domain Name System (DNS) works.

A simple way of looking at the process is it uses a recursive server that translates domain names into Internet Protocol (IP) addresses and asks on behalf of the user.

Now it is time to learn steps in how to Setup Windows DNS Server and Configuration on Windows 2022.

Setup Windows DNS Server and Configuration on Windows 2022

Prerequisites

  • A user with administrative privileges.
  • Minimum 4 GB of RAM with 2 Cores CPU.

Install DNS Server

Log in to the Windows Server as an administrator user and follow the steps given below to install the DNS server on Windows server 2022.

Step 1 – Open the Server Manager as shown below:

Step 2 – Click on Add roles and features. You should see the before you begin screen:

Step 3 – Click on the Next button. You should see the select installation type screen:

Step 4 – Select Role-based and feature-based installation and click on the Next button. You should see the select destination server screen:

Step 5 – Select the server from the server pool and click on the Next button. You should see the roles selection screen:

Step 6 – Select the DNS server and click on the Next button. You should see the confirm installation screen:

Step 7 – Verify all settings and click on the Install button to start the installation. You should see the installation progress screen:

Step 8 – Wait for some time to finish the installation. Once the installation is complete, click on the Close button to close the installation wizard.

Create a Forward Lookup Zone

Next, you will need to create a forward lookup zone to resolve the name to IP address. Follow the below steps to create a forward lookup zone:

Step 1 – On the server manager, click on the Tools => DNS to open the DNS manager as shown below:

Step 2 – Right click on the server name. You should see the following options:

Step 3 – Click on the New Zone. You should see the zone configuration wizard screen:

Step 4 – Click on the Next button. You should see the zone type selection screen:

Step 5 – Select the Primary zone and click on the Next button. You should see the following screen:

Step 6 – Select Forward lookup zone and click on the Next button. You should see the following screen:

Step 7 – Provide your zone name and click on the Next button. You should see the following screen:

Step 8 – Select “Create a file with the file name” and click on the Next button. You should see the Dynamic update screen:

Step 9 – Select “Do not allow dynamic update” and click on the Next button. You should see the following screen:

Step 10 – Click on the Finish button. You should see your forward lookup zone in the following screen:

verify forward zone

Create a Reverse Lookup Zone

Following step is for you to create a reverse lookup zone to resolve the IP address to the name. Follow the below steps to create a reverse lookup zone:

Step 1 – On the DNS manager, right click on the server name and click on the New Zone. You should see the zone creation wizard:

Step 2 – Click on the Next button. You should see the zone type selection screen:

Step 3 – Select the Primary zone and click on the Next button. You should see the following screen:

Step 4 – Select “Reverse lookup zone” and click on the Next button. You should see the following screen:

Step 5 – Select IPv4 Reverse Lookup Zone and click on the Next button. You should see the following screen:

Step 6 – Define your network id and click on the Next button. You should see the following screen:

Step 7 – Select “Create a file with this file name” and click on the Next button. You should see the Dynamic update screen:

Step 8 – Select “Do not allow dynamic updates” and click on the Next button. You should see the following screen:

Step 9 – Click on the Finish button. You should see your reverse lookup zone on the following screen:

Add A and PTR Records to DNS

Further, you will need to add A and PTR records for remote hosts to perform name resolution. Follow the below steps to add A and PTR records to DNS:

Step 1 – On the DNS manager, right click on the forward lookup zone. You should see the following screen:

Step 2 – Click on the New Host (A or AAAA). You should see the following screen:

Step 3 – Provide the parent domain name and IP address of your host, and select “Create associated pointer record” then click on the Add Host button. Next, click on the forward lookup zone, you should see your added A record on the following screen:

Verify DNS Name Resolution

At this point, DNS server installation and configuration is finished. Now, we will need to test whether the DNS name resolution works or not.

Open your command line interface and run the nslookup command:

				
					nslookup
				
			

You should see the following output:

				
					Default Server:  web.exampledns.com
Address:  208.117.85.195
				
			

Now, type the FQDN of your added host:

				
					> web.exampledns.com
				
			

You should see the name to IP address resolution in the following output:

				
					Server:  web.exampledns.com
Address:  208.117.85.195

Name:    web.exampledns.com
Address:  208.117.85.195

				
			

Then type the IP address of your added host:

				
					> 208.117.85.195
				
			

And you should see the IP address to name resolution in the following output:

				
					
Server:  web.exampledns.com
Address:  208.117.85.195

Name:    web.exampledns.com
Address:  208.117.85.195

				
			

Thank you for reading this article about how to Setup Windows DNS Server and Configuration on Windows 2022.

How to Setup Windows DNS Server and Configuration on Windows 2022 Conclusion

In this How to Setup Windows DNS Server and Configuration on Windows 2022 post, we explained how to install a DNS server, create a forward and reverse lookup zone then add A/PTR records to DNS. I hope you can now easily deploy your own DNS server for local name resolution in your organization.

Additionally, it is quite challenging to remember a website’s IP address, but with DNS servers you do not have to worry much. They help translate long IP addresses into human readable domain names, which are quite easy to remember and use. Lastly, you can quickly make online transactions with a DNS server and innovative features, such as AI based searches and chatbots.

Read our content about DNS servers here

Avatar for Hitesh Jethva
Hitesh Jethva

I am a fan of open source technology and have more than 10 years of experience working with Linux and Open Source technologies. I am one of the Linux technical writers for Cloud Infrastructure Services.

0 0 votes
Article Rating
Subscribe
Notify of
0 Comments
Most Voted
Newest Oldest
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x