As the transition from local hosting to cloud-based applications continues, getting cloud migration right is hugely important. While I’ve never migrated any large infrastructure projects to AWS, I have moved a few small WordPress sites. Those experiences were enough to teach me about the kinds of mistakes that are just waiting to happen. Fortunately for me, small sites = small mistakes and, consequently, smaller losses.

Let’s see what useful lessons we can draw from my cloud migration of a WordPress site with less than 1000 subscribers.

Is cloud migration always the right answer?

It’s easy to get caught up in the hype. Don’t get me wrong: the cloud is awesome and it’s definitely the place to build dynamic, large scale infrastructures. But that doesn’t mean that every website or application needs to be there. Here are some serious questions you need to ask yourself before you head down this path.

Will this cloud migration save me money?

Will this cloud migration improve performance?

Will the improved performance offset any extra costs?

Will downtime during the transition be sustainable?

Do I have the technological know-how to successfully complete the job?

Do I have a fallback strategy if the migration fails?

The above list is by no means exhaustive and represents just some of the things you should be thinking about.

As an example, I have a number of small websites hosted with a very cheap service provider. These sites are quietly doing everything they’re supposed to with no problems at all. No subscriber has ever complained about access speeds. So as far as I am concerned I should just leave them there indefinitely.

But every now and again there’s this small voice in the back of my head asking me “Why don’t you move those sites to AWS?” The above checklist makes it clear that there’s no sound logical or financial reason for me to do so.

Cloud migration as a free lunch?

The best thing about Amazon Web Services “Free Tier” is that it’s free. If you are new to AWS I definitely recommend taking full advantage of the offer: it’s a great way to get your feet wet playing around with EC2 instances and other fun stuff. However, it’s not the place to start building the next Facebook or Netflix.

Sure you can run a micro instance of a Linux or Windows Server machine on the free tier for up to 750 hours per month. Go ahead and stop it, restart it, terminate it…reboot a hundred times with no cost. It’s a great place to learn your way around.

When I first came to AWS and got my free tier I was so excited that I moved a perfectly functional WordPress site onto an EC2 instance. The performance was atrocious and I ended up moving it back off the cloud quick smart…but not without a lot of wasted time and effort.

What went wrong?

It turns out that the t2.micro instance type (the one available under the free tier) just didn’t have enough power to keep my customers happy. But moving up just one level to t2.small made all the difference. My second cloud migration attempt turned out to be a smashing success! That is until I got my first monthly bill: a crippling $44!

Ok. So it wasn’t exactly crippling, but it did get my attention.

If you are going to migrate a small site, then you’ll need to understand that EC2 instances can be purchased in different ways:

On-Demand Instances allow you to pay a fixed rate by the hour with no commitment.

allow you to pay a fixed rate by the hour with no commitment. Reserved Instances provide you with long-term capacity reservations and offer a significant discount on the hourly charge for an instance.

provide you with long-term capacity reservations and offer a significant discount on the hourly charge for an instance. Spot Instances enable you to bid whatever price you want for instance capacity, providing for even greater savings if your applications have flexible start and end times.

So I switched to a reserved instance with a twelve-month commitment. My site is now running on a t2.small reserved instance and is costing me about $6 a month instead of $44. And everyone’s happy.

The thing I learned from all this is to carefully research all of my options. If like me, you’re planning a cloud migration for your small site and need it to be available 24/7 for twelve months or more, then you definitely should use a Reserved Instance. But whatever you need, research and plan!

Sometimes the best course of action is to take no action at all.