Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

How to turn a Physical Windows 10 Install into a Win10 VM on unraid?

Featured Replies

I read theres a program called Disk2vhd which will allow me to create a vm snapshot of my physical Windows 10 machine.  Then I can suppodly load that in VMware, but not unraid.  I also read that you have to convert the .VHD file created by Disk2vhd into a .img file unraid can read.  Whats the best way to do this?  Or is there a way to directly turn my windows 10 machine into a .img file unraid can read without first making it a .VHD?

On 5/15/2021 at 11:03 AM, 007craft said:

I read theres a program called Disk2vhd which will allow me to create a vm snapshot of my physical Windows 10 machine.  Then I can suppodly load that in VMware, but not unraid.  I also read that you have to convert the .VHD file created by Disk2vhd into a .img file unraid can read.  Whats the best way to do this?  Or is there a way to directly turn my windows 10 machine into a .img file unraid can read without first making it a .VHD?

 

You can use dd but this will create a flat image, so if you have your windows physical disk of 1 tb the dd command will create a clone image of 1 tb.

Better to use qemu-img command to create a sparse image.

Assuming your windows 10 disk is /dev/sda

qemu-img convert -p -S 512 /dev/sda -O raw /path/to/image/destination/win10image.img

Make sure that the disk of /path/to/image/destination has enough space!

I never tried, but the command should create a sparse image of let's say 1 tb (based on the example above), but with the -S option the command will write zeroes for the not used space. -->  with the -S argument I don't know if the command creates an image of a size corresponding to that effectively used by the vm or if it creates an image of a size of that of the disk with unused spaced filled with zeroes.

If it creates a file of a size corresponding to that of the disk you can run again the qemu-img command to deduplicate the image:

qemu-img convert -p -O raw win10image.img dedup-win10image.img

This will create a deduplicated image without the zeroes, so it will shrink its size.

 

Important: always take into account the needed space of the destination disk to perform conversions of images.

-------------

By the way you can also convert the vhd image with qemu-img:

qemu-img convert -f vpc -O raw /path/to/vhd/file/image.vhd /path/to/destination/image.img

Or you can directly use the vhd file in qemu/libvirt, example attaches the disk to bus virtio, (however my choice would be to convert it):

<disk type='file' device='disk'>
    <driver name='qemu' type='vpc' cache='none' io='native' discard='unmap' />
    <source file='/path/to/file.vhd'/>
    <target dev='vda' bus='virtio'/>
</disk>

 

Edited by ghost82

Archived

This topic is now archived and is closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.