Passing Entire Physical Disk to VM


Recommended Posts

Hi, without passing through the sata controller, first you need a virtual controller.

Having said that you can passthrough the whole disk as a block device, with this xml snippet (this is an example that passthrough the disk with id ata-CT500MX500SSD1_1807E10EA5F2) inside the <devices></devices> section:

 

    <disk type='block' device='disk'>
      <driver name='qemu' type='raw' cache='writeback'/>
      <source dev='/dev/disk/by-id/ata-CT500MX500SSD1_1807E10EA5F2'/>
      <target dev='hdc' bus='sata'/>
      <address type='drive' controller='0' bus='0' target='0' unit='2'/>
    </disk>

 

The above snippet passthrough a disk attached to a sata virtual controller (bus='sata'): q35 machine type already includes one at 00:1f.2

To find your disk identifier (id) simply do "ls /dev/disk/by-id/" in unraid terminal.

-partx (where x is a number) are not disks but partitions, so ignore them all.

Edited by ghost82
Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.