DNS Configuration: Everything You Need to Know (2024)

Introduction

DNS configuration sets up a Domain Name System server to translate domain names (URLs) into IP addresses. The configuration helps manage the DNS records for domains.

Knowing how to configure a DNS server is essential for any network administrator. The steps to configure a DNS differs depending on the operating system.

This article shows how to configure DNS on a Windows, macOS, and Linux machine.

DNS Configuration: Everything You Need to Know (1)

Prerequisites

  • A stable internet connection.
  • Access to an account with administrator privileges.
  • Access to the command line/terminal.

Why Change DNS Configuration?

Internet service providers use a preconfigured DNS server to filter traffic. There are many reasons to change the default DNS configuration, such as:

  • Speed improvements. A DNS maps domain names to IP addresses. Custom DNS configuration helps improve domain name resolution times, which reduces the time needed to access a website.
  • Greater security. Specific DNS servers block malicious web pages and focus on preventing access to unsafe websites. Changing the DNS configuration to use such servers improves internet security and restricts exposure to online threats.
  • Customized experience. Configure the DNS to block access to specific web pages or reroute domain names to different addresses. For example, some DNS servers help create a family-friendly environment by blocking access to unsafe or suspicious websites.
  • Privacy. Some DNS servers log internet queries for advertising purposes. Changing the DNS configuration to a privacy-focused server enables better control over online privacy.
  • Troubleshooting. Changing to a different DNS server is crucial in troubleshooting DNS issues.

There are many free DNS resolvers available. While some solely focus on reducing DNS lookups and speed improvements, other resolvers aim to provide an additional security and filtering layer.

The table below shows example providers, the purpose of the DNS, and the IPv4 and IPv6 addresses:

ProviderPurposeIPv4 AddressesIPv6 Addresses
GoogleSpeed improvements.8.8.8.8
8.8.4.4
2001:4860:4860::8888
2001:4860:4860::8844
CloudflareSpeed improvements.1.1.1.1
1.0.0.1
2606:4700:4700::1111
2606:4700:4700::1001
Quad9Filters malware, phishing, and exploits.9.9.9.9
149.112.112.112
2620:fe::fe
2620:fe::9
OpenDNSSecurity filtering and user-defined policies.208.67.222.222
208.67.220.220
2620:119:35::35
2620:119:53::53

The table shows a brief list of popular DNS servers. Research further to find a DNS resolver for your use case.

How to Change DNS Configuration on Windows

Changing the DNS configuration on Windows OS requires administrator privileges. Below are instructions to change the DNS configuration on a Windows 10/11 or Windows Server machine.

Windows 10/11

To change the DNS configuration on Windows, do the following:

1. In the Start menu, search for Network Status.

2. Select Change adapter options.

DNS Configuration: Everything You Need to Know (2)

3. Right-click the network connection and open Properties.

DNS Configuration: Everything You Need to Know (3)

4. Locate and select the Internet Protocol Version 4 (TCP/IPv4) option from the list.

5. Click the Properties button to open the IPv4 settings.

6. Select the Use the following DNS server addresses option.

7. Fill out the primary and secondary addresses. For example, to use Google's DNS resolver addresses, set 8.8.8.8 as preferred and 8.8.4.4 as alternate.

8. Click OK to save the changes.

DNS Configuration: Everything You Need to Know (5)

Restart the browser to apply the changes.

Windows Server

To change the DNS configuration on a Windows Server, follow the steps below:

1. Open the Start menu.

2. Search for Control Panel and press Enter.

DNS Configuration: Everything You Need to Know (6)

3. Open the Network and Sharing Center.

DNS Configuration: Everything You Need to Know (7)

4. In the left pane, select Change adapter settings.

DNS Configuration: Everything You Need to Know (8)

The steps after this are similar to Windows 10/11 machines.

5. Right-click the connection and open Properties.

6. Double-click the Internet Protocol Version 4 (TCP/IPv4) option on the list.

7. Set the preferred and alternate DNS server address in the fields, and click OK to apply the changes.

Note: If you use an Active Directory domain, enter the loopback address from the IP field and set up a DNS forwarder with the public DNS addresses instead.

How to Change DNS Configuration on Linux

The following steps work on Ubuntu 22.04. The steps can slightly differ between different Linux distributions.

To permanently change the DNS configuration on Linux, do the following:

1. Open the terminal (Ctrl+Alt+T).

2. Open the resolv.conf file using a text editor, such as nano:

sudo nano /etc/resolv.conf

3. Add primary and alternate DNS addresses above the current configuration:

nameserver 8.8.8.8nameserver 8.8.4.4
DNS Configuration: Everything You Need to Know (9)

The addresses use Google's DNS resolver. Replace the IPs with your preferred DNS.

4. Save the file and close nano.

5. To ensure the changes persist after restarting the machine, use the resolvconf tool. Install it with the following command:

sudo apt install resolvconf

Wait for the installation to complete and proceed to the next step.

6. Start and enable the service with the following two commands:

sudo systemctl start resolvconf.service
sudo systemctl enable resolvconf.service
DNS Configuration: Everything You Need to Know (10)

7. Edit the configuration file:

sudo nano /etc/resolvconf/resolv.conf.d/head

8. Add the following lines above all other configurations:

nameserver 8.8.8.8nameserver 8.8.4.4
DNS Configuration: Everything You Need to Know (11)

9. Save the file and close the text editor.

10. Restart the service:

sudo systemctl restart resolvconf.service

11. Confirm the changes applied:

resolvectl status
DNS Configuration: Everything You Need to Know (12)

The addresses show as the current DNS server for the Global settings. Alternatively, run the dig command:

dig phoenixnap.com
DNS Configuration: Everything You Need to Know (13)

The SERVER section shows the DNS addresses.

How to Change DNS Configuration on macOS

To change the DNS configuration on macOS, follow the steps below:

1. Open Apple Menu->System Settings.

DNS Configuration: Everything You Need to Know (14)

2. Open the Network settings from the left menu.

3. Choose the network from the list in the right pane (Wi-Fi or Ethernet).

DNS Configuration: Everything You Need to Know (15)

4. Click the Details button to view the connection settings.

DNS Configuration: Everything You Need to Know (16)

5. Switch to the DNS tab in the left pane.

6. Click the plus (+) button to add DNS server addresses.

DNS Configuration: Everything You Need to Know (17)

7. Add the primary and secondary addresses for the DNS server.

8. Click OK to save the changes and apply the settings.

DNS Configuration: Everything You Need to Know (18)

Restart the browser to test and see the changes.

How to Change DNS Configuration on Router Level?

Changing DNS configuration on a router level affects all connected devices, such as computers, smartphones, and any additional smart device that uses Wi-Fi. Routers that manage multiple signals, such as a phone or TV signal, often do not allow changingDNS settingsat all.

The precise instructions to change the DNS configuration on a router are different for every model. Check the router's instruction manual to see if there are specific steps and guidelines. Alternatively, search for the router name and model and add the "change DNS configuration" phrase.

Conclusion

After going through the steps in this guide, you know how to set up a custom DNS configuration on three different operating systems. Configuring DNS comes with many benefits, and it is essential for proper network administration.

Next, read about the best DNS practices for security and performance.

DNS Configuration: Everything You Need to Know (2024)

FAQs

How to configure DNS server step by step? ›

From the Windows desktop, open the Start menu, select Windows Administrative Tools > DNS. Select and hold (or right-click) your server, and then select Properties. To limit the DNS server to use a specific IP address, select Only the following IP address, select the IP address you wish to use, and then select OK.

What is a DNS configuration? ›

DNS configuration sets up a Domain Name System server to translate domain names (URLs) into IP addresses. The configuration helps manage the DNS records for domains.

Is 1.1 1.1 still the fastest DNS? ›

Cloudflare's 1.1.1.1 DNS service has been ranked as the fastest DNS resolver globally by the independent DNS monitor DNSPerf. Cloudflare's network extends to 310 cities worldwide, enabling quick DNS response times for users globally, hence recommended for excellent speed and stability.

What does DNS stand for in tryhackme? ›

What does DNS stand for and what is it used for? Domain Name System. It's what is remembered as the website name so you don't have to memorize IP addresses when you're trying to go to a specific page.

How do I setup my own DNS? ›

Windows 11
  1. Right-click Start and select Network connections.
  2. Choose the network type your device is using (Wi-Fi or Ethernet).
  3. Find the DNS server assignment option and click Edit.
  4. Choose Manual from the dropdown menu and enable IPv4.
  5. Fill in the DNS fields. ...
  6. Click Save.
Jun 17, 2024

What are the 3 main steps that a DNS server goes through? ›

  • Below is the working of DNS.
  • Step 1: Query from client to DNS Server.
  • Step 2: Translate the domain name to IP address.
  • Step 3: Search for the query using Root Name Servers.
  • Step 4: Search for the query using TLD server.
  • Step 5: Request for full version of domain name by Authoritative DNS server.
Apr 19, 2024

Can I use 1.1 1.1 and 8.8 8.8 at the same time? ›

You can use multiple providers. The downsides should be minor to non-noticeable. #1 - They may respond differently due to caching. If a site is changing their IP addresses, it may be cached for longer with one provider than the other.

Is DNS 8.8 8.8 and 8.8 4.4 safe? ›

Google Public DNS has been available since 2009, with easy-to-remember IP addresses of 8.8.8.8 and 8.8.4.4. Google promises a secure DNS connection, hardened against attacks, as well as speed benefits.

What is 8.8 8.8 DNS? ›

The Google domain name system has two primary IP addresses: 8.8.8.8 and 8.8.4.4. These are the domain name system servers for Google and essentially Google's public IPs.

Can hackers hijacking DNS? ›

Domain Name Server (DNS) hijacking is a type of DNS attack where an attacker purposefully manipulates how DNS queries are resolved so as to redirect users to malicious websites. Hackers either install malware on user PCs, seize control of routers, or intercept or hack DNS connections to carry out the attack.

What is DNS secret? ›

DNSSEC protects against attacks by digitally signing data to help ensure its validity. In order to ensure a secure lookup, the signing must happen at every level in the DNS lookup process.

What does cname stand for? ›

A canonical name (CNAME) is a type of Domain Name System (DNS) database record that indicates that a domain name is the nickname or alias for another domain name. Also referred to as the "true name," the CNAME is especially important when multiple services run from a single IP address.

How do I setup a DNS 1.1 1.1 server? ›

Android 9 or 10
  1. Go to Settings > Network & internet.
  2. Select Advanced > Private DNS.
  3. Select the Private DNS provider hostname option.
  4. Enter one.one.one.one and select Save. Or consider the following options if you want to use 1.1.1.1 for Families.

How do I configure local DNS? ›

DNS Configuration
  1. In the Local Area Connection Properties dialog box, click Internet Protocol (TCP/IP), and then click Properties.
  2. Next, click Use the following IP address, and then type the static IP address, subnet mask, and default gateway for this server.
  3. In Preferred DNS, type the IP address of this server.

How to configure DNS using command prompt? ›

Change DNS Settings using Command Prompt
  1. Open the Windows Run dialog (Winkey ⊞ + R).
  2. Next, type CMD into the open field.
  3. Press Ctrl+Shift+Enter on your keyboard. ...
  4. Type netsh and hit the Enter This will launch the Network Shell (netsh>).
  5. Next, enter interface IP show config and press Enter once again.
Aug 1, 2024

How to configure DNS for client server? ›

To modify the domain controller's DNS client configuration, follow these steps:
  1. Right-click My Network Places, and then select Properties.
  2. Right-click Local Area Connection, and then select Properties.
  3. Select Internet Protocol (TCP/IP), and then select Properties.
  4. Select Advanced, and then select the DNS tab.
Dec 26, 2023

Top Articles
Clearing cached and saved Mac OS credentials - IST Knowledge Base
SDG 5: Gender Equality and SDG 10: Reduced Inequalities
Walgreens Harry Edgemoor
Uhauldealer.com Login Page
Shoe Game Lit Svg
Visitor Information | Medical Center
Savage X Fenty Wiki
Moe Gangat Age
Missing 2023 Showtimes Near Landmark Cinemas Peoria
Günstige Angebote online shoppen - QVC.de
Morocco Forum Tripadvisor
David Turner Evangelist Net Worth
Nioh 2: Divine Gear [Hands-on Experience]
Industry Talk: Im Gespräch mit den Machern von Magicseaweed
9044906381
Bx11
Average Salary in Philippines in 2024 - Timeular
Golden Abyss - Chapter 5 - Lunar_Angel
What Is Vioc On Credit Card Statement
Ahrefs Koopje
Curver wasmanden kopen? | Lage prijs
Glenda Mitchell Law Firm: Law Firm Profile
Lowes Undermount Kitchen Sinks
zom 100 mangadex - WebNovel
Panolian Batesville Ms Obituaries 2022
Ac-15 Gungeon
Jcp Meevo Com
Mikayla Campinos: Unveiling The Truth Behind The Leaked Content
Wonder Film Wiki
Mini-Mental State Examination (MMSE) – Strokengine
Ff14 Laws Order
Verizon TV and Internet Packages
Los Amigos Taquería Kalona Menu
Car Crash On 5 Freeway Today
Top-ranked Wisconsin beats Marquette in front of record volleyball crowd at Fiserv Forum. What we learned.
Space Marine 2 Error Code 4: Connection Lost [Solved]
Pitchfork's Top 200 of the 2010s: 50-1 (clips)
Sunrise Garden Beach Resort - Select Hurghada günstig buchen | billareisen.at
Omaha Steaks Lava Cake Microwave Instructions
303-615-0055
Tunica Inmate Roster Release
3 Zodiac Signs Whose Wishes Come True After The Pisces Moon On September 16
Gotrax Scooter Error Code E2
Wilson Tire And Auto Service Gambrills Photos
Silicone Spray Advance Auto
John M. Oakey & Son Funeral Home And Crematory Obituaries
Blue Beetle Showtimes Near Regal Evergreen Parkway & Rpx
Aloha Kitchen Florence Menu
60 Days From August 16
Craigslist Charles Town West Virginia
Psalm 46 New International Version
Ravenna Greataxe
Latest Posts
Article information

Author: Chrissy Homenick

Last Updated:

Views: 6555

Rating: 4.3 / 5 (74 voted)

Reviews: 81% of readers found this page helpful

Author information

Name: Chrissy Homenick

Birthday: 2001-10-22

Address: 611 Kuhn Oval, Feltonbury, NY 02783-3818

Phone: +96619177651654

Job: Mining Representative

Hobby: amateur radio, Sculling, Knife making, Gardening, Watching movies, Gunsmithing, Video gaming

Introduction: My name is Chrissy Homenick, I am a tender, funny, determined, tender, glorious, fancy, enthusiastic person who loves writing and wants to share my knowledge and understanding with you.