named.conf configuration file for named(8)OverviewBIND 8 is much more configurable than previous releases of BIND. There are entirely new areas of configuration, such as access control lists and categorized logging. Many options that previously applied to all zones can now be used selectively. These features, plus a consideration of future configuration needs led to the creation of a new configuration file format. General SyntaxA BIND 8 configuration consists of two general features, statements and comments. All statements end with a semicolon. Many statements can contain substatements, which are each also terminated with a semicolon. The following statements are supported:
The logging and options statements may only occur once per configuration, while the rest may appear numerous times. Further detail on each statement is provided in individual sections following. Comments may appear anywhere that whitespace may appear in a BIND configuration file. To appeal to programmers of all kinds, they can be written in C, C++, or Shell/Perl constructs. C-style comments start with the two characters /* (slash, star) and end with */ (star, slash). Because they are completely delimited with these characters, they can be used to comment only a portion of a line or to span multiple lines. C-style comments can't be nested. For example, the following is not valid because the entire comment ends with the first */: /* This is the start of a comment. This is still part of the comment. /* This is an incorrect attempt at nesting a comment. */ This is no longer in any comment. */ C++-style comments start with the two characters // (slash, slash) and continue to the end of the physical line. They can't be continued across multiple physical lines; to have one logical comment span multiple lines, each line must use the // pair. For example // This is the start of a comment. The next line // is a new comment, even though it is logically // part of the previous comment. Shell-style (or Perl-style, if you prefer) comments start with the character # (hash or pound or number or octothorpe or whatever) and continue to the end of the physical line, like C++ comments. For example # This is the start of a comment. The next line # is a new comment, even though it is logically # part of the previous comment. Warning You cannot use the ; (semicolon) character to start a comment such as you would in a zone file. The semicolon indicates the end of a configuration statement, so whatever follows it will be interpreted as the start of the next statement. |