Name resolution from UniFi UDM Pro returns VLAN IP

Hey all, slightly dumb question.

user@host:~$  nslookup monitoring
Server:		192.168.1.1
Address:	192.168.1.1#53

Name:	monitoring
Address: 192.168.11.155

except 192.168.11.x is a separate VLAN that can only talk to itself. The ‘monitoring’ host has a second IP on the native 192.168.1.x network and none of the settings has jumped out at me as a way to either give preference to resolving to the 192.168.1.x network, or even to just return both results. My google searches haven’t been helpful and just keep leading me to people having various IP leasing issues.

Not completely clear on your question, but assume 192.168.1.1 is the IP of the DNS server and that will be true even when on separate VLANS.

I am not extremely familiar with udm. Some questions for background data of my assumptions.
Where in the udm are the ip addresses listed? I assume in the dhcp services?

If so please confirm both are in the dhcp services first.

After you confirm this I would try changing the host name on one of them to monitoring-vlan for example. Then do an Nslookup on both names.

I am betting that it is simply resolving the first one found. If so, You may need to have two separate names in dhcp to achiev this.

1 Like

Ah ha! Thanks, Thedannymullen. For whatever reason, my eyes skipped right over the “Domain Name” configuration for the 192.168.11.x network. I’m sure you’re right. I’ll configure the domain for the network and the searchdomain on the other hosts. Should do the trick.

1 Like

Just a followup for anyone that got here from a google search:

UniFi will now resolve hostnames for my primary network as desired:

user@host:~$ nslookup monitoring.lan.lol 192.168.1.1
Server:		192.168.1.1
Address:	192.168.1.1#53

Name:	monitoring.lan.lol
Address: 192.168.1.230

But no joy when I ask it to resolve my VLAN network (even when I specify 192.168.11.1 as the DNS resolver).

user@host:~$ nslookup monitoring.storage.lan.lol 192.168.1.1
Server:		192.168.1.1
Address:	192.168.1.1#53

** server can't find monitoring.storage.lan.lol: NXDOMAIN

Setting the domain on the storage network/VLAN forced resolution to where I want it which is good-enough for my needs, but if you need DNS resolution for both networks, search on!

1 Like

Glad it is working. Thanks for follow up!

1 Like

Eeeh. So bad news. I’m still having issues. Changing the domain for vlan 11 just further exposes some kind of race condition going on. I can either resolve monitoring.storage.lan.lol OR monitoring.lan.lol, and which one resolves appears to be arbitrary (I’m guessing it’s based on the order the DHCP leases are fulfilled by the UDM Pro).