Re: peerdns reversed?
- From: Sean Darcy <seandarcy2 gmail com>
- To: networkmanager-list gnome org
- Subject: Re: peerdns reversed?
- Date: Tue, 22 Apr 2014 11:27:14 -0400
On 04/21/2014 05:28 PM, Dan Williams wrote:
On Sun, 2014-04-20 at 21:15 -0400, Sean Darcy wrote:
on Fedora 20:
cat /etc/sysconfig/network-scripts/ifcfg-external
# Please read /usr/share/doc/initscripts-*/sysconfig.txt
# for the documentation of these parameters.
TYPE=Ethernet
BOOTPROTO=dhcp
DEVICE=external
DEFROUTE=yes
IPV4_FAILURE_FATAL=no
IPV6INIT=no
PEERDNS=no
DNS1=127.0.0.1
DNS2=8.8.8.8
## PEERROUTES=yes
USERCTL=no
cat /etc/resolv.conf
# Generated by NetworkManager
nameserver 127.0.0.1
nameserver 8.8.8.8
but if I set PEERDNS=yes:
cat /etc/resolv.conf
# Generated by NetworkManager
nameserver 167.206.251.130
nameserver 167.206.251.129
nameserver 127.0.0.1
# NOTE: the libc resolver may not support more than 3 nameservers.
# The nameservers listed below may not be recognized.
nameserver 8.8.8.8
Isn't this the wrong way around?
Currently any additional static DHCP servers are appended to those
detected from DHCP. So I think this is the intended functionality. I'm
assuming you'd rather have them prepended instead?
But since you're using 127.0.0.1, it seems unlikely that you want any
nameservers at all, but you'll want to use a local caching nameserver?
NM has some built-in functionality for that already using dnsmasq, see
'man NetworkManager.conf' in the section about DNS.
Dan
Thanks for the reply. I'll look at dnsmasq. Thanks for the lead.
But really I'm just trying to overide the isp's dns servers. I've looked
up PEERDNS in sysconfig.txt, from Fedora's initscripts-9.51-2.fc20.
PEERDNS=yes|no
modify /etc/resolv.conf if peer uses msdns extension (PPP only) or
DNS{1,2} are set, or if using dhclient. default to "yes".
DNS{1,2}=<ip address>
provide DNS addresses that are dropped into the resolv.conf
file if PEERDNS is not set to "no".
As I read this, if PEERDNS is set to "no" the DNS addresses not dropped
into resolv.conf. If "yes", they are, but no mention of pre- or ap- pend.
Now if you set PEERDNS to "no" NM puts only the connection DNS addresses
in resolv.conf. If "yes" NM appends them to the dhcp adresses.
I prefer the wholesale replacement, since I don't want to use the isp's
servers, so I probably shouldn't complain about the inconsistency. Is
the way NM handles the entries in the ifcfg- scripts described anywhere?
Perhaps I should not have been looking at sysconfig.txt?
sean
sean
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]