VM Migration: Modernize an Application Stack with GKE and MySQL




Create a cluster with specified machine type for the nodes.

Exporting the MySQL contents to the cloud storage bucket.

Replicating to Cloud SQL

Create a firewall rule.

Configuring service account for Cloud SQL proxy

VM Migration: Modernize an Application Stack with GKE and MySQL

1 hour 7 Credits


Google Cloud Self-Paced Labs


Google Cloud’s four step structured Cloud Migration Path Methodology provides a defined, repeatable migration path for users to follow:


  1. Assess the current environment to gain a solid understanding of existing resources and define migration move groups.

  2. Plan how to move your apps and create the basic cloud infrastructure for your workloads to live. This planning includes identity management, organization and project structure, networking, sorting your apps and developing a prioritized migration strategy.

  3. Deploy the existing on-premise or cloud based servers in Google Cloud leveraging one of Google Cloud’s recommended migration tools like Google’s Velostrata or CloudEndure’s Live Migration Tool

  4. Optimize your newly migrated workloads to realize the true cost benefits and operational efficiencies that Google Cloud can bring to the enterprise

In this lab, you will focus on the "Optimize" phase and complete the migration and transformation of an environment by modernizing it and making it a cloud native workload.

You will optimize your web application to run on Google Kubernetes Engine (GKE) as well as optimize your MySQL instance to run on Cloud SQL, a Google-managed relational database service which supports both MySQL and PostgreSQL.

What you'll do

In this lab, you will learn how to:

  • Review a working two-tier application consisting of an application and database server.
  • Deploy a Kubernetes Engine Cluster.
  • Create a new Cloud SQL MySQL instance replica, using the MySQL database instance as external master.
  • Create a Kubernetes deployment of the web application as well as deploy the Cloud SQL proxy.
  • Test the new environment.
  • Shut down the source environment and promote the new environment.
  • Verify the new environment.


  • Basic familiarity with on-premise and cloud migrations.
  • Basic familiarity with Kubernetes.

Join Qwiklabs to read the rest of this lab...and more!

  • Get temporary access to the Google Cloud Console.
  • Over 200 labs from beginner to advanced levels.
  • Bite-sized so you can learn at your own pace.
Join to Start This Lab