Monday, 6 February 2017

# got me again

In pretty much every program I use, # at the start of a line means that the rest of the line is a comment. That's useful, not only for comments, but also for temporarily disabling a line.

Except bind.

In bind a ; at the start of a line signifies a comment, and it doesn't recognise a #

Oh, but it's more subtle than that. You can use # for a comment in the named.conf file. But not in the  zone files.

It gets me every time. I make a change in my DNS files, perhaps commenting out a line, and then the DNS doesn't work becuase I used # instead of ;

Please, O people who maintain bind, allow # to start a comment line.


  1. Why just add a comment to the top of the file to remind you that you need to use semicolon instead of hash?

  2. Nice idea. But I already hav comments in the file starting with a semicolon. So another comment probably won't help.

    Better would be if the maintainers of bind conform to the way everyone else does comments (except assembler).