Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am attempting to set up a LAN's domain-name server. My router has a given domain name from the ISP- something like

I would like to assign my local computers names such as, gizmo, gadget, wizbob, etc.

In my bind(9) configuration file, I have this comment from the prefab file:

# This is the zone definition. replace with your domain name
zone "local-network" IN {
        type master;
        file "/etc/bind/zones/local-network";

But, I don't really have a domain name! How do I resolve this?

share|improve this question
... Queue the arguments about using ".local" as a TLD for internal DNS – Mark Henderson Jul 23 '10 at 3:34
@Farseeker: Bah. I'll just go with local-mynetwork-epic-lan-never-a-real-tld. ;) – Paul Nathan Jul 23 '10 at 3:50
Just remember, from a marketing view a hyphenated domain stinks of desparity. Perhaps you want localmynetworkepiclanneverarealtld. – Mark Henderson Jul 23 '10 at 4:01
up vote 3 down vote accepted

You can use a fictional top level domain like "lan" or "local"

share|improve this answer
Despite the arguments some have made to the contrary, I've always liked "local", as it is unlikely in the extreme that it will ever become a TLD. +1 – John Gardeniers Jul 23 '10 at 4:29
@John: but it has already become the tld for zeroconf. even if you don't agree on its usage, you have to agree that its usage is problematic, nowadays. – hop Jul 23 '10 at 11:32
@hop, the idea is to use a LAN TLD that won't clash with anything on the Internet. As I understand it, zeroconf is not Internet facing, so I don't see the problem. – John Gardeniers Jul 23 '10 at 12:21
@hop: yeah, I decided on .network.lan. for the TLD. I have an apple machine on the network, and .local might confuse it to the point of making it cry. And we don't want to see crying apples. That's just weird. – Paul Nathan Jul 23 '10 at 16:13
I use to use .local but with the number of Linux distros that include mDNS these days I have switched to .lan, even though .lan is unofficial. – Micheal Johnson Dec 11 '15 at 16:50

As long as it is only going to be used for lookup inside your LAN you can use any top-level domain you want. It is perfectly fine to tell your local bind about the zone "nathan", which then would consist of gizmo.nathan., gadget.nathan., etc.

share|improve this answer

You can use a fully qualified domain name that you do not own. However, if you're going to go down this route, make sure you pick an FQDN that is not and could never be owned by a third party. So pick one ending with .lan or .local, as Zaid suggests.

The reason for doing this is that if any of your machines are ever used off your local network (e.g. one of them is a laptop and you take it to a cafe), that machine will be trying to resolve network names with the FQDN you chose, on the public internet. If someone else owns that domain on the 'net, then those requests are going to end up on their doorstep.

Thanks to a DNS client feature in Windows called 'DNS devolution', even if the exact target DNS name doesn't exist on that remote network, the request will get re-sent with just the base domain name e.g. if you try and resolve and it fails, the machine will then go out and just request, then finally just com.

Long story short, either buy an externally recognised domain name (it's cheap!), or go with the not-fully-supported-but-still-acceptable .lan or .local suffixes.

share|improve this answer

It really isn't a good idea to use any random thing for your DNS domain, simply because new top-levels are coming into existence all the time. That said, its safer if you chose a longer one. The list of assigned names can be found here:

If your domain ever shows up in that list, you'll have to redo your DNS setup on something else. Otherwise, anything legitimately in that domain won't be reachable from your network.

share|improve this answer

Just go and buy a real domain.

Making up your own domain for local use introduces a chance of name collisions. For the sake of 10 bucks or so each year it's really not worth it.

You don't have to delegate it (i.e. publish NS records) so that it's visible to the rest of the world, just keep it internal.

share|improve this answer

you might find dnsmasq a very handy tool. Its dead easy to set up, and can do your LAN dhcp / dns. Its great for small networks and esp if you want to avoid the headache of bind configuration.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.