Master File Format
(From RFC 1035, pages 33-35)
The format of these files is a sequence of entries. Entries are
predominantly line-oriented, though parentheses can be used to
continue a list of items across a line boundary, and text literals
can contain CRLF within the text. Any combination of tabs and spaces
acts as a delimiter between the separate items that make up an entry.
The end of any line in the
master file can end with a
comment. The comment starts with a semicolon (;).
The following entries are defined:
blank[comment] $ORIGIN domain-name [comment] $INCLUDE file-name [domain-name] [comment] domain-namerr [comment] blankrr [comment]
Blank lines, with or without comments, are allowed anywhere in the file.
Two control entries are defined: $ORIGIN and $INCLUDE. $ORIGIN is followed by a domain name and resets the current origin for relative domain names to the stated name. $INCLUDE inserts the named file into the current file and may optionally specify a domain name that sets the relative domain name origin for the included file. $INCLUDE may also have a comment. Note that an $INCLUDE entry never changes the relative origin of the parent file, regardless of changes to the relative origin made within the included file.
The last two forms represent RRs. If an entry for an RR begins with a
blank, then the RR is assumed to be owned by the last stated owner.
If an RR entry begins with a domain-name,
then the owner name is reset.
rr contents take one of the following forms:
[ TTL] [ class] ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access