Use this when reading VM memory metrics and deciding whether the VM or the host is the problem.
Memory Usage
Monitor VM memory with guest-visible usage and host-side metrics: active memory, ballooning, compression and swap-in. Ballooning or host swap shows host pressure; high guest usage with paging shows the VM is undersized.
1. Memory usage: assigned, active, consumed, host free.
2. Guest cache inflates "used".
3. Watch ballooning and swap.
4. Alert on host available memory.
5. Plan N+1.
guest demand → host memory
Context & applicabilityCommon mistakes · platform/version boundaries
- Alerting on guest "used" memory that is mostly cache.
- Ignoring host-level ballooning and swapping.
- Not tracking memory trends for capacity planning.
Operational reference
Fast context before you go deeper.
esxtop → mVerification & Troubleshooting
Start with the observed symptom, prove the nearest boundary, and move outward only when the current state is understood.
Use the operational verification above to establish the expected state.
Capture the concrete output, symptom, packet, log or counter before changing anything.
Step 1 Checks Verify boundary
esxtop → m
virsh dommemstat vm01
Get-VM | Select Name,MemoryAssigned,MemoryDemand,MemoryStatus
On Hyper-V, MemoryStatus = Warning/Low means Dynamic Memory cannot meet demand.
Evidence · 1 on this Topic
Expected observations and documentation recipes are reference material. Record actual output, device identity, scope and time before claiming a verified result.
- Active memory is what the guest recently touched; consumed is what the host allocated.
- Ballooning and swap-in show host pressure.
- Paging inside the guest shows the VM itself is too small.
virsh dommemstat <vm>— VM memoryGet-VM | ft Name,MemoryAssigned,MemoryDemand— Hyper-Vfree -h— host
ReferenceWhy it matters1 section · depth on demand
Key metrics
| Metric | Healthy | Problem |
|---|---|---|
| Guest used vs configured | Below ~80 % | Guest paging |
| Active / consumed (host) | Stable | Close to host total |
| Balloon | 0 | Rising: host pressure |
| Swap-in rate | 0 | Any sustained value: severe slowdown |
Alert on host swapping and ballooning, not on guest "used" memory alone, because guests use free RAM as cache.
ReferenceImportant terms & boundaries1 section · depth on demand
In depth
Memory usage counters differ:
| Counter | Meaning |
|---|---|
| Configured / assigned | What the VM was given |
| Consumed / host memory | Host RAM backing it |
| Active | Recently touched (estimate) |
| Guest used / available | Guest OS view incl. cache |
| Balloon / swapped / compressed | Reclaim in progress |
Right-size by guest-side working set plus headroom; use host-side balloon/swap to detect host overcommit. "Consumed" near configured is normal for VMs with large caches and does not mean the VM needs more memory.
ReferenceConfiguration & state1 section · depth on demand
Commands
esxtop → m
free -h ; cat /proc/meminfo | head
Get-Counter '\Hyper-V Dynamic Memory VM(*)\Current Pressure'
Hyper-V Current Pressure above 100 means the VM needs more memory than assigned.
Additional reference context Scope · expected state · examples · history · terminology Open only when you need the supporting context
Verification history & basis
When and against what this Topic was checked. Later text edits do not count as a new check.
Authoritative/upstream documentation reviewed for bounded claims in Monitoring → Memory Usage. Documentation verification only; this is not observed lab or production Evidence.
Basis: https://libvirt.org/html/libvirt-libvirt-domain.html · confidence 94%