Applies to: Windows Server 2019, Windows Server 2022, and Windows Server 2025.
Dynamic Memory adjusts virtual-machine RAM within safe administrator-defined limits.
Prerequisites
- Administrative access and an approved change window.
- A verified backup and documented rollback plan.
- A pilot environment or low-risk target for validation.
Step-by-step procedure
- Confirm the guest operating system supports Dynamic Memory.
- Record current startup RAM and workload peaks.
- Set startup, minimum, and maximum values while the VM is off when required.
- Monitor memory pressure after startup.
Commands
Set-VMMemory -VMName "APP01" -DynamicMemoryEnabled $true -StartupBytes 4GB -MinimumBytes 2GB -MaximumBytes 12GB
Get-VMMemory -VMName "APP01"Verification
The guest remains responsive and Hyper-V reports acceptable assigned memory and pressure.
Rollback
Disable Dynamic Memory and restore the recorded fixed startup RAM during a maintenance window.
Security notes
- Use least privilege and record the change.
- Review relevant event logs after implementation.
- Test before production rollout.
Size memory from the guest workload
Dynamic Memory adjusts a guest’s assigned memory within the configured bounds, but it does not remove the application’s memory requirements. Check that the guest operating system and workload support the feature. Some applications or vendor support policies expect fixed memory, so obtain the supported sizing method before changing a production database or appliance.
Startup memory must allow the guest to boot reliably, while minimum and maximum values describe the permitted operating range. The sample values are illustrative. Base the real values on measured startup demand, sustained workload and the host’s total capacity, leaving resources for the management operating system and other VMs.
Schedule the change according to what can be modified on the running VM and host version. Record the original configuration first. Observe guest paging, application latency and host memory pressure over a representative busy period, not only immediately after boot when the server may be idle.
If the guest pages heavily or the host is overcommitted, investigate the capacity model. Raising every VM’s maximum can create competing claims rather than solve a physical shortage. Roll back to the known supported settings if the application behaves poorly, and retain the before-and-after measurements.
Related resources
Canadian Windows VPS and RDS hosting: managed Windows VPS hosting. Refer to Microsoft Windows Server documentation.
Preparing a Windows Server host for Hyper-V
Prepare an authorised Hyper-V host by reviewing hardware or nested support, collecting machine evidence, installing the role, verifying…
Planning an external Hyper-V switch without losing host access
Design a Hyper-V external switch around reliable host access, explicit uplink and VLAN choices, then prove a test guest’s path and preserve…
Provisioning a UEFI-based Hyper-V guest with PowerShell
Provision a supported Generation 2 guest from an agreed specification, configure UEFI and installation media, verify the first boot, and…
Managing Hyper-V production checkpoints through a maintenance change
Use Hyper-V production checkpoints as a controlled maintenance tool, make fallback behaviour explicit, validate guest coordination, and…
Designing and validating recovery with Hyper-V Replica
Build Hyper-V Replica around an application recovery runbook, restricted HTTPS trust, capacity and lag monitoring, then demonstrate an…