0

Let's say I have a micro-instance and i reboot it 100 times a day,

Would that give me a new external ip address each time? and is there a limit to the number of times i can be assigned an IP Address/reboot?

Alex Z
  • 1,827
  • 1
  • 29
  • 26
aws_man
  • 19
  • 1
  • Related to: [AMAZON EC2 Micro instances have different IP addresses?](https://stackoverflow.com/questions/32410552/amazon-ec2-micro-instances-have-different-ip-addresses/32412337#32412337) – John Rotenstein Sep 05 '15 at 22:44

1 Answers1

3

A reboot of an Amazon EC2 instance will not change its public IP address. The virtual machine keeps running, only the operating system restarts.

If the instance has an IP address allocated via the Auto-assign Public IP setting, then stopping the instance and then starting it again might allocate a new Public IP address. Note that this will also restart the hourly billing charge.

If the instance has an Elastic IP Address, then the IP address will not change until the Elastic IP Address is specifically removed or assigned to another instance.

John Rotenstein
  • 165,783
  • 13
  • 223
  • 298
  • What would be your method/suggestion to change the Public IP Address of the micro-instance with minimal server downtime – wolfgang Sep 05 '15 at 15:14
  • @wolfgang If you associate an Elastic IP with the instance then the instance loses its auto-assigned public IP. If you then disassociate the Elastic IP then the instance is automatically assigned a new public IP. No guarantee that it will be a different public IP to the earlier one but I'm guessing it will likely be different. Any particular reason that you want a new public IP every 15 minutes? – jarmod Sep 05 '15 at 15:30
  • @jarmod Performance testing – wolfgang Sep 06 '15 at 16:11