Virtual Switches
Cheat sheet · https://pcornel.dk/topic.php?topic=3338
Answer
An external switch can bridge VM traffic to a physical adapter, an internal switch connects VMs with the management OS, and a private switch limits connectivity to VMs on the same host.
Remember
- Switch type defines reachability scope, not guest IP configuration.
- External switch binding to the wrong physical NIC can look like a guest problem.
- Allowing the management OS to share an external adapter creates a host virtual NIC path that must be considered separately.
- A virtual switch existing does not prove traffic is forwarded on the intended VLAN/path.
First checks
Get-VM— VMs and stateGet-VMHost— host settingsGet-VMSwitch— virtual switchesGet-VMNetworkAdapter -VMName <vm>— vNICs, switch, VLANGet-VMHardDiskDrive -VMName <vm>— attached disksGet-WinEvent -LogName Microsoft-Windows-Hyper-V-VMMS-Admin -MaxEvents 30— VMMS events
Verify in this order
virtual switch → uplink → physical network
Where it usually breaks
First mismatch in host/cluster identity → management configuration → quorum/resource ownership → network/storage dependencies → VM/service runtime → guest/application verification; preserve identity/native error/pre-state before mutation.
Hyper-V → Virtual Switches reference map
| Boundary | Meaning | Evidence limit |
|---|---|---|
| External | Can use physical NIC for external network path | Does not prove upstream switching/routing |
| Internal | VMs plus management OS can communicate | Does not provide external path by itself |
| Private | VM-to-VM on same host scope | Management OS/external access not implied |
| Attachment | vNIC connected to switch | Does not prove packets traverse correctly |
Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=3338