EC2: is an instance's public DNS stable? Can I rely on it not changing?

Posted by Aseem Kishore on Server Fault See other posts from Server Fault or by Aseem Kishore
Published on 2011-11-10T02:47:20Z Indexed on 2012/09/11 9:41 UTC
Read the original article Hit count: 272

Filed under:
|

I'm new to Amazon EC2. I've launched my first instance, and am using it as a web server. I see that it has a public DNS (a public URL), e.g.:

ec2-123-45-6-789.compute-1.amazonaws.com

I can successfully go to this server in my browser, hit it via cURL, etc.

I want to use this web server for a back-end service in an app I'm building, so I placed this URL in my app's config, and it works great.

But when I manually stop and re-started my instance, I see that the public DNS changes! I've read that this happens when you explicitly stop and re-start, but doesn't happen if you just "reboot".

I don't plan on explicitly stopping and re-starting this server ever, but my question is: will this public DNS ever change on its own for any reason? E.g. if the machine abnormally crashes, or whatever.

In other words, is it safe to ship an app that's wired to this URL?

Thanks!

© Server Fault or respective owner

Related posts about dns

Related posts about amazon-ec2