0

I have set my LAN local domain to be local.example.com on my router, an ordinary Verizon FiOS wireless broadband router with no special configuration.

All of the hosts are apparently being correctly assigned their host name, e.g.:

$ hostname
pc.local.example.com

Yet, a lookup for the host yields:

$ nslookup $(hostname)
Server:     192.168.1.1
Address:    192.168.1.1#53

Non-authoritative answer:
Name:   pc.local.example.com
Address: 12.34.56.78

where 12.34.56.78 is the address provided by my external web hosting service, e.g. serving www.example.com on the Internet.

How can I configure DNS on my LAN's router to resolve the correct local addresses, e.g., 192.168.1.x, as opposed to performing this lookup via the DNS server addresses it is configured to use?

  • You need a router that allows you to host your own local DNS. – qasdfdsaq Nov 11 '15 at 23:49
  • Actually his router appears to be caching DNS, however my router does that too.. Just no method to add local DNS entries in many routers. @qasdfdsaq – Tyson Nov 12 '15 at 1:21
  • Thanks for your thoughts on this - you'll see below that this was simply an error on my part when setting up the router configuration. All works as expected once corrected. – Danny Whitt Nov 12 '15 at 6:28
1

This is resolved.

The local domain was incorrectly entered in the router's configuration as local.exampl.com (notice the missing e).

Upon correcting this, the local host names are, of course, resolving correctly:

$ nslookup $(hostname)
Server:     192.168.1.1
Address:    192.168.1.1#53

Name:   pc.local.example.com
Address: 192.168.1.2

Human error at work once again!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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