I am trying to use unbound to forward requests to a pair of dns servers, while answering a small hand full of queries locally. In testing this out, I have built the following configuration at /etc/unbound/conf.d/my.zone.com.conf
forward-zone:
name: "my.zone.com"
forward-addr: 1.2.3.4 # my DNS server
forward-addr: 1.2.3.5 # my other DNS server
local-data: "server1.my.zone.com. IN A 1.2.3.6"
local-data-ptr: "1.2.3.6 server1.my.zone.com"
When running unbound-checkconf I get the following error:
$ unbound-checkconf
/etc/unbound.conf.d/my.zone.com.conf:8: error: syntax error
read /etc/unbound.conf.d/my.zone.com.conf failed: 1 errors in configuration file
$
My desired behavior is that unbound should forward all requests to the DNS servers 1.2.3.4
, and 1.2.3.5
, but should respond with local information for server1.my.zone.com
.
I have looked through a number of lengthy config file examples on line, but I just don't see what I am doing wrong - though I suspect it has to do with local-data
and local-data-ptr
nested inside forward-zone
.
The config file at /etc/unbound/unbound.conf
remains unchanged from the default yum install in centos7.
Thanks in advance for your help