Embrace High Availability to Boost your Website’s Access
Successfully hosting content on the internet is all about connecting a receptive audience to that content. Subtract any one element — audience, content or connection — from the equation and your website fails.
Fortunately, even in the craziest online scenarios, you can ensure that your audience will always reach your content. It’s called high availability.
Of course, while 100-percent uptime is the ideal of online presence, the reality is that such a constant can only be approached but never quite achieved. Still, high availability can get your system as close to that ideal as possible.
Three sysadmin concepts, defined here, work in concert to create a highly available system:
- Redundancy — Having multiple versions of a server or component of the server (e.g., database) operational. This also means you need to replicate the server’s data. Without redundancy, when a server goes down, its content is inaccessible, but having a second server that can distribute its own replicated content will ensure anyone can still reach it.
- Failover — Sending website traffic to an accessible server from an offline server. This allows seamless data access and is achieved through software tools such as Pacemaker.
- Monitoring — Determining if and when a server goes down. Monitoring software, like the Heartbeat daemon, will actively check to see if a server is reachable or not.
Redundancy
Storing a local computer’s data backups in a geographically distinct site aids high availability. Placing your redundant servers in a different location than the original will significantly bolster the chance that your content will remain online if original server access somehow becomes impeded. This geographical redundancy is simple, and it’s one of the best practices available for keeping your site online and data accessible.
Once you’ve assessed your system’s high availability needs, figuring how to set up redundancy becomes much easier. Configuration management services such as Salt and Chef can take care of server deployments while Galera and GlusterFS will handle all the data and filesystem replication. You can find Linode’s guide that covers the setup of the replication here.
Failover
Failing over involves more than the actual failover. To begin with, you have to evaluate the infrastructure that’s to be made highly available. Does only a relatively small number of users access these servers? Or is it a large amount? Are all of the hardware components in the same datacenter? What kind of hosting service is provided? Answers to these questions can lead to different failover methods that contribute to high availability.
Monitoring
With redundancy and failover set up, you’ll need an alert to tell you when your system has failed over to one of your redundant servers. This is where monitoring shines. Setting these options and their values may be different between monitoring services, but they all do the same job: identifying system components being monitored and sending an alert if a failure threshold is breached. This alert usually initiates failover.
Besides redundancy, failover and monitoring, supplemental practices, like those described below, can help you achieve high availability.
Supplemental Means to High Availability
Most sysadmins prefer installing a load balancer with multiple backends. A load balancer assesses in real time the traffic visiting a website and routes that traffic between multiple backend servers. Load balancing ensures website content is accessible, so long as at least one backend server is reachable.
To maintain highest availability, consider using load balancers within each datacenter where you have a server. These help distribute traffic among servers and maintain level, consistent access. Of course, if you are unsure how to load balance, products can be purchased that will do it for you, such as Linode’s NodeBalancer.
If you’re serving content to multiple users around the world, you’re probably using a content delivery network. A CDN ensures that traffic closest to a server accesses that server. This proximity routing averts many transit and peering issues that occur as a result of long distance connections.
Once you’ve evaluated your system’s infrastructure and measured your traffic’s needs, achieving high availability mostly takes sound planning, technical acumen and coordination, all of which take deliberation and diligence.
Despite its potentially daunting process, the payoff for achieving high availability can be quite substantial. (And it’s no sin to ask for professional help.) A website’s being highly available affords it one of the most powerful advantages over competitors when it comes to having content that’s subject — and vulnerable — to so many external factors.
Redundancy, monitoring, and failover equate to data duplication, active system assessment, and rerouting that keep your website online and accessible. This combination will sustain access to your content and keep your followers happy. And isn’t that why you’ve built a website in the first place?
Embrace high availability. Keep content online. Delight your customers and followers.
Have any stories about how high availability has saved your website’s bacon from the fire? Or want to share how you set up HA on your system? Feel free to leave a comment below or tweet at me, @feelingsohsoh.
If you want help, you can read Linode’s guide on high availability, download its more in-depth .pdf, or contact its Professional Services team, which can perform high availability deployments on your system.