0

I'd like to have a very short internal TLD, go, pointed at a webserver hosting a URL redirection app. For instance, a user could type go/chat or go/news without the need to remember what the exact URL is.

I've set up my internal DNS server with a zone file as follows:

$ttl 3600
go. IN  SOA localhost. dns.company.corp. (
            1597456469
            3600
            600
            1209600
            3600 )
go. IN  NS  localhost.
@   IN  A   10.0.88.10

From a Windows host using nslookup, this appears to work perfectly:

>nslookup go
Server:  dns1
Address:  10.0.40.10

Non-authoritative answer:
Name:    go
Address:  10.0.88.10

(with similar results on Linux)

However, no web browsers I've tried are able to resolve this name correctly. Chrome, Firefox, Edge, and IE all act as if this http://go domain name doesn't exist, that is, unless I include an extra period on the address (http://go.), upon which it resolves properly.

I've already tried the basics. Flushed DNS, rebooted, etc.

What's the right way to allow a "naked" TLD like this to be resolvable? Is this even possible?

Mikey T.K.
  • 1,367
  • 2
  • 15
  • 29
  • If you're setting the NS to `localhost`, why not put the IP in the `hosts` file? – tater Aug 15 '20 at 02:35
  • 3
    Why don't you just add your _real_ domain to the client's domain search list? (Or it may already be there.) Then you can just add a DNS entry for `go` in your domain, and it will act as you wish. – Michael Hampton Aug 15 '20 at 02:39

1 Answers1

1

The reason your browsers are showing a "non-existent domain" error when browsing to http://go is because they are appending a DNS suffix to the hostname (whether one exists, or the browser appends a null suffix). One still gets appended.

To achieve what you want to do, you need to either add the . to the end of the URL, so the browser sees it as an absolute address or configure a DNS zone e.g. example.internal, set the hostname for the webserver to go.example.internal, configure the DNS suffix on the PCs to example.internal (either manually or via DHCP) and then you can browse to http://go

Or you can add the hostname "go" to the hosts file of every PC that will need to connect to it.

http://www.dns-sd.org/TrailingDotsInDomainNames.html

Christopher H
  • 338
  • 2
  • 16