External DNS servers provided with use.external.dns disabled #9030
Replies: 11 comments 1 reply
-
@kriegsmanj |
Beta Was this translation helpful? Give feedback.
-
To me this means: dns is not going "instance -> vr -> external dns", but bypasses internal, "instance -> external dns" Using both internal + external at the same time, where the internal also has a host-file with all entries of instances in that network makes no sense. Some app use the resolvers in random and not just the first configured. This causes lookup errors for these hostnames when it randomly uses the external resolver to resolve an internal hostname |
Beta Was this translation helpful? Give feedback.
-
if I understand correctly, internal dns means the internal dns1/dns2 in zone setting. |
Beta Was this translation helpful? Give feedback.
-
In case of an isolated network, the resolvers configured are the Virtual Router IP and external dns1/dns2 in zone setting. The DHCP should give only the Virtual Router IP as DNS servers in case of isolated network / vpc. Else the hostname entires in the VR make no sense if it cannot used by the virtual machines. |
Beta Was this translation helpful? Give feedback.
-
I got same result as @kriegsmanj described, even if internal dns1/dns2 are set.
|
Beta Was this translation helpful? Give feedback.
-
I think the problem lies in the logic here. Based on the description in the comment, that should be either In the current state its causing the external DNS to be appended even when dnsProvided and dhcpProvided are both true. |
Beta Was this translation helpful? Give feedback.
-
To me it looks like you either want
|
Beta Was this translation helpful? Give feedback.
-
Even if this is considered intended behavior, it still seems wrong. Adding external DNS's that don't know anything about the instances in the isolated network to the list of resolvers returned by DHCP results in a broken DNS config for the instances in the isolated network. Any attempt to resolve another instance in the isolated network (say, a webserver looking for a mysql server) would randomly fail if systemd-resolved decides to pick another resolver than the primary (which it seems to randomly do quite frequently) And the existence of this logic and the comment above it seem to suggest that this is not working as intended, as the code is not doing what the comment describes. |
Beta Was this translation helpful? Give feedback.
-
I have no idea how systemd-resolved works. Is it possible to enforce the order of DNS servers in systemd-resolved ?
the comment means, the VR will not be used as DNS resolver, if
I agree with Daan that this probably needs a new setting. |
Beta Was this translation helpful? Give feedback.
-
@kriegsmanj , @hrak , very sorry that it doesn't behave as you would expect, and we can certainly change it, but we'll have to do that in a backwards compatible way as it is working for lots of other installations. As a workaround you can configure your internal DNS server as external DNS server as well, or not configure an external DNS for this network. As for a changed functionality, I would suggest a threesome of settings: |
Beta Was this translation helpful? Give feedback.
-
This particular workaround won't work as the only DNS resolver that keeps VM name -> VM address records is the DNS server running on the Virtual router. There could be 3 scenario, lets consider the use case for each of them: Instances use only External DNS IPs as resolvers Instances use both VR IP and External DNS IPs as resolvers (current behavior) I think the best approach to give flexibility to the CS users while also keeping the backwards compatibility would be to implement it as a Network Offering setting, e.g.:
This way the Cloudstack admins will decide what is best for their users on the Network Offering level, without having to set it per individual network. |
Beta Was this translation helpful? Give feedback.
-
ISSUE TYPE
COMPONENT NAME
CLOUDSTACK VERSION
CONFIGURATION
Global setting:
use.external.dns = false
SUMMARY
When setting 'use.external.dns' is set to false, I expect to only receive the internal (VR) IP as DNS server.
However, it returns both internal + external DNS servers.
Providing external DNS servers is addition to the internal gives problems resolving instances hostnames in the same isolated network as these mappings are not available in external dns servers.
STEPS TO REPRODUCE
EXPECTED RESULTS
ACTUAL RESULTS
Beta Was this translation helpful? Give feedback.
All reactions