The following zone file has been compiled for the domain `grossefirma.de:
$ORIGIN grossefirma.de. $TTL 86400 ; SOA Records @ IN SOA hydrogen.ns.hetzner.com. dns.hetzner.com. 2020042701 86400 10800 3600000 3600 ; NS Records @ IN NS helium.ns.hetzner.de. @ IN NS hydrogen.ns.hetzner.com. @ IN NS oxygen.ns.hetzner.com. ; A Records @ IN A 127.0.0.1 mail IN A 127.0.0.1 www IN A 127.0.0.1 ; Others @ IN MX 10 mail
$TTL 86400 @ IN SOA hydrogen.ns.hetzner.com. dns.hetzner.com. 2020042701 86400 10800 3600000 3600
- The DNS zone has a TTL (Time To Live) of 86400 seconds ($TTL 86400).
- The name server
hydrogen.ns.hetzner.comis responsible for the internet domain. (The @ character is a placeholder for the domain
- The period at the end of
hydrogen.ns.hetzner.com.prevents the primary name server from being called
- The email address for the administrator is
email@example.com. (The first period is always replaced by the
- The zone file was last changed on 27 April 2020; this was the second change made on that day.
- The secondary name server undertakes changes from the primary name server every 24 hours (TTL = 86,400 seconds; Time To Live).
- In the event of an error, the secondary name server attempts synchronization again after 3 hours (3600 seconds).
- If the secondary name server has not created synchronization with the primary name server after 1000 hours (3,600,000 seconds), it declares the domain invalid.
- The entries are normally valid for 24 hours (86400 seconds) if no other value is defined.
- Other name servers remember "negative" answers, so requests for non-existant hosts are likewise 24 hours.
@ IN NS helium.ns.hetzner.de. @ IN NS hydrogen.ns.hetzner.com. @ IN NS oxygen.ns.hetzner.com.
- These 3 NS record specify
oxygen.ns.hetzner.com.com as responsible/authoritative nameservers.
- The period at the end of the lines is required. Otherwise the main domain
grossefirma.deis attached at the end, and
helium.ns.hetzner.de.grossefirma.de. This would be nonsense in this case.
- IP addresses are not permitted in NS records. If you are using your own name server (whose hostname should be
ns1.grossefirma.de), define the appropriate A record and specify Glue with the domain's registrar. Registering the name server may be required as well, depending on the top level domain.
@ IN A 22.214.171.124 www IN A 126.96.36.199 mail IN A 188.8.131.52
- Enquiries, for example, in the web browser for
www.) are resolved to
www.grossefirma.dehas the IP address
- A host called
mail.grossefirma.deexists, but it is not clear from this entry whether this is also the responsible/authoritative mail server.
pop IN CNAME www smtp IN CNAME www relay IN CNAME www imap IN CNAME www ftp 3600 IN CNAME ftp.anderedomain.de.
www.grossefirma.dehas the following additional names
ftp.grossefirma.deis forwarded as
ftp.anderedomain.de, as the period at the end prevents resolution to
ftp.grossefirma.deis valid for one hour only (3600 seconds); therefore, changes to the entries become known relatively quickly to the name servers on the worldwide internet. Important note: As long as the secondary name server still publishes the old values, this will result in a delay in possible changes to the data; therefore, you should also shorten the refresh time in the SOA record.
Note: If a subdomain already has a CNAME record, then you cannot set any further record types for this subdomain.
@ IN MX 10 mail
- There is only one mail server and this is
- IP addresses are not allowed for MX records.
- CNAMEs are not allowed in MX records; they are only allowed as aliases for A records.
- You can list further mail servers in an additional line, but this doesn't often make much sense.
- With several mail servers, the one with the least priority (here 10) is given preference.
technik IN A 184.108.40.206 technik IN MX 10 technik
- A subdomain is created within the zone file; however, it is not delegated to an external name server.
- The host
technik.grossefirma.deis the responsible/authoritative host for the subdomain
technik.grossefirma.de, which resolves to IP address
@ IN TXT "v=spf1 mx -all"
grossefirma.dehas a TXT record `v=spf1 mx -all
- This record type can be used for SPF (Sender Policy Framework)
As an alternative to the procedure described above under "Subdomain", you could instead delegate subdomains to another DNS server.
Note: In the DNS Console, it is not possible to create DNS zones for subdomains! Here subdomains can only be defined as described in the section "Subdomain".
For example, a subdomain for the technology department of a large company needs to be set up for short-term internal tests. The DNS records of the subdomain need to be independent of the entries for the domain "grossefirma.de" (hosted at a large and possibly inflexible provider).
In the zone file of the domain
grossefirma.de, add the following entries:
technik IN NS ns.technik ns.technik IN A 220.127.116.11
For example, this lets name server queries for
www.technik.grossefirma.de be passed on to
ns.technik.grossefirma.de. Since this host name should be resolved even by this same name server in the parent domain, you should enter a glue record:
ns.technik.grossefirma.de -> 18.104.22.168.
On the new name server, you need to create a zone file for the new subdomain:
@ IN SOA hydrogen.ns.hetzner.com. dns.hetzner.com. 2020042701 86400 10800 3600000 3600 @ IN NS ns.technik ns IN A 22.214.171.124 @ IN MX 10 mail mail IN A 126.96.36.199 www IN A 188.8.131.52
The administrator has the email address
- The primary name server has the hostname
- It is the only name server (there are no secondary name servers).
- It has the IP address
- A host
mail.technik.grossefirma.dewith the IP address of
184.108.40.206exists and is also responsible for receiving the subdomain's mail.
- There is another host named
www.technik.grossefirma.dewhich resolves to