Posts Tagged ‘DNS’
Mastering DNS Configuration: A, AAAA, CNAME, and Best Practices with OVH
I am currently reorganizing a website of mine, hosted at OVHcloud, and it is worth reminding some concepts and best practices related to DNS.
(disclaimer: I am not part of OVH at all, I express myself as a mere customer)
DNS (Domain Name System) is the backbone of the internet, translating human-friendly domain names into IP addresses that computers understand. Yet, many website owners and IT professionals struggle with its configuration. Let’s break down the essential DNS records—A, AAAA, and CNAME—and illustrate best practices using OVH’s interface.
Key DNS Records Explained
1️⃣ A Record (Address Record)
- Maps a domain (e.g.,
example.com
) to an IPv4 address (e.g.,192.168.1.1
). - Best practice: Ensure you update this if your server IP changes.
2️⃣ AAAA Record (IPv6 Address Record)
- Similar to A records but maps to an IPv6 address (e.g.,
2001:db8::1
). - Best practice: If your hosting provider supports IPv6, use this alongside A records for better future-proofing.
3️⃣ CNAME Record (Canonical Name Record)
- Points a domain (e.g.,
blog.example.com
) to another domain (example.wordpress.com
). - Best practice: Use CNAME for aliases but avoid pointing the root domain (
example.com
) to another domain using CNAME—stick to A/AAAA records.
Configuring DNS Records in OVH
To set up a subdomain (blog.example.com
) on OVH:
- Log in to your OVH Control Panel.
- Navigate to Web Cloud → Domains, then select your domain.
- Go to the DNS Zone tab and click Add an entry.
- Choose A Record if your blog has a dedicated IPv4, or CNAME if pointing to another domain.
- Enter your subdomain (
blog
) and the corresponding IP or domain. - Save changes and wait for propagation (~24 hours max).
Best Practices for DNS Management
- Use TTL (Time-To-Live) wisely: Lower values (e.g.,
300s
) allow faster updates but increase queries to your DNS provider. - Keep DNS records minimal: Avoid unnecessary CNAME chains to improve resolution speed.
- Secure with DNSSEC: If your registrar supports it, enable DNSSEC to prevent DNS spoofing.
- Regularly review DNS settings: Especially after migrations, new SSL configurations, or changes in hosting.