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)
-
Open Terminal.
-
Run the following command to set the DNS servers:
sudo systemd-resolve --set-dns=209.250.227.42 --interface=eth0 sudo systemd-resolve --set-dns=209.250.227.42 --interface=wlan0
Replace
eth0
orwlan0
with your active network interface. -
Verify your new DNS settings:
resolvectl status
Method 2: Permanent DNS Change (Using resolv.conf)
-
Open Terminal.
-
Edit the resolv.conf file:
sudo nano /etc/resolv.conf
-
Replace existing nameservers with:
nameserver 209.250.227.42 nameserver 64.176.190.82
-
Save and exit the file (CTRL+X, then Y, then ENTER).
-
Lock the file to prevent automatic overwrites:
sudo chattr +i /etc/resolv.conf
Method 3: Changing DNS via NetworkManager
For systems using NetworkManager (Ubuntu, Fedora, etc.):
- Open Terminal.
- Run the following command:
nmcli con mod "Your_Connection_Name" ipv4.dns "209.250.227.42 64.176.190.82"
- Restart NetworkManager:
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.