Long story short, my country is censoring some websites by forcing ISPs to configure their DNS servers to not return the correct answer when queried about specific domains.

For various reasons, I want to continue to use the DHCP provided DNS servers (which are the ISP's ones).

But when I try to resolve one of the aforementioned domains, I want to use specific servers that aren't subjected to that censorship.

I'm using stock kubuntu 20.10, so I'm using systemd-resolved, which from my understanding, is running a local DNS server which is forwarding request to the DHCP provided ones and/or the configured ones.

Is it possible to configure systemd-resolved system-wide to continue to honor the network-manager settings but forward the request to a specific server for specific domains?

If no, are there other solutions to solve my issue ?


  • Adding those hosts to /etc/hosts would be a start - depending on how many you need.
    – Panki
    Commented Dec 7, 2020 at 9:47
  • That's too impractical, there can bee a lot, and if their ip changes, I'd need to update it manually. The optimal solution would be to configure resolved to query servers provided by dhcp/statically (depending on network-manager) and if the answer is incorrect, query an alternate dns. Problem is, the ISP's server do answer (although the answer is "No answer") so resolved doesn't query anything else.
    – hey00
    Commented Dec 7, 2020 at 10:38
  • dnsmasq does this really well. I don't know how, and if, systemd-resolver can do it too Commented Dec 7, 2020 at 11:48
  • From my understanding, that would require removing resolved, right?
    – hey00
    Commented Dec 14, 2020 at 9:37

1 Answer 1


If your ISP Blocking or forcing your DNS Configuration, then the solution is use tunneling or VPN, which has a different connection with your ISP.

The DNS Server can be configured on Tunnel/VPN server.

  • They aren't blocking it. I can use any configuration I want, that's not an issue. I could fully use other DNS servers, but for now I still want to use my ISP's as primary server and only switch to other for specific domains.
    – hey00
    Commented Dec 14, 2020 at 9:36

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .