Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #188210

Re: Why does resolv.conf keep changing?

From Jude DaShiell <jdashiel@panix.com>
Newsgroups linux.debian.user
Subject Re: Why does resolv.conf keep changing?
Date 2017-10-23 18:10 +0200
Message-ID <uDNsB-7Tv-5@gated-at.bofh.it> (permalink)
References <uDAvn-89e-1@gated-at.bofh.it> <uDGKt-3zS-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


If you've got dynamic ip addresses as many of us do, that file has to 
change to keep your internet connection up.

On Mon, 23 Oct 2017, Joe wrote:

> Date: Mon, 23 Oct 2017 04:17:11
> From: Joe <joe@jretrading.com>
> To: debian-user@lists.debian.org
> Subject: Re: Why does resolv.conf keep changing?
> Resent-Date: Mon, 23 Oct 2017 08:54:41 +0000 (UTC)
> Resent-From: debian-user@lists.debian.org
> 
> On Sun, 22 Oct 2017 22:12:03 -0400
> Roberto C. S?nchez <roberto@debian.org> wrote:
>
>> So, I just upgraded my main router/firewall machine to Stretch.
>> Following the upgrade my /etc/resolv.conf settings appear to track the
>> DHCP options obtained by one of the two interfaces.  No matter what I
>> try I can't get the /etc/resolv.conf settings to remain as I would
>> like them.
>>
>> The machine has two network interfaces: one on the Internt side which
>> connects to my ISP-provided equipment and which obtains its address
>> via DHCP, another on the LAN side which is statically configured.
>>
>> My /etc/network/interfaces looks like this (192.168.174.0/24 is my LAN
>> subnet):
>>
>> auto lo
>> iface lo inet loopback
>>
>> auto eth0
>> iface eth0 inet static
>>         address 192.168.174.1
>>         netmask 255.255.255.0
>>         broadcast 192.168.174.255
>>
>> auto eth1
>> iface eth1 inet dhcp
>>
>> My /etc/resolv.conf looks like this:
>>
>> domain example.com
>> search example.com.
>> nameserver 127.0.0.1
>>
>> The reason for "nameserver 127.0.0.1" is that I run my own instance of
>> bind which acts as a caching server and also serves my own internal
>> zones.  Prior to the recent upgrade to Stretch everything worked
>> normally.  That is, whatever I put in /etc/resolv.conf was left as I
>> configured it.  Following my recent Stretch upgrade I found my
>> resolv.conf had been changed to just this (192.168.63.1/24 is the
>> subnet used by the ISP equipment):
>>
>> nameserver 192.168.63.1
>>
>> That has the effect of not allowing processes running on that machine
>> (the router/firewall) to properly resolve internal DNS addresses.
>> Other machines on my network are fine since they get their name
>> servers set by the internal DHCP server which is configured with the
>> name server address 192.168.174.1.  This DHCP server is different
>> from the embedded DHCP server that runs on my ISP's device.
>>
>> I have tried two different things.  First, I added this directive to
>> /etc/network/interfaces under the eth0 stanza:
>>
>>         dns-nameservers 127.0.0.1
>>
>> That did not appear to have any effect because taking eth0 and eth1
>> down and then bringing them back up still results in resolv.conf
>> pointing to the ISP router as its name server.  Additionally, after
>> the interfaces are up even if I manually change resolv.conf,
>> something comes along sometime later and undoes my changes.
>>
>> The second thing I tried was adding to /etc/dhcp/dhclient.conf:
>>
>> supersede domain-name example.com;
>> supersede domain-search example.com.;
>> supersede domain-name-servers 127.0.0.1;
>>
>> This similarly has no lasting effect, which is really surprising to
>> me.
>>
>> I did find a page on the Debian wiki [0] which recommends setting the
>> immutable attribute on /etc/resolv.conf.  However, that feels like an
>> ugly hack.
>>
>
> It most certainly is, and shouldn't be necessary in your case.
>
>> Can anyone point out what it is that I am missing here?
>
> Not 'missing', you probably have the package resolvconf installed, and
> with your network configuration, you don't need it. It's not certain,
> but it seems to be the culprit in most of these cases. There is
> undoubtedly a way to beat it into submission, but it's not widely
> known. There was another recent thread on this matter.
>
> If you're bringing up and taking down random interfaces, such as VPN
> tunnels and wifi, then you do want to keep shifting your DNS server, so
> resolvconf is appropriate on a laptop, but probably not on a fixed
> workstation.
>
>

-- 

Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-23 04:20 +0200
  Re: Why does resolv.conf keep changing? Joe <joe@jretrading.com> - 2017-10-23 11:00 +0200
    Re: Why does resolv.conf keep changing? <tomas@tuxteam.de> - 2017-10-23 11:50 +0200
      Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-24 01:40 +0200
        Re: Why does resolv.conf keep changing? David Wright <deblis@lionunicorn.co.uk> - 2017-10-24 02:30 +0200
          Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-24 05:10 +0200
            Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-24 09:20 +0200
              Re: Why does resolv.conf keep changing? Greg Wooledge <wooledg@eeg.ccf.org> - 2017-10-24 14:20 +0200
                Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-24 14:30 +0200
                Re: Why does resolv.conf keep changing? Curt <curty@free.fr> - 2017-10-24 19:10 +0200
              Re: Why does resolv.conf keep changing? David Wright <deblis@lionunicorn.co.uk> - 2017-10-24 18:50 +0200
                Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-25 15:30 +0200
                Re: Why does resolv.conf keep changing? Gene Heskett <gheskett@shentel.net> - 2017-10-25 15:40 +0200
                Re: Why does resolv.conf keep changing? David Wright <deblis@lionunicorn.co.uk> - 2017-10-25 20:50 +0200
              Re: Why does resolv.conf keep changing? Roger Lynn <Roger@rilynn.me.uk> - 2017-10-25 00:30 +0200
                Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-25 04:10 +0200
    Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-23 13:00 +0200
    Re: Why does resolv.conf keep changing? Greg Wooledge <wooledg@eeg.ccf.org> - 2017-10-23 18:10 +0200
    Re: Why does resolv.conf keep changing? Jude DaShiell <jdashiel@panix.com> - 2017-10-23 18:10 +0200
      Re: Why does resolv.conf keep changing? Gene Heskett <gheskett@shentel.net> - 2017-10-23 23:10 +0200
        Re: Why does resolv.conf keep changing? Dan Ritter <dsr@randomstring.org> - 2017-10-24 00:00 +0200
          Re: Why does resolv.conf keep changing? Gene Heskett <gheskett@shentel.net> - 2017-10-24 02:40 +0200
            Re: Why does resolv.conf keep changing? Michael Stone <mstone@debian.org> - 2017-10-25 03:20 +0200
              Re: Why does resolv.conf keep changing? Gene Heskett <gheskett@shentel.net> - 2017-10-25 05:00 +0200
                Re: Why does resolv.conf keep changing? Michael Stone <mstone@debian.org> - 2017-10-25 05:10 +0200
                Re: Why does resolv.conf keep changing? Gene Heskett <gheskett@shentel.net> - 2017-10-25 06:20 +0200
                Re: Why does resolv.conf keep changing? Michael Stone <mstone@debian.org> - 2017-10-25 13:40 +0200
                Re: Why does resolv.conf keep changing? Alberto Luaces <aluaces@udc.es> - 2017-10-25 14:10 +0200
                Re: Why does resolv.conf keep changing? Michael Stone <mstone@debian.org> - 2017-10-25 15:30 +0200
                Re: Why does resolv.conf keep changing? <tomas@tuxteam.de> - 2017-10-25 15:50 +0200
                Re: Why does resolv.conf keep changing? Curt <curty@free.fr> - 2017-10-25 16:30 +0200
                Re: Why does resolv.conf keep changing? Joe <joe@jretrading.com> - 2017-10-25 17:10 +0200
                Re: Why does resolv.conf keep changing? <tomas@tuxteam.de> - 2017-10-25 17:30 +0200
                Re: Why does resolv.conf keep changing? rhkramer@gmail.com - 2017-10-25 19:00 +0200
                Re: Why does resolv.conf keep changing? <tomas@tuxteam.de> - 2017-10-25 19:10 +0200
                Re: Why does resolv.conf keep changing? rhkramer@gmail.com - 2017-10-25 19:40 +0200
                Re: Why does resolv.conf keep changing? Gene Heskett <gheskett@shentel.net> - 2017-10-25 14:20 +0200
                Re: Why does resolv.conf keep changing? Felix Miata <mrmazda@earthlink.net> - 2017-10-25 05:50 +0200
                Re: Why does resolv.conf keep changing? Gene Heskett <gheskett@shentel.net> - 2017-10-25 13:40 +0200
                Re: Why does resolv.conf keep changing? <tomas@tuxteam.de> - 2017-10-25 14:00 +0200
                Re: Why does resolv.conf keep changing? tomas@tuxteam.de - 2017-10-25 14:20 +0200
                Re: Why does resolv.conf keep changing? Nicolas George <george@nsup.org> - 2017-10-25 14:50 +0200
                Re: Why does resolv.conf keep changing? Joe <joe@jretrading.com> - 2017-10-25 14:10 +0200
                Re: Why does resolv.conf keep changing? <tomas@tuxteam.de> - 2017-10-25 14:20 +0200
                Re: Why does resolv.conf keep changing? Joe <joe@jretrading.com> - 2017-10-25 15:00 +0200
                Re: Why does resolv.conf keep changing? Dan Ritter <dsr@randomstring.org> - 2017-10-25 17:10 +0200
                Re: Why does resolv.conf keep changing? Gene Heskett <gheskett@shentel.net> - 2017-10-25 18:50 +0200
                Re: Why does resolv.conf keep changing? Don Armstrong <don@debian.org> - 2017-10-25 21:30 +0200
                Re: Why does resolv.conf keep changing? Michael Stone <mstone@debian.org> - 2017-10-25 13:40 +0200
              Re: Why does resolv.conf keep changing? Glenn English <ghe2001@gmail.com> - 2017-10-26 17:40 +0200
                Re: Why does resolv.conf keep changing? Greg Wooledge <wooledg@eeg.ccf.org> - 2017-10-26 17:50 +0200
                Re: Why does resolv.conf keep changing? The Wanderer <wanderer@fastmail.fm> - 2017-10-26 18:00 +0200
                Re: Why does resolv.conf keep changing? Nicholas Geovanis <nickgeovanis@gmail.com> - 2017-10-26 18:20 +0200
                Re: Why does resolv.conf keep changing? Nicholas Geovanis <nickgeovanis@gmail.com> - 2017-10-26 18:40 +0200
                Re: Why does resolv.conf keep changing? Gene Heskett <gheskett@shentel.net> - 2017-10-27 02:00 +0200
                Re: Why does resolv.conf keep changing? Gene Heskett <gheskett@shentel.net> - 2017-10-27 02:00 +0200
  Re: Why does resolv.conf keep changing? Jörg-Volker Peetz <jvpeetz@web.de> - 2017-10-23 12:10 +0200
  Re: Why does resolv.conf keep changing? Stefan Monnier <monnier@iro.umontreal.ca> - 2017-10-25 05:50 +0200
    Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-25 06:10 +0200
      Re: Why does resolv.conf keep changing? Stefan Monnier <monnier@iro.umontreal.ca> - 2017-10-25 06:50 +0200
        Re: Why does resolv.conf keep changing? Curt <curty@free.fr> - 2017-10-25 08:50 +0200
          Re: Why does resolv.conf keep changing? Stefan Monnier <monnier@iro.umontreal.ca> - 2017-10-25 14:40 +0200
            Re: Why does resolv.conf keep changing? <tomas@tuxteam.de> - 2017-10-25 14:50 +0200
              Re: Why does resolv.conf keep changing? Stefan Monnier <monnier@iro.umontreal.ca> - 2017-10-25 15:00 +0200
                Re: Why does resolv.conf keep changing? <tomas@tuxteam.de> - 2017-10-25 15:10 +0200
              Re: Why does resolv.conf keep changing? Greg Wooledge <wooledg@eeg.ccf.org> - 2017-10-25 15:10 +0200
                Re: Why does resolv.conf keep changing? <tomas@tuxteam.de> - 2017-10-25 15:10 +0200
                Re: Why does resolv.conf keep changing? Michael Stone <mstone@debian.org> - 2017-10-25 15:30 +0200
                Re: Why does resolv.conf keep changing? Gene Heskett <gheskett@shentel.net> - 2017-10-25 15:30 +0200
                Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-25 16:10 +0200
                Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-25 16:10 +0200
                [SOLVED] Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-25 20:30 +0200
                Re: [SOLVED] Re: Why does resolv.conf keep changing? Michael Stone <mstone@debian.org> - 2017-10-25 20:40 +0200
                Re: [SOLVED] Re: Why does resolv.conf keep changing? Greg Wooledge <wooledg@eeg.ccf.org> - 2017-10-25 20:40 +0200
                Re: [SOLVED] Re: Why does resolv.conf keep changing? Greg Wooledge <wooledg@eeg.ccf.org> - 2017-10-25 21:00 +0200
                Re: [SOLVED] Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-25 21:00 +0200
                Re: [SOLVED] Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-26 15:10 +0200
                Re: [SOLVED] Re: Why does resolv.conf keep changing? Greg Wooledge <wooledg@eeg.ccf.org> - 2017-10-26 15:40 +0200
                Re: [SOLVED] Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-26 16:00 +0200
                Re: [SOLVED] Re: Why does resolv.conf keep changing? Don Armstrong <don@debian.org> - 2017-10-26 21:40 +0200
                Re: [SOLVED] Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-26 21:40 +0200
                Re: [SOLVED] Re: Why does resolv.conf keep changing? Nicholas Geovanis <nickgeovanis@gmail.com> - 2017-10-26 16:30 +0200
                The new normal of logging Jonathan de Boyne Pollard <J.deBoynePollard-newsgroups@NTLWorld.COM> - 2017-10-26 21:10 +0200
                Re: The new normal of logging Nicholas Geovanis <nickgeovanis@gmail.com> - 2017-10-26 21:30 +0200
                Re: The new normal of logging Gene Heskett <gheskett@shentel.net> - 2017-10-27 02:10 +0200
                Re: The new normal of logging Ben Caradoc-Davies <ben@transient.nz> - 2017-10-27 03:30 +0200
                Re: The new normal of logging Gene Heskett <gheskett@shentel.net> - 2017-10-27 07:00 +0200
                Re: The new normal of logging Ben Caradoc-Davies <ben@transient.nz> - 2017-10-28 04:50 +0200
                Re: The new normal of logging Gene Heskett <gheskett@shentel.net> - 2017-10-28 08:10 +0200
                Re: The new normal of logging Joe Pfeiffer <pfeiffer@cs.nmsu.edu> - 2017-10-27 04:10 +0200
                Re: The new normal of logging Darac Marjal <mailinglist@darac.org.uk> - 2017-10-27 11:40 +0200
                Plain text vs. binary (was Re: The new normal of logging) The Wanderer <wanderer@fastmail.fm> - 2017-10-27 14:40 +0200
                Re: The new normal of logging Roberto C. Sánchez <roberto@debian.org> - 2017-10-26 21:30 +0200
                Re: [SOLVED] Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-27 17:10 +0200
                Re: [SOLVED] Re: Why does resolv.conf keep changing? Greg Wooledge <wooledg@eeg.ccf.org> - 2017-10-27 17:50 +0200
                Re: [SOLVED] Re: Why does resolv.conf keep changing? Curt <curty@free.fr> - 2017-10-27 20:30 +0200
                Re: [SOLVED] Re: Why does resolv.conf keep changing? Brian <ad44@cityscape.co.uk> - 2017-10-27 20:50 +0200
                Re: [SOLVED] Re: Why does resolv.conf keep changing? Curt <curty@free.fr> - 2017-10-27 21:50 +0200
                Re: [SOLVED] Re: Why does resolv.conf keep changing? Greg Wooledge <wooledg@eeg.ccf.org> - 2017-10-27 22:00 +0200
                Re: [SOLVED] Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-28 18:30 +0200
                Re: Why does resolv.conf keep changing? Stefan Monnier <monnier@iro.umontreal.ca> - 2017-10-26 05:40 +0200
                Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-26 12:50 +0200
                Re: Why does resolv.conf keep changing? Darac Marjal <mailinglist@darac.org.uk> - 2017-10-26 13:30 +0200
                Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-26 13:50 +0200
                Re: Why does resolv.conf keep changing? David Wright <deblis@lionunicorn.co.uk> - 2017-10-26 16:40 +0200
                Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-26 17:00 +0200
                Re: Why does resolv.conf keep changing? Mart van de Wege <mvdwege@gmail.com> - 2017-10-27 10:10 +0200
                Re: Why does resolv.conf keep changing? Gene Heskett <gheskett@shentel.net> - 2017-10-27 13:50 +0200
                Re: Why does resolv.conf keep changing? Darac Marjal <mailinglist@darac.org.uk> - 2017-10-27 14:20 +0200
                Re: Why does resolv.conf keep changing? Greg Wooledge <wooledg@eeg.ccf.org> - 2017-10-27 14:40 +0200
                Re: Why does resolv.conf keep changing? David Wright <deblis@lionunicorn.co.uk> - 2017-10-27 20:50 +0200
                Re: Why does resolv.conf keep changing? David Wright <deblis@lionunicorn.co.uk> - 2017-10-27 20:50 +0200
                Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-27 16:20 +0200
                Re: Why does resolv.conf keep changing? Mart van de Wege <mvdwege@gmail.com> - 2017-10-28 00:10 +0200
                Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-28 00:10 +0200
                Re: Why does resolv.conf keep changing? David Wright <deblis@lionunicorn.co.uk> - 2017-10-28 02:00 +0200
                Re: Why does resolv.conf keep changing? Mart van de Wege <mvdwege@gmail.com> - 2017-10-28 15:30 +0200
                Re: Why does resolv.conf keep changing? Glenn English <ghe2001@gmail.com> - 2017-10-28 18:50 +0200
                Re: Why does resolv.conf keep changing? Mart van de Wege <mvdwege@gmail.com> - 2017-10-28 15:40 +0200
                Re: Why does resolv.conf keep changing? Stefan Monnier <monnier@iro.umontreal.ca> - 2017-10-27 16:40 +0200
                Re: Why does resolv.conf keep changing? Mart van de Wege <mvdwege@gmail.com> - 2017-10-28 00:10 +0200
                Re: Why does resolv.conf keep changing? Stefan Monnier <monnier@iro.umontreal.ca> - 2017-10-27 16:30 +0200
                Re: Why does resolv.conf keep changing? Michael Stone <mstone@debian.org> - 2017-10-28 02:40 +0200
                Re: Why does resolv.conf keep changing? Stefan Monnier <monnier@iro.umontreal.ca> - 2017-10-26 14:40 +0200
                Re: Why does resolv.conf keep changing? Roger Lynn <Roger@rilynn.me.uk> - 2017-11-04 00:30 +0100
                Re: Why does resolv.conf keep changing? <tomas@tuxteam.de> - 2017-11-04 08:50 +0100
                Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-11-04 13:10 +0100
                Re: Why does resolv.conf keep changing? Brian <ad44@cityscape.co.uk> - 2017-11-04 22:00 +0100
                Re: Why does resolv.conf keep changing? <tomas@tuxteam.de> - 2017-11-04 22:10 +0100
                Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-11-04 22:10 +0100
                Re: Why does resolv.conf keep changing? Pascal Hambourg <pascal@plouf.fr.eu.org> - 2017-11-04 15:40 +0100
                Re: Why does resolv.conf keep changing? Greg Wooledge <wooledg@eeg.ccf.org> - 2017-10-26 15:30 +0200
              Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-25 15:30 +0200
            Re: Why does resolv.conf keep changing? Gene Heskett <gheskett@shentel.net> - 2017-10-25 15:00 +0200
              Re: Why does resolv.conf keep changing? Stefan Monnier <monnier@iro.umontreal.ca> - 2017-10-25 15:30 +0200
        Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-25 15:10 +0200
          Re: Why does resolv.conf keep changing? Stefan Monnier <monnier@iro.umontreal.ca> - 2017-10-25 15:30 +0200
            Re: Why does resolv.conf keep changing? Roberto C. Sánchez <roberto@debian.org> - 2017-10-25 16:20 +0200

csiph-web