[Pdns-users] DNS Forwarding on Master/Slave Servers

Steven Garner stevenjgarner at gmail.com
Fri May 7 21:38:09 UTC 2021


Many thanks.  I'm doing something wrong as I got a malformed entry.  Here's
what I did:

1) I went with the purge autoremove:

# apt-get --purge autoremove pdns-server pdns-backend-mysql
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
  libboost-program-options1.71.0* libmysqlclient21* pdns-backend-bind*
pdns-backend-mysql* pdns-server*
0 upgraded, 0 newly installed, 5 to remove and 13 not upgraded.
After this operation, 21.8 MB disk space will be freed.
Do you want to continue? [Y/n] Y
(Reading database ... 116529 files and directories currently installed.)
Removing pdns-backend-bind (4.2.1-1build2) ...
Removing pdns-backend-mysql (4.2.1-1build2) ...
Removing pdns-server (4.2.1-1build2) ...
Removing libboost-program-options1.71.0:amd64 (1.71.0-6ubuntu6) ...
Removing libmysqlclient21:amd64 (8.0.23-0ubuntu0.20.04.1) ...
Processing triggers for man-db (2.9.1-1) ...
Processing triggers for libc-bin (2.31-0ubuntu9.2) ...
(Reading database ... 116476 files and directories currently installed.)
Purging configuration files for pdns-backend-bind (4.2.1-1build2) ...
dpkg: warning: while removing pdns-backend-bind, directory
'/etc/powerdns/pdns.d' not empty so not removed
Purging configuration files for pdns-server (4.2.1-1build2) ...
dpkg: warning: while removing pdns-server, directory '/etc/powerdns' not
empty so not removed
Processing triggers for systemd (245.4-4ubuntu3.6) ...


2) I then created the suggested files (using your suggested focal-auth-44):

Create the file: '/etc/apt/sources.list.d/pdns.list' with this content:

deb [arch=amd64] http://repo.powerdns.com/ubuntu focal-auth-44

Created the file: '/etc/apt/preferences.d/pdns':

Package: pdns-*

Pin: origin repo.powerdns.com

Pin-Priority: 600

3) I then executed the update & install, getting the malformed entry:

# curl https://repo.powerdns.com/CBC8B383-pub.asc | sudo apt-key add - &&
> sudo apt-get update &&
> sudo apt-get install pdns-server pdns-backend-mysql
  % Total    % Received % Xferd  Average Speed   Time    Time     Time
 Current
                                 Dload  Upload   Total   Spent    Left
 Speed
100  1682  100  1682    0     0   1990      0 --:--:-- --:--:-- --:--:--
 1988
OK
E: Malformed entry 1 in list file /etc/apt/sources.list.d/pdns.list
(Component)
E: The list of sources could not be read.


4) Not being sure of what to do, I checked on the website
https://repo.powerdns.com/ubuntu/ and noticed it is actually
https://repo.powerdns.com/ubuntu/dists/.  So I modified the content of
/etc/apt/sources.list.d/pdns.list:

deb [arch=amd64] http://repo.powerdns.com/ubuntu/dists/focal-auth-44


- and ran it again - still got a:

E: Malformed entry 1 in list file /etc/apt/sources.list.d/pdns.list (Suite)


I do not understand what to do here.  Looking at the website, should I be
using:

https://repo.powerdns.com/ubuntu/dists/focal-auth-44/main/binary-amd64/Packages


Also intrigued why we are using
https://repo.powerdns.com/ubuntu/dists/focal-auth-44/ and not
https://repo.powerdns.com/ubuntu/dists/focal-auth-master/ - maybe because
it was just listed today?  So what exactly does the content of
the /etc/apt/sources.list.d/pdns.list file need to be?

5) Just to have a semi-functional pdns server, I removed the two files and
reinstalled 4.2.1:

sudo apt update && sudo apt install pdns-server pdns-backend-mysql -y


Many thanks in advance.


Steve Garner
+1 302 364 0325
stevenjgarner at gmail.com


On Fri, May 7, 2021 at 12:09 PM Brian Candler <b.candler at pobox.com> wrote:

> On 07/05/2021 11:35, Steven Garner wrote:
>
>  I thought the best practice to ensure current software on Ubuntu was to
> use apt, first to update and then to install:
>
> sudo apt update
> sudo apt install pdns-server pdns-backend-mysql -y
>
>
> That gives you some version which has probably percolated down from the
> Debian repositories, and could be very old and stale.  In the case of
> Ubuntu 16.04 they published an alpha version (4.0.0~alpha2) with
> significant bugs, and never updated it to the release.
>
> So you're much better off getting the packages from the powerdns repo.
>
>
>
>
> I understand from your referenced documentation (
> https://repo.powerdns.com/), that the preferred installation method for
> "PowerDNS Authoritative Server - master branch" on Ubuntu 20.04 "Focal
> Fossa" is to:
>
> Create the file '/etc/apt/sources.list.d/pdns.list' with this content:
>
> deb [arch=amd64] http://repo.powerdns.com/ubuntu bionic-auth-master main
>
> Two problems with that.
>
> 1. The master branch is the development tip.  Only use this if you're
> participating in the development of the *next* release (e.g. testing new
> features).  Don't use it in production: you need to choose the 44 branch.
>
> 2. Ubuntu 20.04 is "focal", not "bionic".
>
> So the branch you want is focal-auth-44
>
>
>
> There is nothing there about installing the preferred backend, but would I
> be correct in assuming I could extend that last line to read:
>
> sudo apt install pdns-server pdns-backend-mysql
>
>
> Yes - the repo has the backend packages too.
>
>
> I find the documentation on upgrading pdns (
> https://doc.powerdns.com/authoritative/upgrading.html) to be highly
> contextual and difficult to follow, in that there does not appear to be
> procedures set forth to actually upgrade any distribution.
>
> So instead of upgrading, do I first uninstall, remove and purge the old
> pdns 4.2.1 installation and then follow the installation of the latest
> master branch above?
>
> apt-get --purge autoremove pdns-server pdns-backend-mysql
>
> It doesn't really matter.  After adding the new repo, a simple
>
> apt-get update
> apt-get dist-upgrade
>
> will install the newer packages.  It will be up to you to ensure the
> configs are valid for the new version, but they usually are (and you can
> compare with the .dpkg-dist files to see what's new)
>
> If you prefer to purge and reinstall, that's fine too.
>
>
> I'm assuming as a backend, the apt-updated version of MySQL is adequate:
>
> mysql  Ver 8.0.23-0ubuntu0.20.04.1 for Linux on x86_64 ((Ubuntu))
>
>
> ... where all the domain and record information will persist.
>
> I don't use mysql with pdns, but I suggest you read the release notes and
> look for provisos for Mysql 8, for example:
>
>
> https://doc.powerdns.com/authoritative/upgrading.html#mysql-character-set-detection
>
> Regards,
>
> Brian.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.powerdns.com/pipermail/pdns-users/attachments/20210507/b6811db1/attachment-0001.htm>


More information about the Pdns-users mailing list