hard drive passthrough

mjmclarty

Member
Nov 5, 2020
11
1
23
50
Is there a way to passthrough multiply hard drives? Using (qm set 102 -scsi5 /dev/disk/by-id/ata-) only does one drive and only gives the VM one drive. What I'm trying to do is pass through six drives to truenas so I can create a truenas pool.
 
Normal way would be to buy a PCIe HBA, use PCI Passthrough to connect it to your VM and attach all HDDs to that HBA. That way the HDDs would be physically addressable by the VM and not just virtualized.

You can use "qm set 102 -scsi6 /dev/disk/by-id/ata-", "qm set 102 -scsi7 /dev/disk/by-id/ata-", and so on to "passthrough" more drives but these drives aren't really physically passed through as far as I know. They are still virtualized using the virtio SCSI controller.
 
Last edited:
Nothing stops you from repeating the "qm set.." command multiple times for multiple drives. I use that exact method for a (Debian) file server using two HDD's that are passed-through.
 
A mod once mentioned that there is a limit (I think it was 9) on how much devices you could passthrough.
 
  • Like
Reactions: apoc
Per VM or per Host?
9 is greater 6 so it should be fine ?
Not sure. I think it was per VM and the mod wan't really sure about the number as well. The thread was about someone who wanted to passthrough alot of USB devices to a VM and reached a limit.