[SOLVED] Problem adding custom options to unbound

Started by guest15512, November 27, 2017, 12:22:53 PM

Previous topic - Next topic
Hi all,

I am trying to add "do-not-query-localhost: no" to unbound's custom options, but unbound daemon doesn't start. Returns the following error:

opnsense: /status_services.php: The command '/usr/local/sbin/unbound -c '/var/unbound/unbound.conf'' returned exit code '1', the output was '/var/unbound/unbound.conf:137: error: syntax error read /var/unbound/unbound.conf failed: 1 errors in configuration file [1511781603] unbound[94187:0] fatal error: Could not read config file: /var/unbound/unbound.conf'

Under /var/unbound/unbound.conf, I see this option outside server options ... Why? is it a bug?

On the other side, how can I configure a forwarder for unbound? I need to add something like:

forward-zone:
    name: *
    forward-addr: 10.1.5.23@5353

Thanks


The custom options are appended. If they are required to be in a specific block, that doesn't work then. We should consider to add support for the feature you are trying to set manually? If yes, please file a request here:

https://github.com/opnsense/core/issues


Cheers,
Franco

unbound allows duplicate blocks, so this should work, hopefully.

server:
  do-not-query-localhost: no

forward-zone:
  name: *
  forward-addr: 10.1.5.23@5353

Ok, I have solved adding include files in advanced options.

Thanks for your help