Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 485198

Summary: net-dns/pdns-recursor - Improved chroot support
Product: Gentoo Linux Reporter: Thomas Deutschmann (RETIRED) <whissi>
Component: Current packagesAssignee: Sven Wegener <swegener>
Status: UNCONFIRMED ---    
Severity: normal Keywords: PATCH
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Package list:
Runtime testing required: ---
Attachments: pdns-recursor-3.5.3.ebuild
Updated init script
Added file for /etc/rsyslog.d
Updated configuration file

Description Thomas Deutschmann (RETIRED) gentoo-dev 2013-09-17 14:40:07 UTC

per default, pdns-recursor is running in a chrooted environment, which is a good thing. But we have to make sure, that this chroot environment is up to date.

Also there is a problem with /dev/log, which will disappear when logs get rotated (=pdns-recursor will stop logging).

I fixed these things. Would be nice if you could add these improvements to the tree.

Reproducible: Always
Comment 1 Thomas Deutschmann (RETIRED) gentoo-dev 2013-09-17 14:41:04 UTC
Created attachment 358862 [details]

The symlink loop is now part of the init script.
Comment 2 Thomas Deutschmann (RETIRED) gentoo-dev 2013-09-17 14:41:34 UTC
Created attachment 358864 [details]
Updated init script
Comment 3 Thomas Deutschmann (RETIRED) gentoo-dev 2013-09-17 14:43:28 UTC
Created attachment 358866 [details]
Added file for /etc/rsyslog.d

This file will make sure, that /var/lib/pdns-recursor/dev/log will exist, so that pdns-recursor is still able to log, also after logrotation.
Comment 4 Thomas Deutschmann (RETIRED) gentoo-dev 2013-09-17 14:43:53 UTC
Created attachment 358868 [details]
Updated configuration file
Comment 5 Thomas Deutschmann (RETIRED) gentoo-dev 2013-09-17 14:47:47 UTC
The attached files are current for today, 2013-09-17, but I don't know when you (the maintainer) will have a look at this bug report, so please check my overlay for any updates, thanks!
Comment 6 Jeroen Roovers (RETIRED) gentoo-dev 2013-09-17 15:03:59 UTC
Comment on attachment 358862 [details]

--- pdns-recursor-3.5.1.ebuild  2013-05-04 22:54:57.000000000 +0200
+++ -   2013-09-17 17:03:50.127424768 +0200
@@ -2,7 +2,7 @@
 # Distributed under the terms of the GNU General Public License v2
 # $Header: /var/cvsroot/gentoo-x86/net-dns/pdns-recursor/pdns-recursor-3.5.1.ebuild,v 1.1 2013/05/04 20:54:57 swegener Exp $
 inherit toolchain-funcs flag-o-matic eutils
@@ -27,6 +27,7 @@
 src_prepare() {
        epatch "${FILESDIR}"/${PN}-
+       epatch_user
        sed -i -e s:/var/run/:/var/lib/powerdns: "${S}"/config.h || die
@@ -52,9 +53,11 @@
        insinto /etc/powerdns
        doins "${FILESDIR}"/recursor.conf
-       doinitd "${FILESDIR}"/precursor
+       insinto /etc/rsyslog.d
+       newins "${FILESDIR}"/pdns-recursor.rsyslog pdns-recursor.conf
-       # Pretty ugly, uh?
-       dodir /var/lib/powerdns/var/lib
-       dosym ../.. /var/lib/powerdns/var/lib/powerdns
+       newinitd "${FILESDIR}"/pdns-recursor.initd ${PN}
+       keepdir "/var/lib/powerdns"
+       keepdir "/var/lib/powerdns/dev"