Warm Disaster Recovery for Applications on Google Cloud

Get Cooking in Cloud

Priyanka Vergadia
Google Cloud - Community
4 min readDec 19, 2019

--

Introduction

Get Cooking in Cloud is a blog and video series to help enterprises and developers build business solutions on Google Cloud. In this second miniseries I am covering Disaster Recovery on Google Cloud. Disasters can be pretty hard to deal with when you have an online presence. In the next few blogs, we will elaborate on how to deal with disasters like earthquakes, power outages, floods, fires etc.

Here is the plan for the series.

  1. Disaster Recovery Overview
  2. Cold Disaster recovery on Google Cloud for on-premise applications
  3. Warm Disaster recovery on Google Cloud for on-premise applications
  4. Hot Disaster recovery on Google Cloud for on-premise applications
  5. Cold Disaster recovery for applications in Google Cloud
  6. Warm Disaster recovery for applications in Google Cloud (This article)
  7. Hot Disaster recovery for applications in Google Cloud
  8. Disaster recovery on Google Cloud for Data: Part 1
  9. Disaster recovery on Google Cloud for Data: Part 2

In this article, you will learn to set up a Warm DR pattern for your applications that are deployed on Google Cloud. So, read on!

What you’ll learn

  • Warm DR pattern for Google Cloud applications, with an example
  • Steps to be taken before a disaster hits
  • Steps to be taken during a disaster
  • Steps to be taken after a disaster

Prerequisites

  • Basic concepts and constructs of Google Cloud so you can recognize the names of the products.
  • Read the overview article for DR related definitions.

Check out the video

Let’s learn Warm DR pattern with an example

Mane-street-art currently runs their web application on Compute engine. It’s mostly a static website so in the unlikely event that their site is not available they can use a failover to a static website on Google Cloud storage.

Mane-Street-art is very cost conscious so they have gone for a zonal set up which will cause them problems if the zone becomes temporarily unavailable, so, this recipe provides them with a cost efficient way to recover.

Mane-street-Art’s current architecture

Their primary application runs on Compute Engine instances. These instances are grouped into managed instance groups, and the instance groups serve as backend services for an HTTPs load balancer. The HTTP load balancer directs incoming traffic to the instances according to the load balancer configuration, the configuration of each instance groups, and the health of each instance. This provides HA but for belts and braces approach this recipe is worth discussing.

Note: If you are unfamiliar with the terms used here (RTO, RPO, DR Patterns) checkout the previous blog to get an overview.

In any DR pattern you need to understand what steps need to be taken before a disaster hits, what happens when a disaster hits and what needs to happen after the disaster has passed.

Warm DR Pattern — How does it work?

Steps to be taken before disaster hits

Warm DR Pattern: Steps to be taken before disaster hits
  • They would have to Create a VPC network
  • Create a custom image that’s configured with the application service.
  • Use that image to create an instance template.
Warm DR Pattern
  • Using this instance template, configure a managed instance group with health checks and load balancing
  • Create a cloud storage based static website. Check out the prior articles in this series to cook it up!
  • Then finally configure the Cloud DNS to point at the primary application, and the standby static site sits dormant.

Steps to be taken when disaster hits:

When a disaster hits, all Mane-street-art have to do is to configure Cloud DNS to point to this static site.

Warm DR Pattern: Steps to be taken before disaster hits

Steps to be taken after the disaster has passed

When the production Compute Engine is back up and running again and can support production workloads, Mane-street-art can reverse the recovery step: they will just have to configure cloud DNS to point to the load balancer that fronts the instances.

Warm DR Pattern: Steps to be taken before disaster hits

Conclusion

If your web application already runs on Google Cloud and you are on a specific budget to meet those RTO and RPO values, then you can use the Warm DR pattern and failover to a static website on Google Cloud Storage! Stay tuned for upcoming articles, where you will learn to set up more DR patterns that makes sense for your business.

Next steps

--

--

Priyanka Vergadia
Google Cloud - Community

Developer Advocate @Google, Artist & Traveler! Twitter @pvergadia