what are DNS search domains ?

Questions about Wi-Fi and other network devices, file sharing, firewalls, connection sharing etc
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
Rotten Hero
Level 1
Level 1
Posts: 4
Joined: Wed Dec 08, 2021 10:28 am

what are DNS search domains ?

Post by Rotten Hero »

I was looking to change my DNS but it also asks for "search domains" what are those?
my system details: Linux Mint 20.2 xfce 64bit
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
ARC1450
Level 1
Level 1
Posts: 3
Joined: Fri Dec 20, 2019 12:35 pm

Re: what are DNS search domains ?

Post by ARC1450 »

Simple answer:

In general, you don't need search domains. You'll know when you need to fill that box in with information.

Long answer:

They're what gets automagically tacked onto hostnames.

This forum has 3 DNS components:
  1. forums
  2. linuxmint
  3. com
"com" is what's known as a "top level domain", one of the end-all-be-all names on the Internet. "linuxmint" is the domain name and can literally be anything as long as it adheres to certain naming standards (like no starting with weirdo characters). "forums" is *technically* the hostname (though there's way more to it than just that underneath). There's also an implicit "." at the end of domain names as "." is what is know as the "root" of DNS.

Now to tie it all together. If, for example, you set "linuxmint.com" as a search domain, in your browser you could simply type "forums", hit enter, and you'd be directed here because what resolves DNS on your computer would tack ".linuxmint.com" onto anything that doesn't end with a period.

If you want more info or that doesn't make sense, just ask.
Rotten Hero
Level 1
Level 1
Posts: 4
Joined: Wed Dec 08, 2021 10:28 am

Re: what are DNS search domains ?

Post by Rotten Hero »

i understand what you said but it also wants a search domain with a dns so what do i enter in search domains box or is there a way i can skip adding a search domain?
User avatar
Bluray
Level 1
Level 1
Posts: 23
Joined: Mon Oct 26, 2020 9:51 pm

Re: what are DNS search domains ?

Post by Bluray »

Rotten Hero wrote: Thu Dec 09, 2021 3:24 am i understand what you said but it also wants a search domain with a dns so what do i enter in search domains box or is there a way i can skip adding a search domain?
A "search domain" is only needed for your local network. All DNS queries that are fully qualified (FQDN) such as forums.linuxmint.com will be sent to your specified external DNS server for resolution to an IP address. This is for resolving external hosts. If you have multiple PCs/devices at home their names cannot be resolved by an external DNS server.

If you want your internal devices to be resolvable to an IP address, you would need to either use the hosts file on each device, or create an internal DNS server.

The "search domain" is to tell your PC what to do to resolve names that are not fully qualified. If you called your PC server1, then your PC will try to resolve "server1" using the hosts file first, if there is no entry for server1 in the hosts file it will try to add the "search domain" to server1 (server1.localdomain) and try to resolve that using your DNS server entry. It will obviously not get a valid answer for server1.localdomain.

You could make up a domain for internal use if you have other devices to connect with on your local network such as mydomain.local for example.
Locked

Return to “Networking”