In linux we can create a filesystem in single file and mount it. Is there any way to create a filesystem in a file in windows and mount the filesystem created in a file?
In Windows 7 you can use diskpart to do this.
Save the command lines to a text file, such as c:\newdisk.txt. This example will create a 500 MB virtual disk and mount it:
 create vdisk file=c:\test.vhd maximum=500 type=fixed
 sel vdisk file=c:\test.vhd
 attach vdisk
Execute the script with diskpart:
 diskpart /s c:\newdisk.txt
You can also format the volume, assign a drive letter, etc with diskpart.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With