📝 Creating Your First VM Instance in GCP – Step-by-Step Guide

Gcp Kajal November 29, 2025 3 mins read

Learn how to create and configure your first Virtual Machine in Google Cloud Platform using this simple and beginner-friendly tutorial.

1. Introduction

Virtual Machines (VMs) are one of the core services of cloud computing. In Google Cloud Platform (GCP), VMs are created and managed using Compute Engine, which allows you to deploy workloads on Google’s fast, secure infrastructure.

This tutorial provides a hands-on, step-by-step guide to creating your first VM instance, even if you’re new to GCP.


2. Prerequisites

Before you begin, ensure you have:

✔️ A Google Cloud Platform account
✔️ Billing enabled
✔️ Access to the Google Cloud Console
✔️ Basic knowledge of projects, regions, and zones


3. Steps to Create a VM Instance


Step 1: Navigate to Compute Engine

  1. Log in to the Google Cloud Console

  2. From the left navigation menu, open:
    Compute Engine → VM Instances


Step 2: Click “Create Instance”

  • Press the Create Instance button

  • Enter a name for your VM (example: my-first-vm)


Step 3: Choose Region and Zone

  • Select your desired Region (e.g., us-central1)

  • Pick a Zone (e.g., us-central1-a)

Tip: Select a region close to your location for lower latency.


Step 4: Select Machine Type

Choose a machine configuration:

  • e2-micro → Free-tier eligible

  • Standard and high-performance types available

Adjust CPU and Memory based on your workload.


Step 5: Configure Boot Disk

  1. Click Change under Boot Disk

  2. Choose an OS image:

    • Ubuntu

    • Debian

    • CentOS

    • Windows Server

  3. Configure:

    • Disk type (Standard, Balanced, SSD)

    • Disk size (default: 10GB)


Step 6: Networking & Firewall

Expand Networking → Firewall:

✔️ Allow HTTP traffic
✔️ Allow HTTPS traffic (optional but recommended)


Step 7: Create the VM

  • Click Create

  • Wait for provisioning — the VM will appear in the instance list

Your first Compute Engine VM is now ready!


4. Connecting to Your VM

Option 1: Browser-Based SSH

Click SSH next to your VM in the console — a terminal opens directly in the browser.

Option 2: gcloud CLI

 
gcloud compute ssh my-first-vm --zone=us-central1-a

5. Validation Tests

After connecting, verify your VM:

✔️ Check OS

 
uname -a

✔️ Check disk space

 
df -h

✔️ Test internet connectivity

 
ping google.com

6. Troubleshooting

❗ Quota Exceeded

Go to IAM & Admin → Quotas and request more CPUs.

❗ SSH Not Working

Ensure firewall rule allows TCP port 22.

❗ Performance Issues

  • Resize VM to a larger machine type

  • Switch to SSD boot disk


7. Cleanup

To avoid charges, stop or delete unused VMs.

Stop VM

In the console → Click Stop

Delete VM

 
gcloud compute instances delete my-first-vm --zone=us-central1-a

8. Visual Guide (Recommended Images)

Here are ideal visuals to include:

📸 GCP Console VM Creation Form
🔁 VM lifecycle diagram: create → connect → validate → cleanup
📊 Machine type comparison infographic (micro vs small vs medium)

I can generate these graphics with RSH Network branding—just tell me.


9. Conclusion

Congratulations! 🎉
You’ve successfully created your first VM instance in Google Cloud Platform. This is the essential first step toward deploying applications, hosting services, or exploring advanced cloud features like networking and automation.

Next in this series:
Setting up VPC networks, firewalls, and subnets in GCP.

Advertisement

K
Kajal

7 posts published

Sign in to subscribe to blog updates