These are usually referred to as alias records since they usually map an alias to its canonical name. The name server does handle these queries differently from an A record. When a name server looks up a name and finds a CNAME record, it replaces the name with the canonical name and looks up the new name. This allows you to point multiple systems to one IP without specifically assigning an A record to each hostname. If your IP was ever to change you would only have to change one A record.
1. Navigate to Managed DNS
2. Select your Domain
3. Click the Plus Button
Under “CNAME Records” click the plus sign to add a new record.
4. Enter CNAME values
We will add a CNAME record to the domain example.io for www.example.com which maps to the root record of the domain name. To alias to the root record of the domain name, you leave the data value blank. Finally, click Submit.
Systems that have a static IP should usually have a TTL of 1800 or higher. Systems that have a dynamic IP should usually have a TTL of 1800 or less.
The lower the TTL the more often a client will need to query the name servers for your host’s (record’s) IP address this will result in higher query traffic for your domain name. Whereas a very high TTL can cause downtime when you need to switch your IPs quickly.
You can also create an alias for one hostname to the hostname of an A record. Here we create the CNAME record smtp.example.com and alias it to the A record mail.example.com.
Finally, you can create an alias for a hostname to another external domain. Here we create an alias for search.example.com to google.com.
CNAME to record within the same domain
Name | TTL | Type | Data |
www.example.com. | 1800 | A | 192.168.1.2 |
ftp.example.com. | 1800 | CNAME | www.example.com |
Configuration:
A record: For the A record configuration explanation please read more on the A-Data Entry page.
CNAME to record the apex/root record in the same domain
Name | TTL | Type | Data |
example.com. | 1800 | A | 192.168.1.2 |
www.example.com. | 1800 | CNAME | example.com |
Configuration:
A record: For the A record configuration explanation please read more on the A-Data Entry page.
CNAME to record to a different domain
Name | TTL | Type | Data |
www.example.com. | 1800 | CNAME | www.example100.com. |
Configuration:
A record: For the A record configuration explanation please read more on the A-Data Entry page.