Fully Qualified Domain Name
A Fully Qualified Domain Name (FQDN) is a domain that is identified all the way up to root.
Remember, the very top level of the domain name system is root, a simple period: . After that comes the top-level domain like com., net., and org., and after that comes the second-level domain you purchase at a registrar like ircnow.org.
For example, example.com. is a FQDN because it has a period at the very end. On the other hand, example.com is not a FQDN because it lacks the period at the very end.
In short: Look for the dot at the end!
$ORIGIN
Zone files automatically append the $ORIGIN at the end of every name in a zone file unless it is a FQDN. For example, this zone file snippet does something completely unexpected:
$ORIGIN example.com. www.example.com IN A 10.0.0.1
The name server will append example.com to the end of www.example.com to give you www.example.com.example.com. Instead of defining www.example.com's IP to be 10.0.0.1, it defines www.example.com.example.com's IP to be 10.0.0.1. That's probably NOT what you want.
The reason why the zone file appends $ORIGIN to the end of every name is to make it easier to write the zone file using shorthand:
$ORIGIN example.com. www IN A 10.0.0.1
Here, instead of defining www's IP to be 10.0.0.1 (which would be impossible anyway since we don't own the www top level domain), the name server will append $ORIGIN at the end of www. This means that www.example.com's IP is 10.0.0.1.
Any name you see in a zone file will automatically be appended with the current $ORIGIN unless it's a FQDN (unless it has a period at the end). For example:
$ORIGIN example.com. IN NS ns1 IN NS ns2 www IN A 10.0.0.1 ns1 IN A 10.0.0.2 ns2 IN A 10.0.0.3 irc IN CNAME www mail IN CNAME mail.ircnow.org.
When there is no name entry at all but a name is still needed, the previous name is used. If there is no previous name, $ORIGIN is used. So the NS record for the 'blank' name means that example.com.'s nameservers are ns1.example.com. and ns2.example.com. These have IPs 10.0.0.2 and 10.0.0.3.
www.example.com. has IP 10.0.0.1, and irc.example.com. has a CNAME record that points to www.example.com. So, irc.example.com. also has IP 10.0.0.1.
mail.example.com, however, has a CNAME which points to the FQDN mail.ircnow.org. $ORIGIN is not appended here because there is a dot at the very end.
DNS Records | DNS Zone Files | vhost | dig | host |
unbound | NSD |