<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<atom:link href="https://dev1galaxy.org/extern.php?action=feed&amp;tid=4651&amp;type=rss" rel="self" type="application/rss+xml" />
		<title><![CDATA[Dev1 Galaxy Forum / pdns-server in Debian 11 comes without init script]]></title>
		<link>https://dev1galaxy.org/viewtopic.php?id=4651</link>
		<description><![CDATA[The most recent posts in pdns-server in Debian 11 comes without init script.]]></description>
		<lastBuildDate>Sun, 07 Nov 2021 22:17:51 +0000</lastBuildDate>
		<generator>FluxBB</generator>
		<item>
			<title><![CDATA[Re: pdns-server in Debian 11 comes without init script]]></title>
			<link>https://dev1galaxy.org/viewtopic.php?pid=32666#p32666</link>
			<description><![CDATA[<p>Addendum: Might have been included in orphan-sysvinit-scripts (not checked):</p><p><a href="https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=997835" rel="nofollow">https://bugs.debian.org/cgi-bin/bugrepo … bug=997835</a></p>]]></description>
			<author><![CDATA[dummy@example.com (dl1ps)]]></author>
			<pubDate>Sun, 07 Nov 2021 22:17:51 +0000</pubDate>
			<guid>https://dev1galaxy.org/viewtopic.php?pid=32666#p32666</guid>
		</item>
		<item>
			<title><![CDATA[pdns-server in Debian 11 comes without init script]]></title>
			<link>https://dev1galaxy.org/viewtopic.php?pid=32665#p32665</link>
			<description><![CDATA[<p>Upgrading to Devuan 4, i have noticed that the package is missing the init script. The bug was already filed at the Debian side:</p><p><a href="https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=997054" rel="nofollow">https://bugs.debian.org/cgi-bin/bugrepo … bug=997054</a></p><p>where the bug filer asked to keep the init script included. Unfortunately, the wish sounded more like a demand (for init freedom) and was abruptly declined by the package maintainer.</p><p>If somebody is using powerdns as authoritative nameserver the following script taken from a Devuan 3 installation still works:</p><div class="codebox"><pre class="vscroll"><code>∴root∴/u/l/bin $ cat /etc/init.d/pdns
#!/bin/sh
### BEGIN INIT INFO
# Provides:          pdns
# Required-Start:    $network $remote_fs $syslog
# Required-Stop:     $network $remote_fs $syslog
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Should-Start:      slapd
# Should-Stop:       slapd
# Short-Description: PowerDNS Authoritative Name Server
# Description: PDNS is a versatile high performance authoritative nameser
### END INIT INFO

PATH=/bin:/sbin:/usr/bin:/usr/sbin
BINARYPATH=/usr/bin
SBINARYPATH=/usr/sbin

ODESC=&quot;PowerDNS Authoritative Name Server&quot;
DESC=&quot;$ODESC&quot;
NAME=pdns
DAEMON=/usr/sbin/pdns_server
DAEMON_ARGS=&quot;&quot;
CONTROL=/usr/bin/pdns_control
PIDFILE=/var/run/$NAME.pid
SCRIPTNAME=/etc/init.d/$NAME

[ -x &quot;$DAEMON&quot; ] || exit 0

[ -r /etc/default/pdns ] &amp;&amp; . /etc/default/pdns

# Handle instance scripts
suffix=$(basename $0 | cut -d- -f2- -s)

if [ -n &quot;$suffix&quot; ]; then
        SUFFIX=&quot;--config-name=$suffix&quot;
        DAEMON_ARGS=&quot;$DAEMON_ARGS $SUFFIX&quot;
        NAME=&quot;$NAME-$suffix&quot;
        DESC=&quot;$DESC (config name $suffix)&quot;
        PIDFILE=&quot;/var/run/$NAME-$suffix.pid&quot;
fi

# Load lsb stuff for systemd redirection (if available).
if [ -e /lib/lsb/init-functions ]; then
  . /lib/lsb/init-functions
fi

# function to invoke properly parametrized pdns_control
doPC()
{
    $CONTROL $SUFFIX $1 $2 2&gt; /dev/null
        return $?
}

isrunning()
{
        doPC ping &gt; /dev/null
        return $?
}

#
# Function that starts the daemon/service
#
do_start()
{
        # Return
        #   0 if daemon has been started
        #   1 if daemon was already running
        #   2 if daemon could not be started
        if isrunning; then
                return 1
        fi
        start-stop-daemon --start --quiet \
                --pidfile $PIDFILE --exec $DAEMON -- \
                $DAEMON_ARGS --daemon --guardian=yes \
                || return 2
}

#
# Function that stops the daemon/service
#
do_stop()
{
        # Return
        #   0 if daemon has been stopped
        #   1 if daemon was already stopped
        #   2 if daemon could not be stopped
        #   other if a failure occurred
        doPC quit &gt;/dev/null
        RETVAL=&quot;2&quot;
        for sec in $(seq 1 5); do
                if ! isrunning; then
                        RETVAL=&quot;0&quot;
                        break
                fi
                sleep 1
        done
        [ &quot;$RETVAL&quot; = 2 ] &amp;&amp; return 2
        rm -f $PIDFILE
}

case &quot;$1&quot; in
  start)
        echo -n &quot;Starting $DESC: $NAME ...&quot;
        do_start
        case &quot;$?&quot; in
                0|1)
                        echo done
                        exit 0
                        ;;
                2)
                        echo failed
                        exit 1
                        ;;
        esac
        ;;
  stop)
        echo -n &quot;Stopping $DESC: $NAME ...&quot;
        do_stop
        case &quot;$?&quot; in
                0|1)
                        echo done
                        exit 0
                        ;;
                2)
                        echo failed
                        exit 1
                        ;;
        esac
        ;;
  status)
        if isrunning; then
                echo &quot;$NAME is running: $(doPC status)&quot;
                exit 0
        else
                echo &quot;$NAME is not running&quot;
                exit 3
        fi
        ;;
  force-stop)
        echo -n &quot;Killing $ODESC (all instances): $NAME ...&quot;
        kill -9 $(pidof pdns_server)
        case &quot;$?&quot; in
                0)
                        echo done
                        exit 0
                        ;;
                1)
                        echo failed
                        exit 1
                        ;;
        esac
        ;;
  restart)
        echo -n &quot;Restarting $DESC: $NAME ...&quot;
        do_stop
        case &quot;$?&quot; in
                0|1)
                        do_start
                        case &quot;$?&quot; in
                                0)
                                        echo done
                                        exit 0
                                        ;;
                                1)
                                        echo failed  # Old process is still running
                                        exit 1
                                        ;;
                                *)
                                        echo failed # Failed to start
                                        exit 1
                                        ;;
                        esac
                        ;;
                *)
                        # Failed to stop
                        echo failed
                        exit 1
                        ;;
        esac
        ;;
  reload|force-reload)
        echo -n &quot;Reloading $DESC: $NAME ...&quot;
        if isrunning; then
                doPC cycle &gt;/dev/null
                case &quot;$?&quot; in
                        0)
                                echo done
                                exit 0
                                ;;
                        1)
                                echo failed
                                exit 1
                                ;;
                esac
        else
                echo done
                exit 7
        fi
        ;;
  monitor)
        if isrunning; then
                echo &quot;already running&quot;
                exit 1
        else
                $DAEMON $DAEMON_ARGS --daemon=no --guardian=no --control-console --loglevel=9
                exit 0
        fi
        ;;
  dump)
        if isrunning; then
                doPC list
                exit 0
        else
                echo &quot;not running&quot;
                exit 7
        fi
        ;;
  show)
        if isrunning; then
                if [ $# -lt 2 ]; then
                        echo &quot;Insufficient parameters&quot;
                        exit 2
                fi
                echo -n &quot;$2=&quot;
                doPC show $2
                exit 0
        else
                echo &quot;not running&quot;
                exit 7
        fi
        ;;
  mrtg)
        if isrunning; then
                if [ $# -lt 2 ]; then
                        echo &quot;Insufficient parameters&quot;
                        exit 2
                fi
                doPC show $2
                if [ &quot;$3x&quot; != &quot;x&quot; ]; then
                        doPC show $3
                else
                        echo 0
                fi
                doPC uptime
                echo &quot;$DESC&quot;
                exit 0
        else
                echo &quot;not running&quot;
                exit 7
        fi
        ;;
  cricket)
        if isrunning; then
                if [ $# -lt 2 ]; then
                        echo &quot;Insufficient parameters&quot;
                        exit 1
                fi
                doPC show $2
                exit 0
        else
                echo &quot;not running&quot;
                exit 7
        fi
        ;;
  *)
        echo &quot;Usage: $SCRIPTNAME {start|stop|status|force-stop|restart|reload|monitor|dump|show|mrtg|cricket}&quot;
        ;;
esac

exit 0</code></pre></div><p>&#160; </p><p>Maybe its possible to fork pdns-server (pdns-recursor is still forked) for devuan to resolve this issue. </p><p>Many, Many thanks for the efforts in maintaining init freedom!!!!!!</p>]]></description>
			<author><![CDATA[dummy@example.com (dl1ps)]]></author>
			<pubDate>Sun, 07 Nov 2021 22:09:28 +0000</pubDate>
			<guid>https://dev1galaxy.org/viewtopic.php?pid=32665#p32665</guid>
		</item>
	</channel>
</rss>
