AI & security research Sydney, Australia
Contact Me LinkedIn Contact
Me

If you're building a cybersecurity homelab on Windows, Hyper-V is the best starting point — it's built into Windows 10/11 Pro, completely free, and runs Linux VMs without slowing down your main machine.

This guide takes you from zero to a fully updated Ubuntu 22.04 LTS desktop inside Hyper-V. No third-party software, no dual-booting, no BIOS changes needed on most modern machines.

Prerequisites

Step 1 — Enable Hyper-V

Open PowerShell as Administrator and run:

Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Hyper-V -All

Restart when prompted. Alternatively go to Control Panel → Programs → Turn Windows features on or off, tick Hyper-V (both Platform and Management Tools), and restart.

Step 2 — Download Ubuntu ISO

Go to ubuntu.com/download/desktop and grab the latest LTS release (22.04 or 24.04). Save it somewhere easy to find — you'll point Hyper-V at it in the next step.

Step 3 — Create the VM in Hyper-V Manager

Open Hyper-V Manager (search it in Start). Click New → Virtual Machine on the right panel and work through the wizard:

  1. Name: Ubuntu-Lab01
  2. Generation: Generation 2 (UEFI — required for Ubuntu 22.04+)
  3. Memory: 4096 MB minimum. Enable Dynamic Memory so Hyper-V manages it automatically
  4. Network: Select Default Switch for NAT internet access through your host
  5. Virtual Hard Disk: Create a new VHD — 25 GB is comfortable
  6. Installation Media: "Install from a bootable image file" → browse to your Ubuntu ISO

Before hitting Start, open the VM's Settings → Security and either disable Secure Boot or change the template to Microsoft UEFI Certificate Authority. Ubuntu will not boot with the default Windows Secure Boot template.

Step 4 — Install Ubuntu

Start the VM. It boots the Ubuntu live environment. Click Install Ubuntu and follow the prompts:

Installation takes 5–10 minutes. The VM restarts automatically when done.

Step 5 — Update Everything

Log in and open a terminal (Ctrl + Alt + T). Run:

sudo apt update && sudo apt upgrade -y

This pulls all pending security patches. Reboot after it finishes.

Step 6 — Install Hyper-V Guest Tools

For automatic screen scaling and clipboard sharing between host and VM:

sudo apt install -y linux-tools-virtual linux-cloud-tools-virtual

Restart the VM. You can now resize the Hyper-V window and the Ubuntu desktop scales with it.

What's Next

You now have a free, clean Ubuntu VM running inside Windows. From here:

Hyper-V Checkpoints are the killer feature for security labs. Take one before every exercise, revert instantly if you break something. VMware charges for snapshots on the Pro tier — Hyper-V gives you unlimited checkpoints for free.

The next lab in this series covers installing Splunk Free inside this VM to start ingesting Windows event logs from your host machine.

← All posts
Contact Me Message me