GCP Networking - Part 1 - Virtual Private Cloud(VPC) Introduction

Google Cloud VPC Introduct


2 min read

GCP Virtual Private Cloud (VPC) is a virtual network providing functionality for Compute Engine instances, GKE Clusters, App Engine and different Google Cloud services. GCP VPC provides networking for cloud-based resources and services that is global, scalable, and flexible in GCP Cloud environment.

Regions are collections of zones. A zone is a deployment area within a region. The fully-qualified name for a zone is made up of -. Zones have high-bandwidth, low-latency network connections to other zones in the same region. In order to deploy fault-tolerant applications that have high availability, it is recommended deploying applications across multiple zones and regions. It will protect against unexpected failures of components, up to and including a single zone or region. Depending on how widely the resources has to be distributed, create the instances across multiple zones in multiple regions for redundancy.

In GCP Regions have three or more zones. Resources that live in a zone, such as Compute instances or zonal persistent disks, are referred to as zonal resources. Static external IP addresses, are regional. Regional resources can be used by any resource in that region, regardless of zone, while zonal resources can only be used by other resources in the same zone. Only certain resources are region or zone-specific. Other resources, such as images, are global resources that can be used by any other resources across any location.

To built and design robust systems resources have to be spread across different failure domains and zones. Creating resources in different zones in a region reduces the risk of an infra outage affecting all resources simultaneously. Creating resources in different regions provides an even higher degree of failure independence.

Below are Global resources which are accessible by any resource in any zone within the same project. VPC network, Firewalls, Routes, static external IP addresses, Images, Snapshots, Instance templates, Cloud Interconnects, Cloud Interconnect locations,

Regional resources are accessible by any resources within the same region. Subnets, Regional managed instance groups, Regional persistent disks, Cloud Interconnect attachments.

Resources that are hosted in a zone are called per-zone resources. Zone-specific resources are unique to that zone and are only usable by other resources in the same zone. Instances, Machine types, Zonal managed instance groups, Persistent disks, and Cloud TPUs.

A VPC has to have a CIDR (Classless Interdomain Routing) IP block attached to it. The VPC CIDR defines the IP range that we can use when creating subnets to VPC. CIDR range is VPC specific and can overlap with other VPC’s CIRD range. If there should be VPC-to-VPC inter-connection, VPC CIDR IP ranges have to be unique per VPC.