resolv.conf on CentOS 7/RHEL 7 is NetworkManager managed

Bug #1620807 reported by Bert JW Regeer
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
cloud-init
Expired
Medium
Unassigned

Bug Description

Related to https://bugs.launchpad.net/cloud-init/+bug/1620796 I have found that even when I have fixed cloud-init to properly write resolv.conf it gets overwritten as soon as network is started because NetworkManager takes over control:

/etc/resolv.conf

# Generated by NetworkManager
search novalocal

# No nameservers found; try putting DNS servers into your
# ifcfg files in /etc/sysconfig/network-scripts like so:
#
# DNS1=xxx.xxx.xxx.xxx
# DNS2=xxx.xxx.xxx.xxx
# DOMAIN=lab.foo.com bar.foo.com

instead any DNS entries should be added directly to the ifcfg-eth* files that are generated, then let NM figure out what DNS resolvers it wants to add to /etc/resolv.conf.

Tags: rhel centos

Related branches

tags: added: rhel
tags: added: centos
Revision history for this message
Bert JW Regeer (bregeer-ctl) wrote :

I've resolved this in this branch: https://code.launchpad.net/~bregeer-ctl/cloud-init/+git/cloud-init/+ref/bugfix/centos7_resolv

Launchpad is unable to find it though, so I can't link it.

Scott Moser (smoser)
Changed in cloud-init:
status: New → Confirmed
importance: Undecided → Medium
Revision history for this message
James Falcon (falcojr) wrote :
Changed in cloud-init:
status: Confirmed → Expired
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.