For cPanel & WHM 11.40
(Home >> DNS Functions >> Edit DNS Zone)
This feature allows you to edit the records in a domain’s DNS zone file.
You may only edit zone data for one domain at a time.
You should exercise caution when you edit a DNS zone, as improperly configured DNS data prevents visitors from accessing a domain.
Edit a DNS zone
To edit a DNS zone, perform the following steps:
- Click the domain whose zone you wish to edit.
- Click Edit.
WHM displays the Edit DNS Zone screen. At the top, this screen shows the following information about the domain:
- Editing zone — Displays the name of the domain whose zone record(s) you are currently editing.
- cPanel first — Shows the cPanel version and build number installed on your server when you created the zone.
- latest — Shows the most recent cPanel version and build number installed on your server.
- Cpanel:: ZoneFile::VERSION — Shows which zonefile version cPanel is using.
- mtime — The date and time (in Unix time) the zone file was last edited.
- $TTL — The default time to live, in seconds. This specifies how long zone data should be cached (saved in memory) by clients (for example, a visitor’s web browser), if not specified for each record below.
The Edit DNS Zone interface with Zone File Information.
Beneath this information, the Edit DNS Zone interface displays a table of editable text fields containing the DNS entries for the domain.
The column headings are:
- Domain — The name of the domain associated with the entry.
- TTL — The time to live, or length of time that the DNS entry should be cached by the client.
Record type —The type of DNS record.
While the Class field may be editable, changing this field to anything other than “IN” will result in an error.
DNS record types
There are several DNS record types. The following list shows the most common. For more information about DNS record types, read our Zone Record Parameters documentation
- SOA — The start of authority record. This contains authoritative information — that is, information on record with an accredited domain name registrar — about the domain. It includes:NS — A nameserver record. This specifies the hostname that clients will refer to when they look for your domain.
- The authoritative nameserver’s hostname.
- The server administrator’s contact email with a period [.] in place of the @ sign.
- Time information and several settings dictating how clients should store the domain’s DNS data:
- Serial number — This number consists of the year, month, date, and time the record was last edited.
- Refresh — The time interval which should elapse before the client should refresh zone data.
- Retry — The time interval which should elapse before the client should try again after a failed refresh attempt.
- Expire — The time interval after which the record is no longer authoritative.
- Minimum TTL — The minimum time to live, or length of time that any DNS information from this zone should be cached.
- A — An address record. This matches your domain name to an IP address.
- MX — A mail exchange record. This matches your domain name to a list of servers which handle mail for your domain, tagging each with a priority (the highest priority is 0).
- CNAME — A “canonical” name record, which matches your domain name to an alias. This is useful if you are running a server besides Apache, such as an FTP server, on a separate port.
Editable Entries on the Edit DNS Zone interface.
You can add new entries to the DNS record in the empty text fields at the bottom of the interface.
When you have entered the information, click Save.
Empty Text Fields for New Entries on the Edit DNS Zone interface.
How to set a separate IP address for your domain and mailserver
If you change the IP address of your domain's A record, the IP address of your mail server automatically changes as well. This happens because the standard zone template uses a CNAME record to point
- Change the MX record to
$domain.represents your domain. For example,
example.com.would change to
- Change the CNAME for mail into an A record to the IP address of the mail server.
- Click Save.
You must include the trailing period after
To change the zone template so that all new domains will create MX records which assign your mailserver a different IP address, perform the following steps:
- Navigate to the Edit Zone Templates scren in WHM. ( Home >> DNS Functions >> Edit Zone Templates ).
- Click standard.
%domain%. IN MX 0 %domain%.to
%domain%. IN MX 0 mail.%domain%.
mail IN CNAME %domain%.to
mail IN A %IP%.
- Click Save.
Your mailserver's IP address is now different from your domain's main A record.