[SOLVED] Change DNS Settings?

Questions about Wi-Fi and other network devices, file sharing, firewalls, connection sharing etc
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
User avatar
Carl
Level 5
Level 5
Posts: 701
Joined: Wed Apr 15, 2009 5:20 pm
Location: Isle of Wight, UK

[SOLVED] Change DNS Settings?

Post by Carl »

Hi,

How do I go about changing the DNS settings from within Linux Mint 19? unfortunately I cannot change them in my router so this is the next best thing

Thank you
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 2 times in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
User avatar
Pjotr
Level 24
Level 24
Posts: 20086
Joined: Mon Mar 07, 2011 10:18 am
Location: The Netherlands (Holland) 🇳🇱
Contact:

Re: Change DNS Settings?

Post by Pjotr »

Last edited by Pjotr on Fri Jul 27, 2018 6:10 am, edited 1 time in total.
Tip: 10 things to do after installing Linux Mint 21.3 Virginia
Keep your Linux Mint healthy: Avoid these 10 fatal mistakes
Twitter: twitter.com/easylinuxtips
All in all, horse sense simply makes sense.
User avatar
Carl
Level 5
Level 5
Posts: 701
Joined: Wed Apr 15, 2009 5:20 pm
Location: Isle of Wight, UK

Re: Change DNS Settings?

Post by Carl »

Pjotr wrote: Thu Jul 26, 2018 5:00 pm Try this:
https://sites.google.com/site/easylinux ... our-system
(item 10, right column)
Thank you but unfortunately xed says it cannot find that file? "Could not find the file admin:///etc/resolvconf/resolv.conf.d/tail."
User avatar
Pjotr
Level 24
Level 24
Posts: 20086
Joined: Mon Mar 07, 2011 10:18 am
Location: The Netherlands (Holland) 🇳🇱
Contact:

Re: Change DNS Settings?

Post by Pjotr »

Carl wrote: Thu Jul 26, 2018 5:04 pm
Pjotr wrote: Thu Jul 26, 2018 5:00 pm Try this:
https://sites.google.com/site/easylinux ... your-ystem
Thank you but unfortunately xed says it cannot find that file? "Could not find the file admin:///etc/resolvconf/resolv.conf.d/tail."
You're right... apparently systemd has taken over in that respect, as well. I'll have to research that a bit....
Last edited by Pjotr on Fri Jul 27, 2018 6:11 am, edited 1 time in total.
Tip: 10 things to do after installing Linux Mint 21.3 Virginia
Keep your Linux Mint healthy: Avoid these 10 fatal mistakes
Twitter: twitter.com/easylinuxtips
All in all, horse sense simply makes sense.
User avatar
Carl
Level 5
Level 5
Posts: 701
Joined: Wed Apr 15, 2009 5:20 pm
Location: Isle of Wight, UK

Re: Change DNS Settings?

Post by Carl »

Looks like this works
I've found and adapted a solution that works from https://support.opendns.com/hc/en-us...8007087-Ubuntu

To change your system to use the OpenDNS servers (this is for Mint 19 - adapt accordingly for your distro/version):

Code: Select all

sudo cp /etc/resolv.conf /etc/resolv.conf.auto

Code: Select all

xed admin:///etc/dhcp/dhclient.conf
and add supersede domain-name-servers 208.67.222.222,208.67.220.220; after the require subnet-mask command.

Save the file.

Find out your interface device name with netstat -i and replace device_name below with that device name.

Code: Select all

sudo ifconfig device_name down && sudo ifconfig device_name up
Disconnect and reconnect.
from: https://www.linuxquestions.org/question ... ost5866919
User avatar
Pjotr
Level 24
Level 24
Posts: 20086
Joined: Mon Mar 07, 2011 10:18 am
Location: The Netherlands (Holland) 🇳🇱
Contact:

Re: [SOLVED] Change DNS Settings?

Post by Pjotr »

I've modified my how-to: it can easily be done by means of Network Manager:
https:sites.google.com/site/easylinuxtipsproject/7#TOC-How-to-add-extra-DNS-name-servers-to-your-system
(item 10, right column)

https://easylinuxtipsproject.blogspot.c ... .html#ID10
(item 10)
Last edited by Pjotr on Tue Aug 13, 2019 4:30 am, edited 2 times in total.
Tip: 10 things to do after installing Linux Mint 21.3 Virginia
Keep your Linux Mint healthy: Avoid these 10 fatal mistakes
Twitter: twitter.com/easylinuxtips
All in all, horse sense simply makes sense.
swayne

Re: [SOLVED] Change DNS Settings?

Post by swayne »

Pjotr wrote: Thu Jul 26, 2018 5:27 pm I've modified my how-to: it can easily be done by means of Network Manager:
https://sites.google.com/site/easylinux ... our-system
(item 10, right column)
URL not working, broken link.
User avatar
Pjotr
Level 24
Level 24
Posts: 20086
Joined: Mon Mar 07, 2011 10:18 am
Location: The Netherlands (Holland) 🇳🇱
Contact:

Re: [SOLVED] Change DNS Settings?

Post by Pjotr »

swayne wrote: Mon Aug 12, 2019 10:45 pm
Pjotr wrote: Thu Jul 26, 2018 5:27 pm I've modified my how-to: it can easily be done by means of Network Manager:
https://sites.google.com/site/easylinux ... our-system
(item 10, right column)
URL not working, broken link.
This is the new location:
https://easylinuxtipsproject.blogspot.c ... .html#ID10
(item 10)
Tip: 10 things to do after installing Linux Mint 21.3 Virginia
Keep your Linux Mint healthy: Avoid these 10 fatal mistakes
Twitter: twitter.com/easylinuxtips
All in all, horse sense simply makes sense.
Locked

Return to “Networking”