TECHNIG
Gateway for IT Experts and Tech Geeks

Install DNS in Server 2022 using Server Manager and Powershell

Domain Name System or DNS for short is a fundamental service that resolves names/services to IP addresses and sometimes vice versa. It is a key service that must be running in every network. The very first configuration regarding this topic is installing its capability on the server. Then, there are bundles of configurations and settings to understand and care about. So, as a beginner article regarding DNS, this article covers how to install DNS in Windows Server 2022 using both Server Manager and PowerShell tools.

You may also like to read: Install And Configure DHCP In Windows Server 2022 Using PowerShell.

Install DNS Using Server Manager

Using Server Manager is a user-friendly and easy method to install roles, including DNS, in Windows Server Operating Systems. We just graphically navigate through the options and install it. The steps are listed below.

1. Open Server Manager console. It is present in the Start Menu by default. If it is not, search for it.

Opening Server Manager in Windows Server 2022
Opening Server Manager in Windows Server 2022

2. On the Server Manager console, click on Manage in the top-right corner. Then, select Add Roles and Features option.

Add roles and features using Server Manger
Add roles and features using Server Manager

3. On the Before You Being page, just click on Next to continue. Choose the Role-based or feature-based installation option on Installation Type. Then, click on the Next button.

Choosing Installation Type for the Role
Choosing Installation Type for the Role

4. On the Server Selection section, choose the server on which you want to install DNS and click on the Next button, afterwards.

Selecting the Server to Install the DNS Service on it
Selecting the Server to Install the DNS Service on it

5. In this step, check out the DNS Server checkbox option on the Server Roles section. Click on Add Features on the next window that pops up. Finally, click on Next.

Selecting DNS Role to Install
Selecting DNS Role to Install

6. Click on Next on both Features and DNS Server wizards. On the Confirmation window, check out the option for the Restart if it needs to during the DNS role installation. And, finally, click on the Install button. See the picture below.

Confirming DNS Role Installation on Server
Confirming DNS Role Installation on Server

7. Wait for a few moments until the DNS role installation completes. Once completed, click on the Close button in the Result section.

DNS Installation Result Screen
DNS Installation Result Screen

As simple as the above steps, we have installed the DNS Server in Windows Server 2022 using Server Manager. Now, if you open the Tools menu on the Server Manager console, you will observe the DNS is present there.

Install DNS using Windows PowerShell

Using Windows PowerShell is always a preferred and professional method of accomplishing such tasks. Besides other benefits, it takes us less time. Now, let’s dive into the brief steps to install DNS using the Windows PowerShell tool.

1. Open Windows PowerShell as administrator. To do so, go to the Start Menu, right-click on it and choose Run as Administrator. You can also open it using the Run dialogue box by using powershellas command.

Opening Windows PowerShell as administrator
Opening Windows PowerShell as an administrator

2. Once you have opened the PowerShell tool, check the DNS if it is available to install. To check the DNS, use the Get-WindowsFeature DNS command. As you can see in the picture below, it is available to install.

Check DNS Status Using PowerShell Command
Checking DNS Feature Status Using PowerShell Command

3. To install DNS run Install-WindowsFeature DNS -IncludeManagementTools PowerShell command. Then, wait for a while until it finishes the installation process.

Install DNS Using Windows PowerShell Command
Install DNS Using Windows PowerShell Command

4. Now that we have installed DNS, once more, run Get-WindowsFeature DNS PowerShell command to verify the installation. You can see in the below picture that it is installed.

Verify DNS State Using Windows PowerShell Command
Verify DNS State Using Windows PowerShell Command

5. It is also the right point to mention how we can uninstall DNS using Windows PowerShell. To uninstall it, run Remove-WindowsFeature DNS PowerShell command. Wait for a moment until it completes the operation. You will receive a message to restart the server if it needs to. you can restart the server using Restart-Computer PowerShell command.

Uninstalling DNS Using Windows PowerShell Command
Uninstalling DNS Using Windows PowerShell Command

That is it. We learned how to install and uninstall the DNS in Windows Server 2022 using Windows PowerShell.

Summery

To summarize this article, we have walked through a step-by-step guide on how to install DNS service in Windows Server 2022 using Server Manager and Windows Powershell tools. We covered a detailed illustration to install DNS using Server Manager, first. Then, in a separate section, we discussed the PowerShell commands to install, verify and uninstall DNS in Server 2022.

In the end, I hope you find this article helpful. If you have any further questions, do not hesitate to share us in the comment section.

Leave A Reply

Your email address will not be published.

This website uses cookies to improve your experience. We'll assume you're ok with this, but you can opt-out if you wish. Accept Read More