Server doesn't respond to top level ".local" domain name but my other devices do

I have Ubuntu Server 22.04 on my network. I have my router (Fresh Tomato) resolving local domain names. Weirdly, I can ping or navigate in a browser to any device with <hostname>.local except for the server which I can only ping or connect to my Nextcloud with JUST <hostname>.

If I ping <hostname> from another device the return is:

64 bytes from <hostname>.local (

but if I ping <hostname>.local I get “name or service not known”

Alternatively, from the server itself I can ping it’s own <hostname>.local address and the output is the same as above.

64 bytes from <hostname>.local (

If I ping <hostname> from the server itself it returns

64 bytes from hostname (

Any idea what is up? Would be great to have consistency across my whole network.

How does your hosts file and hostname file look?

cat /etc/hosts localhost breakfast
# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters

Servers hostname is breakfast (it’s the most important meal of the day I’m told)

cat /etc/hostname


Looks the same as my desktop’s hosts and hostname files (other than the actual name of course)

As far as I know, you aren’t supposed to use .local as a TLD, because mDNS can interfere with it, so you could try to change it to something else like .lan instead.

1 Like

I concur however, you might be able to try setting in your /etc/hosts: breakfast.local breakfast

See how that works…

I think I recall hearing this somewhere but forgot about it. I changed the domain in the router to .lan and that fixed the issue instantly. Thanks!

You’re welcome, glad to help.