[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: /run and read-only /etc

On 8 April 2003 "Marco d'Itri" <md@Linux.IT> wrote:
> On Apr 07, Thomas Hood <jdthood0@yahoo.co.uk> wrote:
>>A difficulty is that only a whole "options { ... };"
>>statement can be included from the named configuration file,
>>not just the "forwarders { ... };" statement inside it.
>You can include a file even inside the options keyword.

On 8 April 2003 "Anthony DeRobertis" <asd@suespammers.org> wrote:
> Just tested it (with a different option than forwarders) and it
> seems you can certainly use
>	include "file";
> inside of options { ... }.

Unfortunately you seem to be wrong, at least with regard to
bind version 1:8.3.4-4.  If named.conf (or named.conf.options)

    options {
        directory "/var/cache/bind";
        include "/run/bind/named.forwarders";

and /run/bind/named.forwarders contains (with a real address
in place of "aa.bb.cc.dd"):

    forwarders { 

then an error message is printed in the syslog on named reload:

    Apr 15 20:34:24 thanatos named[25582]: /etc/bind/named.conf:23:
    syntax error near include

whereas if /etc/bind/named.conf contains:

    options {
        directory "/var/cache/bind";
        forwarders { 

then there is no error message.  It seems that the documentation is
telling the truth when it says (/usr/share/doc/bind/html/include.html):

    The include statement inserts the specified file
    at the point that the include statement is encountered.
    It cannot be used within another statement, though,
    so a line such as
      acl internal_hosts { include "internal_hosts.acl"; };                                                                                      
   is not allowed.

Were the two of you running a different version of bind?

On 8 April I wrote:
> I'm glad to hear this because it means that one could
> include a file containing only the "forwarders { }"
> statement.

I'm now disappointed to discover that this is not possible.

Thomas Hood <jdthood0@yahoo.co.uk>

Reply to: