article suggestion - HomeLAN DNS server

Notice: Page may contain affiliate links for which we may earn a small commission through services like Amazon Affiliates or Skimlinks.

Joel

Active Member
Jan 30, 2015
851
191
43
42
So I'm loving the idea of having my own DNS server on my LAN, now that I have a bunch of services running. However the execution is getting my head spinning, especially when I want to combine the best of DHCP and DNS. And I consider myself decent with navigating CLIs & Ubuntu/Debian...

For example, I'd love to be able to type into my browser:

router.lan
portainer.lan
proxmox.lan
nextcloud.lan
couchpotato.lan
canonprint.lan
kodiTV.lan
etc.

instead of having to remember 18,000 IP/port combinations, especially when DHCP gets funny and changes IPs on me. Side bonus to this is that LastPass would get less confused, since I have quite a few services running on different ports from the same IP address on the main server.

Many of the static devices I'm ok with configuring static IPs, but I'd like to not need to worry about that (bind via MAC address?).

Bonus points for being able to cache external DNS requests as well which would provide a slight speed increase to browsing, etc.

So that brings my requirements to:
1. Authoritative DNS & DHCP combined server for .lan domain.
2. External caching DNS server.
3. Web GUI, because why not?



If it helps/matters, my physical network layout:
Cox modem -> Netgear Router
Some powerline adapters, one of which is a wifi repeater
Second router acting as wifi repeater
Raspberry Pi for farting around (want to purpose this as the .lan authoritative DNS server)
Raspberry Pi 3 for Kodi
2x2667v2 server (Proxmox, mining, file server, NextCloud, CouchPotato, & too many services to list)
Windows 10 laptop
Ipad
Android phone
Sony Blu ray player
Two network printers
Allowance for guest devices to be assigned by DHCP.
 

ttabbal

Active Member
Mar 10, 2016
743
207
43
47
I would recommend using ".local", as this is what it's for. I'd you run the right services, most machines will work without special configuration. On linux, "avahi" is what you want. And usually some package to enable mdns lookup.

If you run dhcp and dns on a Linux or pfsense, most machines will register with their host name as well. You can assign static addresses in the DHCP server by MAC address. I usually let the machines start dynamic and assign a static as needed. That way, the server already knows the MAC and I don't have to type it. :) I use pfsense for that, I just click on the one I want and give it an address. You can also add whatever DNS records you want to use.

My preference is to assign servers, switches, routers, and printers static addresses manually. That way they always work, even if the gateway/dhcp server is down.
 
  • Like
Reactions: wsuff