Community Packages

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#39813 - [ndisc6] Support resolvconf merge hook

Attached to Project: Community Packages
Opened by Ed Branch (branch) - Friday, 11 April 2014, 03:27 GMT
Last edited by Sébastien Luttringer (seblu) - Tuesday, 26 August 2014, 08:56 GMT
Task Type Feature Request
Category Packages
Status Closed
Assigned To Sébastien Luttringer (seblu)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:

rdnssd has a merge-hook that writes directly to /etc/resolv.conf but its entries are overwritten by resolvconf.

Additional info:
* ndisc6 1.0.2-7
* reported as packaging bug because upstream may not care about resolvconf compatability, but ARCH may since resolvconf is a dependency of a package in the base group (netctl).
* rdnssd creates /run/rdnssd/resolv.conf which the merge-hook merges with /etc/resolv.conf,
so it seems the merge-hook could be modified to simply do:
/usr/bin/resolvconf -a rdnssd < /run/rdnssd/resolv.conf
It could then be cleaned up on stop from the rdnssd.service file with
ExecStop=/usr/bin/resolvconf -d rdnssd

Steps to reproduce:
1) Set up a host on the local subnet to send router advertisements with RDNSS info.
2) systemctl start rdnssd
3) wait for the RDNSS entry to appear in /etc/resolv.conf (may take several minutes)
4) do anything that causes resolvconf to rewrite /etc/resolv.conf like 'netctl restart eth0' or just 'resolvconf -u'
This task depends upon

Closed by  Sébastien Luttringer (seblu)
Tuesday, 26 August 2014, 08:56 GMT
Reason for closing:  Implemented
Additional comments about closing:  ndisc6-1.0.2-8
Comment by Sébastien Luttringer (seblu) - Tuesday, 19 August 2014, 12:19 GMT
Best option I see, is to:
1) put a resolvconf compatible merge hook in /etc/rdnssd/resolvconf-merge-hook.
2) override systemd service (via drop-in.d) to use this hook (instead of the default one)

We could eventually ship a compatible merge hook in the package, as an alternative. I will, if you provide it, but I will not make the package conflict with resolvconf, this is not a packaging conflict.

Side note: netctl should go away from base, networkd do the job now.
Comment by Ed Branch (branch) - Sunday, 24 August 2014, 16:12 GMT
Sounds good. Sorry, I did not mean to imply a package conflict, just an operational one. The following files seem to basically work:

=================================
/usr/lib/systemd/system/rdnssd-resolvconf.service
=================================
[Unit]
Description=RDNSS daemon for Linux
Before=network.target
Requires=network.target

[Service]
Type=forking
PIDFile=/run/rdnssd.pid
ExecStart=/usr/bin/rdnssd -H /etc/rdnssd/resolvconf-merge-hook
ExecStop=/usr/bin/bash -c '/usr/bin/resolvconf -d rdnssd || /usr/bin/true'

[Install]
WantedBy=multi-user.target

=================================
/etc/rdnssd/resolvconf-merge-hook
=================================
#!/usr/bin/bash

if [ -f /run/rdnssd/resolv.conf ]; then
/usr/bin/resolvconf -a rdnssd < /run/rdnssd/resolv.conf
fi
Comment by Sébastien Luttringer (seblu) - Monday, 25 August 2014, 14:01 GMT
I strongly modified the .service file. It's now rdnssd@.service file, so to have an old behavior you should do systemctl enable rdnssd@merge-hook.service. Otherwise to use the resolvconf hook you should do systemctl enable rdnssd@resolvconf-hook.service.

Could you test ndisc6-1.0.2-8 in cty-testing?
Comment by Ed Branch (branch) - Tuesday, 26 August 2014, 02:11 GMT
ndisc6-1.0.2-8 works great, thanks.

Loading...