How to Put Two Virtual Machines in the Same Network in ESXi


This guide covers two VMs in the same network step by step, with every setting in the order you will use it. Most lab exercises need at least two machines talking to each other: a domain controller and a member server, a web server and a client, a DNS server and its resolver. This guide shows how to put two VMs on the same virtual network in ESXi and prove they can communicate.

two VMs in the same network in a home lab

WINDOWS SERVERTWO VMS IN THE SAME NETWOR…ENTERPRISE LABtimer 45 MIN LAB
NH
Nurul Huda AUTHORInfrastructure & Cloud Architect · Verified 2026

print Print Lab

● VALID ON THE CONFIG BELOW

dns LAB TOPOLOGY & PREREQUISITES

# example values used while writing and testing this guide

LAB VM

HypervisorESXi / Workstation
vCPU2
RAM4-8 GB
Disk60 GB thin

WINDOWS BUILD

EditionServer 2019 Std
InterfaceDesktop Experience
Adminlocal Administrator
IPstatic or DHCP

VALIDATION

RolesServer Manager
Firewalllab rules only
Snapshotbefore changes

01constructionStep 1: Create Both VMs

Create the two virtual machines (any guest OS works) and make sure they are powered off for the next step.

02downloadStep 2: Assign the Same Port Group

Both VMs must be connected to the same port group — that is what “same network” means on a vSwitch. Edit each VM’s settings and set the network adapter to the same label, for example VM Network. If you want the pair isolated from everything else, create a dedicated port group first as covered in managing virtual networks.

03usbStep 3: Configure Matching IP Settings

Give both machines addresses from the same subnet:

  • Static: for example 192.168.100.11/24 and 192.168.100.12/24 — no gateway needed for local-only talk
  • DHCP: if the network has a DHCP server (physical router or one you configure yourself with the Windows Server DHCP guide), just renew and note the leases

04terminalStep 4: Test Connectivity

From VM one, ping VM two’s address. If it fails, walk this checklist:

  1. Both adapters on the same port group (check the VM Summary tabs)
  2. Same subnet mask on both sides
  3. Guest firewall: Windows blocks ping by default — enable the File and Printer Sharing (Echo Request) rule or test the other direction
  4. Uplink status if the port group needs external reachability

Once two machines talk, you can practice isolating them, moving them to another network, or building services like DNS and DHCP on top.

Related Content

▶ UP NEXT IN THE WINDOWS TRACK

How to Connect a VM to the Data Network in ESXi Server

Finish this lab, then continue down the track. Each guide builds on the one before it.

rocket_launch Launch Next Lab