Score:1

Using router's DNS on Ubuntu 22.10

cx flag

I'm running multiple Ubuntu VMs and would like to refer to them by hostnames when using ssh instead of their IPs. Because I don't want to add every server to every /etc/hosts I thought using DNS aliases would be best.

I setup a VM to run dnsmasq and made some entries of IP to hostnames, along with using 8.8.8.8 as a backup. Then I created a custom DNS config on my router to point to that VM (with 8.8.8.8 as a backup there too).

Machines like my Macbook follow the router's DNS settings and use the VM for lookup, but my other Ubuntu VMs don't. How can I make Ubuntu use my router for DNS?

RonJohn avatar
cn flag
Have you rebooted the Unbuntu server (or at least restarted networking)?
CliffAnderson avatar
cx flag
Yes, they've been rebooted with no change to behavior
RonJohn avatar
cn flag
What does network-mangler say? Maybe you need to explicitly tell it what DNS server to use.
SkiBum avatar
cm flag
Have you thought about enabling Dynamic DNS on your router? That will create a DNS entry for the hosts as they get their DHCP created IP address.
CliffAnderson avatar
cx flag
It doesn't look like my router supports dynamic DNS. I think I've determined the issue. systemd-resolved is running using port 53. dnsmasq can't run as well if port 53 is in use, but it also seems like systemd-resolved needs to be running for dnsmasq to run
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.