Created
June 23, 2015 13:44
-
-
Save googl/a8c3184b4c1888492955 to your computer and use it in GitHub Desktop.
powershell disk image idea
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Step 1 - Create the VHD | |
diskpart Create vdisk file=”c:\test\test.vhd” maximum=1000 | |
select vdisk file="c:\test\test.vhd" | |
attach vdisk | |
create partition primary | |
assign letter=X noerr | |
exit | |
Step 2 - Copy the files into your new vhd | |
Robocopy <Source> <Destination> *.* /S /MT:128 | |
Step 3 - Detach the vhd | |
select vdisk file="c:\test\test.vhd" | |
detach vdisk | |
exit | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment