Skip to main content

Google Cloud Compute Engine Concepts

Overview​

The following are the key Google Cloud Compute Engine concepts that every Cloud Engineer, DevOps Engineer, SRE, and Cloud Architect should understand.


1. Virtual Machine (VM) Creation

Topics to Learn​

  • Creating VM instances from the Google Cloud Console
  • Creating VMs using Google Cloud CLI (gcloud)
  • Creating VMs using Infrastructure as Code (Terraform)
  • Selecting machine types and series
  • Choosing operating systems and images
  • Configuring networking and firewall rules
  • Attaching storage volumes
  • Configuring service accounts and IAM permissions
  • Startup and shutdown scripts
  • VM labels and tags

2. Connecting to Virtual Machines

Multiple Methods to Connect​

Browser-Based Access​

  • SSH through Google Cloud Console
  • Browser SSH terminal

Command Line Access​

  • Google Cloud SDK (gcloud compute ssh)
  • Cloud Shell

Authentication Methods​

  • SSH key-based authentication
  • OS Login
  • IAM-based access control

Network-Based Access​

  • Public IP access
  • Private IP access
  • Bastion Host (Jump Server)
  • Identity-Aware Proxy (IAP)

3. Instance Templates

Why Instance Templates Are Needed​

Instance Templates provide a reusable configuration for creating virtual machines consistently.

What Instance Templates Contain​

  • Machine type
  • Boot disk configuration
  • Operating system image
  • Startup scripts
  • Network configuration
  • Service accounts
  • Labels and tags
  • Metadata
  • Shielded VM settings

Use Cases​

  • Managed Instance Groups (MIGs)
  • Auto Scaling
  • Standardized VM deployments

4. Machine Images

Purpose​

Machine Images capture the complete state of a virtual machine.

Components Included​

  • Boot disk
  • Attached disks
  • Instance properties
  • Metadata
  • Network configuration

Use Cases​

  • Backup and recovery
  • Disaster recovery
  • Environment cloning
  • Migration between projects

5. Instance Groups

Purpose​

Instance Groups allow multiple VM instances to be managed as a single unit.


Managed Instance Groups (MIG)​

Features​

  • Auto-healing
  • Auto-scaling
  • Load balancing integration
  • Rolling updates
  • High availability

Use Cases​

  • Web applications
  • API services
  • Microservices workloads

Unmanaged Instance Groups​

Features​

  • Manual VM management
  • No auto-healing
  • No auto-scaling

Use Cases​

  • Legacy applications
  • Custom workloads
  • Applications requiring unique VM configurations

6. Persistent Disks and Volumes

Disk Types​

Standard Persistent Disk​

  • Cost-effective
  • Suitable for general workloads

Balanced Persistent Disk​

  • Balanced performance and cost

SSD Persistent Disk​

  • High-performance workloads

Extreme Persistent Disk​

  • Mission-critical applications
  • Very high IOPS requirements

Operations​

  • Create disks
  • Attach and detach disks
  • Resize disks
  • Snapshot disks
  • Restore from snapshots

7. Network File Storage (NFS)

Google Cloud Filestore​

Managed NFS service provided by Google Cloud.

Features​

  • Shared file storage
  • NFS protocol support
  • High availability
  • Managed service

Use Cases​

  • Shared application data
  • Kubernetes persistent storage
  • Content management systems
  • Enterprise applications

8. Metadata

Purpose​

Metadata allows configuration and customization of VM instances.

Types​

Project Metadata​

Applied to all VM instances in a project.

Instance Metadata​

Applied to a specific VM instance.

Common Use Cases​

  • Startup scripts
  • Shutdown scripts
  • Configuration management
  • Application settings
  • Environment variables

9. Snapshots

Purpose​

Snapshots provide point-in-time backups of Persistent Disks.

Topics to Learn​

  • Creating snapshots
  • Scheduled snapshots
  • Snapshot restoration
  • Cross-region recovery
  • Backup strategies

10. Custom Images

Purpose​

Custom Images enable standardized VM deployments.

Use Cases​

  • Golden Images
  • Pre-installed software
  • Enterprise standards
  • Faster provisioning

11. Service Accounts

Purpose​

Provide secure access from VMs to Google Cloud services.

Topics to Learn​

  • Creating Service Accounts
  • IAM Roles
  • Least Privilege Principle
  • Service Account Scopes
  • Workload Identity

12. Availability and Resiliency

Topics​

  • Regions and Zones
  • High Availability Design
  • Multi-Zone Deployment
  • Disaster Recovery
  • Auto-Healing
  • Load Balancing

13. Startup and Shutdown Scripts

Use Cases​

  • Application installation
  • Server configuration
  • Package updates
  • Automated deployments

14. Shielded VM

Security Features​

  • Secure Boot
  • Virtual Trusted Platform Module (vTPM)
  • Integrity Monitoring

15. Sole-Tenant Nodes

Purpose​

Dedicated physical servers for compliance and licensing requirements.

Use Cases​

  • Regulatory compliance
  • BYOL (Bring Your Own License)
  • Isolation requirements

16. Compute Engine Best Practices

  • Use Instance Templates for standardization.
  • Use Managed Instance Groups for production workloads.
  • Follow least-privilege IAM principles.
  • Use snapshots and machine images for backup strategies.
  • Enable monitoring and alerting.
  • Use startup scripts for automation.
  • Prefer private IP communication where possible.
  • Implement auto-scaling for scalable applications.
  • Use labels and tags for resource organization.
  • Follow cost optimization practices.

Learning Outcome

After completing these topics, you should be able to:

  • Design and deploy Compute Engine environments.
  • Configure secure VM access methods.
  • Implement high availability and auto-scaling.
  • Manage storage and shared file systems.
  • Create reusable VM deployment patterns.
  • Implement backup and disaster recovery strategies.
  • Apply security and governance best practices.