[nsd-users] include order

Hendrik Jaeger nsd at henk.geekmail.org
Fri Nov 9 14:58:48 UTC 2018


Hi

I was having a problem with my puppet-generated nsd-config: it worked
on one and did not work on the other host.
That was very confusing for me as everything was based on the same
templates and the configs were mostly identical (apart from
hostnames/IPs).

After some debugging with the help of a friend the cause was found:
the 'include' directive does not do what I expected it to do when
using globbing, which is including the files in lexical order.
It actually includes the files in "directory order".

This directory order was different for the two hosts since puppet
decided the order in which it created files and that happened to be
different for the two hosts.
The result was that the file with additional "server"-settings was
included after the files providing "pattern"s and "zone"s and thus I
got a "syntax error".

IMHO the files should be included in lexical order.
That’s what people usually expect, as that is what (most) other
software does, e.g. run-parts.

Is there any reason why "GLOB_NOSORT" and thus "directory order" is
used?
Could it be changed to include globbed files in lexical order?

Thank you

Hendrik Jäger


-- 
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing in e-mail?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <http://lists.nlnetlabs.nl/pipermail/nsd-users/attachments/20181109/b0edd89d/attachment.bin>


More information about the nsd-users mailing list