- Windows-10 iso image (64-bit).
- Virtual box 6.1 or above.
- Downloadable link for virtio drivers–https://docs.fedoraproject.org/en-US/quick-docs/creating-windows-virtual-machines-using-virtio-drivers.
Create a Virtual Machine (VM):
- Open VirtualBox manager and create a new VM. Provide the name of the VM. Click on continue.
- Select the memory size as appropriate. Try to keep a minimum of 4 Gb and click continue.
- Select create a virtual disk now and click continue.
- Choose type as VMDK and click continue.
- Choose dynamic allocation and click continue.
- Choose the file location and size. Try to keep the minimum size to 30GB and location can be the default.
- Click on the settings and then system and check for the following settings:
- The boot order should be the first CD ROM and then the hard disk.
- In the extended features make sure all three are selected.
- Click on storage and perform the following.
- Add windows 10 optical drive downloaded.
- Add virtio driver iso downloaded.
Please refer to the snapshots below.
Review the Final Configuration
Check for the following:
EFI should be enabled.
- The boot order should be first optical drive and then hard disk.
- In the storage, windows iso should be there on port1 and on port 2
- Virtio driver iso
Start the Windows Installations
Install Virtio Driver:
- Right-click on windows and click on file explorer.
- Navigate to drive where virtio drivers are mounted.
- Here it is on e: drive.
- Look for virtio-win-gt-x64. You will see it in the drivers.
- Follow the installation guide and install the drivers.
- Refer to the attached screenshots.
Inject Storage Drivers in pe environment:
- Search for settings in search and click on settings.
- Select update and security settings.
- Select recovery and click on recovery.
- Select restart.
- Select Troubleshoot.
- Select Advanced options.
- Select command prompt.
- The system will be rebooted. Enter your username and password if asked.
- You will land in the command prompt.
- We need to look for our mounted drivers. Type the following commands:
- In this setup, it’s on e-drive.
- Go to the following directory: e:\amd64\w10 (as the virtio drivers are mounted on e-drive)
- Let’s load and install both scsi and viostor driver.
- First load the driver
- Inject the driver. Here the drive-c represents the drive where my Windows installation is.
- Exit and Turn off the PC.
Convert the Image to qcow2 Format
Use the following command to convert the image to qcow2 format:
qemu-img convert -f vmdk -O qcow2 fml-vbox-vm.vmdk virtual-box-w10vm.qcow2