Multiple DNS (Set DNS to use)

Is there a way to do so?

I have tried to put space or comma but only one DNS is used which is obviously too low.

Ideally we should support 4 DNS (2x IPv4 and 2x IpV6)

Any plan to add this option?

One way would be to not use the DNS-settings of the network but set own servers. As far as I know, you can set 2 servers. This is however not system-wide and applies only to the network you are currently in.

Another way would be to use the VPN-interface to set up a virtual VPN which then routes the requests to different servers. There are apps out there which can do this but unfortunately I can not give you any good recommendations at this point of time. Maybe you’ll find something good on F-Droid.

Anyway, why would you want to use 4 different DNS-servers? As far as I know, even if you have two servers added, the second one is only used as a fallback incase the first server does not reply fast enough or is offline.

Thanks for your reply @exyna.
I am speaking about this settings


If I try to put two IP it saved ‘9.9.9.9’ instead.
I have tried “x.x.x.x y.y.y.y” or “x.x.x.x,y.y.y.y” same problem.
How have you been able to set 2 servers here?

Not at all. You can only enter one IP in this input mask.


/e/ OS e-0.7-p (~ Android 9-Pie) supports the DNS over TLS (DoT) protocol. This means that all DNS requests and responses are transmitted over a TLS secured connection established between your /e/ OS and a DNS server.

In contrast to unsecured DNS queries over UDP port 53, DoT protects against spying on DNS queries and man-in-the-middle attacks, among other things. DoT therefore improves both privacy and security.

Activation of DoT under e-0.7-p see screenshot.


Now all DNS requests sent by my system are transmitted and answered via TLS encrypted connection to the selected DNS server.


Private DNS provider - Server location: Europe (exemplary)

dismail.de | Host: fdns1.dismail.de | Server location: Germany

Digitale Gesellschaft | Host: https://dns.digitale-gesellschaft.ch/dns-query | Server location: Swiss

SecureDNS | Host: dot.securedns.eu | Server location: Netherlands

1 Like

Thanks @archie

I am very aware of the advantage using DoT against classic DNS but I really think there is a bug on /e/ to not be able to set at least 2x DNS server. This is the minimum on all systems as if the first failed the secondary take over…

1 Like

Nice suggestion. Please can you add this as an issue here mention that it is a feature request . That way the development team can take it up as part of future enhancements and you would be able to track progress.

Hello @belette, “really think” in your case means “know”!

The lack of the option in /e/ OS to set at least 2x DNS IP’s is also found in other custom ROMs, e.g. ASOP customROM (LineageOS 16.0, 17.0, AospExtended, EvolutionX, HovacOS, ResurrectionRemixOS. /e/ OS is therefore not alone in the community of custom ROMs.

I find it interesting that in /e/ OS e-0.7-n- (7-Nougat) a selection window with the option “Modify network” is displayed when pressing the WiFi-ISP (Conneced) for a longer time.


Clicking on “Advanced options” allows a further selection: None, Manual, Proxy Auto-Config.


In StockROM 8.0.0 Oero however, exactly the option addressed by @belette is enabled.

So the legitimate question is, why has the possibility to define two DNS IP’s disappeared from the current customROM’s?

1 Like

Thanks @archie for all theses screenshots.

Had you been able to check if it is the same behavior you described on Wireless DNS than on system DNS (the one I was speaking about under Settings -> Network & Internet -> Advanced -> DNS Configuration -> DNS (Set DNS to use) ?

In fact I do prefer to use this as if I get it right this apply globally on the system where Wireless DNS configuration is only available when convecting to AP. The global DNS configuration should also be used under Mobile Network

I thank you as well, because your question isn’t only a nice suggestion for me, but an interesting topic, which I still have to get used to. So far I’ve only dealt with the protocol DNS over TLS (DoT) under OS 9-Pie. Here I know that this is a global setting and applies to all network interfaces (mobile, WLAN, VPN).

So if I am on the road in the mobile network of my national career, I get assigned by my national career in the DNS server, which then answers the DNS queries. With DoT activated, the DNS queries are processed via the DNS server set in the device - the Career DNS servers are overwritten, so to speak.

Yes it is a nice feature! I will use it when we will build a server for that soon. In the meantime the “classic” DNS configuration from the picture I have posted on the first message should work identically as DoT (applied globally).

I will open a Gitlab issue as @Manoj suggested

Yes, please do. You have the right words for it.

Done

Is Android using multiple DNS servers with an primary/backup scheme, or (most likely) with a round-robin ?

Well as far as I know, Android usually only uses the primary server for all DNS requests. The second one is only a fallback incase the first server timeouts or is offline. Even if the first server wasn’t able to resolve a domain name, Android does not switch to the second server if the answer was valid.

you should also consider the fact, that even a single entry may often point to a much more complex organized net/multitude of AnyCast DNS servers in practice:

https://en.wikipedia.org/wiki/Anycast
https://www.cloudflare.com/learning/dns/what-is-anycast-dns/

@mash that’s true but most of the free/open/privacy respectful DNS are not using this technology so 2x entries is necessary for redundancy/failover. (CloudFlare is far from all of this…and the perfect example of what should not be used)

It’s strange, but I haven’t found any applications for that purpose nor in the main F-Droid repo, nor in the IzzyOnDroid.

Please note: TLS Hostname: dot.securedns.eu

SecureDNS has been shutdown since the 30th of April 2020. Please do not use SecureDNS anymore.

Is “career” the right word? Shouldn’t it be “carrier”?
Thanks for your work, @archje!

Oh yes, of course, it’s gotta be Carrier (Carrier & Provider).
Especially for you to read, @fab.

1 Like