Search code examples
amazon-web-servicesondemand

How do I migrate an existing on-demand instance to spot instance?


My on-demand instance currently hosts a website, does a few computing, and serves as a light-load php server. To reduce the cost, I'm thinking about migrating it to a spot instance. I haven't found any clue on the web yet. Any pointers are greatly appreciated.


Solution

  • Spot instances and on-demand instances are two separate systems. While on-demand systems are available all of the time, you set a maximum bid for spot instances instead. If there are systems available for that price, they will be launched. However if there is a higher demand in your availability zone, these systems may be terminated without notice. So for hosting a website on AWS, I would not recommend using spot instances. If you want to reduce the price, you can have a look at reserved instances instead.

    That said, you would probably have to stop your on-demand machine and set up a spot instance request for this machine instead.