Tuesday, July 19, 2016

Creating shared folders in Hyper-V

Note: This has only been tested on Windows 10 (Build 14393). Earlier versions may not have the same functionality.

1. Open the new hard disk wizard in Hyper-V

2. Pick VHDX (VHD will work too)

3. Use dynamically expanding.

4. Pick any file name.

5. Set a size (it can be expanded later if needed).

6. Click finish.

7. Find the file, right click it and mount it. You’ll get an error, but this is expected as the drive isn’t formatted yet. (Note: I had issues accessing the file at first, but rebooting fixed it. Not sure if this is a Windows bug or not.)


8. Open Disk Management and you’ll be created with a proper to initialize the drive. Click “OK” to continue.

9. Click ‘New Simple Volume’ to create a new partition.

10. Click next through all the dialogs.





After a few seconds, your drive will appear.

11. Connect to your Windows 10 VM (RemoteFX enabled).

12. When the connect prompt opens, click ‘Show Options`.

13. Click the new ‘Local Resources’ tab that appears.


14. Click ‘More…’.

15. Expand the ‘Drives’ tree and pick the virtual drive we created earlier.


16. Click ‘OK’ and then ‘Connect’.

17. At this point you will see the drive in both your VM and local machine. You can now copy files between them.

Creating a Windows 10 Insider Preview ISO and Hyper-V VM

For those with access to Windows 10 Insider Preview builds, one common complaint is that there’s no official option for ISOs or VMs. However, we can still create our own relatively quickly.

Required tools:


Steps:

1. Open up ESDToolKit_gui.bat (from ESD-Decrypter) and click next.

2. Pick the default WIM option. Feel free to use whatever naming style you prefer.

3. Use the default crypto keys.

4. Pick any path where you want to save the ISO. I'll put it in my 'Documents' folder.

5. On the next page, use ‘C:\$WINDOWS.~BT\Sources\Install.esd’ as your ESD file.

6. Click next through the next three pages (the default options are fine).

7. At this point, you’ll have to wait 10-30 minutes for the ISO to be created.

8. After the conversion is done, you’ll find a new ISO in the folder you set.

9. We could use this to install a VM manually, but Convert-WindowsImage.ps1 can automatically create a bootable .VHDX for us. First, open PowerShell as an administrator.

10. Then import the Convert-WindowsImage.ps1 script and run 'Convert-WindowsImage -SourcePath <ISO name here>'.

11. After a couple of minutes, you'll find a new .vhdx file beside your ISO. We can now use this with Hyper-V.