How To Automatically Extend The Storage Volume For Windows Operating System?

Updated on: December 4, 2023

Estimated reading time: 2 minutes

Summary: This article explains a simple step-by-step process to extend the storage volume of Windows OS in a few simple clicks.

To automate resize the storage/disk volume of the Windows virtual machine on 1st-time startup of the virtual machine in VMware after VM creation. Follow the given below steps to add the script for auto disk resize.


WGS VMware WHMCS Module


After creating the virtual machine and before converting it to a VM template, add the given below scripts to your VMware template.

  • Create a file – extend.ps1 and paste the below script into it and move the file into C drive.
  • $drive_letter = “C”
  • Resize-Partition -DriveLetter C -Size $(Get-PartitionSupportedSize -DriveLetter C).SizeMax

After that execute the below script from windows terminal

  • schtasks /create /tn “FileMonitor” /sc onstart /delay 0000:30 /rl highest /ru system /tr “powershell.exe -file C:\extend.ps1”

After adding the above script, shutdown the VM and convert in VM template.

Note:- You can make your own script and you can change the script location path to anything.

Following these steps will not just increase the storage space of your computer but also enhance the speed of your system. This will make you capable enough to perform high memory consumption operations and you will be able to run heavy applications of your system.

So this is how you can extend the storage space of your Windows OS even without having so much of technical skills.

Related Articles:

Looking for Something More? We can help!

Our WHMCS experts are ready to accept your custom requirements.

Custom Development

Need a Custom Solution?

Looking for an integration or billing automation? Our team builds bespoke solutions designed around your stack and business requirements.

Discuss your requirement
Support & Maintenance

WHMCS Support & Maintenance Plans

Keep your billing platform secure, updated, and running smoothly with ongoing support from experienced WHMCS specialists.

  • ✓ WHMCS upgrades and security patching
  • ✓ Module and theme compatibility fixes
  • ✓ Priority support from WHMCS experts
See maintenance plans
Complete Setup

Starting a Web Hosting Business?

We help you set up your complete hosting platform, including WHMCS, client area, payments, order forms, and server automation.

01 WHMCS installation, licensing and setup
02 Hosting theme, client area and order forms
03 Payment gateways, tax rules and checkout
04 Server provisioning and automation
Request a setup quote
Need advice? Our WHMCS specialists are at your service 24/7. Reach out now