I recently deployed a WordPress instance to AWS (Amazon Web Services) LightSail which was expecting a high volume of traffic. The site crashed within 2 hours, even though we provisioned the highest spec VM (Virtual Machine) – 32Gig RAM, 8vCPU & SSD storage.
This is what I learned from the experience
- LightSail does not allow you to continuously use higher than 20% CPU capacity for long periods of time – rather it allows for short spikes in load. So, even if you provision a high spec VM, take the margin into account.
- Use a load balancer for high volume sites – With a load balancer you can add resources on the fly so that, if you see the VM getting into trouble, you can quickly and easily deploy more resources.
- Create your instance at least a couple of days before you go live so that it has time to build up the allowed burst capacity time.
Resources
Follow this 4-part tutorial “Deploying a highly available WordPress site on Amazon Lightsail”, written by a Developer Advocate for Lightsail, Mike Coleman.
“This post walks you through what to consider when architecting a scalable, redundant WordPress site. It discusses how WordPress stores such elements as user accounts, posts, settings, media, and themes, and how to configure WordPress to work with a standalone database.
This walkthrough deploys a WordPress site on Amazon Lightsail. Lightsail is the easiest way to get started on AWS, and it might be the easiest (and least expensive) way to get started on WordPress. You can launch a new WordPress site in a few clicks with one of Lightsail’s blueprints, for a few dollars a month. This gives you a single Lightsail instance to host your WordPress site that’s perfect for a small personal blog.”