Skip to content

Linux Setup Guide ​

Configuring your Linux system to use our public DNS resolvers enhances security, privacy, and browsing speed. Follow these steps to manually set up DNS on Linux.

Method 1: Temporary DNS Change (Valid Until Reboot) ​

  1. Open Terminal.
  2. Run the following command to set the DNS servers:
    sh
    sudo systemd-resolve --set-dns=209.250.227.42 --interface=eth0
    sudo systemd-resolve --set-dns=209.250.227.42 --interface=wlan0
    Replace eth0 or wlan0 with your active network interface.
  3. Verify your new DNS settings:
    sh
    resolvectl status

Method 2: Permanent DNS Change (Using resolv.conf) ​

  1. Open Terminal.
  2. Edit the resolv.conf file:
    sh
    sudo nano /etc/resolv.conf
  3. Replace existing nameservers with:
    nameserver 209.250.227.42
    nameserver 64.176.190.82
  4. Save and exit the file (CTRL+X, then Y, then ENTER).
  5. Lock the file to prevent automatic overwrites:
    sh
    sudo chattr +i /etc/resolv.conf

Method 3: Changing DNS via NetworkManager ​

For systems using NetworkManager (Ubuntu, Fedora, etc.):

  1. Open Terminal.
  2. Run the following command:
    sh
    nmcli con mod "Your_Connection_Name" ipv4.dns "209.250.227.42 64.176.190.82"
  3. Restart NetworkManager:
    sh
    sudo systemctl restart NetworkManager

Verifying Your Configuration ​

Visit the UK DNS Project homepage to verify that your system is using the configured DNS.

For any issues or troubleshooting steps.


Cookies? Nope, we don’t use them — so there’s nothing to accept!