網頁

2011年4月2日 星期六

Extend booted VHD space

Recently, I want to install windows 7 service pack 1 on my virtual environment with VHD file. When I do "windows update" function on windows 7 platform, it tell me that "Installation error!".

At first, I think the Cloud tool influence the install procedure. Because I ever happen the same problem on another machine due to this tool running. Then I can install windows 7 service pack 1 after it is disabled service. Due to the previous experiment, I think follow this procedure to resolve the problem. But the result still fail!

After checking log message, I find out the key point is "no enough space". This is a big joke for me to forget checking system log! So do that let me spend more time to search what happen.


The root cause has been found. Next step? Of course, extend VHD space. How to do it?

I search the method by Google and find out one tool can help me."VHD tool"
At first, I download it from this URL http://archive.msdn.microsoft.com/vhdtool/Release/ProjectReleases.aspx?ReleaseId=5344 next to install it on windows 7.
The command prompt run as administrator is executed and do the following command to extend VHD size next to boot it from VHD file.

Command -- VhdTool.exe /extend [/quiet]
WARNING – this function is admin only and bypasses file system security. The resulting VHD file will contain data which currently exists on the physical disk.
To extend an existing fixed format VHD to a larger size(from 25GB to 35GB).
Command -- VhdTool.exe /extend xxx.vhd 37580963840

To attach VHD file by Disk Management console

To open Partition Wizard tool, you will see unallocated partition 10GB.

To click move/resize button and move mouse to the rightest plane for extending partition.


So do that you will see the VHD file is extended space to 35GB by disk management console or file explorer.

Now I have disk space to install windows 7 service pack 1.
Since 2010 Design by Davidwa
©Copyright Davidwa Inc. All rights reserved.