PowerDNS / pdns

PowerDNS Authoritative, PowerDNS Recursor, dnsdist
https://www.powerdns.com/
GNU General Public License v2.0
3.63k stars 904 forks source link

[Doc] webserver-address unlike local-address #8625

Open candlerb opened 4 years ago

candlerb commented 4 years ago

Short description

pdns-recursor gives exception on startup if you list multiple addresses in webserver-address. It's correct behaviour but I was surprised that it doesn't behave the same as local-address.

Environment

Steps to reproduce

webserver=yes
webserver-address=0.0.0.0,::

Expected behaviour

I expected it to work like local-address, where to listen on both v4 and v6 you would do:

local-address=0.0.0.0,::

Actual behaviour

Dec 12 12:49:00 cache1 pdns_recursor[19826]: Enabling web server
Dec 12 12:49:00 cache1 pdns_recursor[19826]: Exception: Unable to convert presentation address '0.0.0.0,::'
Dec 12 12:49:00 cache1 pdns_recursor[19826]: terminate called after throwing an instance of 'PDNSException'
Dec 12 12:49:00 cache1 systemd[1]: Starting Apport crash forwarding receiver...
-- Subject: Unit apport-forward@7-unknown.service has begun start-up
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
--
-- Unit apport-forward@7-unknown.service has begun starting up.

Other information

It appears I can get the behaviour I want simply by using:

webserver-address=::

(i.e. it opens a dual-protocol socket). Other people might want to bind to an explicit IPv4 and IPv6 address; I don't need this.

On careful reading of the documentation, it does say that webserver-address allows IP Address, while local-address allows IP addresses, comma separated.

But I think this could be made clearer in the doc and/or sample config:

Habbie commented 4 years ago

960 complains about the missing feature instead of the lack of docs on this.