Traditionally, the purpose of a DNS server is to translate human-friendly hostnames into IP addresses. More importantly, it allows for the updating of a service's location (IP address) on the network while retaining the same hostname.
In EC2 however, the public DNS hostname is linked to its public IP address. For example, if the IP address of an instance is 1.2.3.4
, its DNS name would be ec2-1-2-3-4.compute-1.amazonaws.com
.
As the DNS name is syntactically linked to its IP, it wouldn't serve as a memorable URL nor allow the IP to change independently of its DNS name.
What could be the reason AWS provides the DNS name? What purpose does the DNS name serve in the context of EC2? What can I accomplish with the public DNS hostname that I can't with the public IPv4 address?