Tuesday, 27 October 2020

Subdomain uses CNAME(alias) or A for DNS entry

 Both will work,

 general rule, uses CNAME if subdomain uses the same IP as domain, for example

myWeb.com    A                     172.168.12.160

www               CNAME             @(subdomain www.myWeb.com is am alias of myWeb.com)


use A record if subdomain points to a different IP than domain, for example :

myWeb.com    A                     172.168.12.160

dev                   A                     172.168.12.165 (dev.myWeb.com subdomian points to a different IP than domain)



https://serverfault.com/questions/275982/what-type-of-dns-record-is-needed-to-make-a-subdomain

No comments:

Post a Comment