Bug 20383 - add options for resolv.conf and reboot produce bad (not working) resolv.conf
Summary: add options for resolv.conf and reboot produce bad (not working) resolv.conf
Status: NEW
Alias: None
Product: Mageia
Classification: Unclassified
Component: RPM Packages (show other bugs)
Version: Cauldron
Hardware: All Linux
Priority: Normal normal
Target Milestone: ---
Assignee: Base system maintainers
QA Contact:
URL:
Whiteboard: MGA5TOO
Keywords:
Depends on:
Blocks:
 
Reported: 2017-03-02 16:26 CET by eric gerbier
Modified: 2017-03-06 17:08 CET (History)
3 users (show)

See Also:
Source RPM: resolvconf, initscripts
CVE:
Status comment:


Attachments

Description eric gerbier 2017-03-02 16:26:35 CET
Description of problem:

my network config is defined with static IP address and dns names and domain.
the /etc/resolv.conf is well computed

according RESOLVCONF(8) man page, I have added some resolver option in /etc/resolvconf/resolv.conf.d/tail file :
options rotate timeout:1

when I reboot, the file /etc/resolv.conf only contains the option line, the nameserver and search lines have disapeared !
it only contains :

# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
#     DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
options rotate timeout:1
options rotate timeout:1


Version-Release number of selected component (if applicable):
resolvconf-1.79-1.mga6 
initscripts-9.55-22.mga6 (for network scripts ?)

How reproducible:

Steps to Reproduce:
1. check if resolv.conf contains name of dns servers: grep nameserver /etc/resolv.conf
2. add options : echo "options rotate timeout:1" > /etc/resolvconf/resolv.conf.d/tail
3. reboot computer : shutdown -r 0
4. check again resolv.conf : grep nameserver /etc/resolv.conf

I have also tested on Mageia 5 (but with dhcp address) and I do not have this problem
eric gerbier 2017-03-02 16:29:19 CET

Component: Release (media or process) => RPM Packages

Comment 1 eric gerbier 2017-03-03 08:33:38 CET
I just have the same test on Mageia 5 with static IP network configuration, and I have the same behavior as on Mageia 6 : the computed /etc/resolv.conf only contains the options line after a reboot, and is useless.

I had a look into the code, and I found the following chain call :
ifup -> ifup-eth -> ifup-post -> ( by change_resolv_conf in network-functions) -> resolvconf

and on stop :
ifdown -> ifdown-eth -> ifdown-post -> (by clear_resolv_conf in network-functions) -> resolvconf
Marja Van Waes 2017-03-03 19:52:34 CET

CC: (none) => marja11
Assignee: bugsquad => basesystem
Source RPM: (none) => setup
Whiteboard: (none) => MGA5TOO

Thierry Vignaud 2017-03-06 17:08:04 CET

CC: (none) => thierry.vignaud
Source RPM: setup => resolvconf, initscripts


Note You need to log in before you can comment on or make changes to this bug.