Opened 2 years ago
Closed 2 years ago
#214 closed enhancement (implemented)
Scan and assign PCI devices to netvm directly before NetVM start
| Reported by: | joanna | Owned by: | joanna |
|---|---|---|---|
| Priority: | major | Milestone: | Release 1 Beta 2 |
| Component: | core | Keywords: | |
| Cc: |
Description
Currently we scan for NICs and assign them to the default NetVM at install time. This works for most cases, but will not work in the following scenarios:
1) User upgrades their system (not for laptops)
2) User installed Qubes on an external USB driver and now plugged it and booted on a different machine that has different hardware.
Change History (3)
comment:1 Changed 2 years ago by joanna
- Type changed from defect to enhancement
comment:2 Changed 2 years ago by joanna
Perhaps we will close this ticker of this as part of getting rid of xend .conf files?
comment:3 Changed 2 years ago by marmarek
- Resolution set to implemented
- Status changed from new to closed
PCI devices can by assigned to VMs by qvm-prefs.
Warning: still network devices are assigned to pciback driver at boot time. Only network devices.
(will be changed, when USB controllers will be moved to NetVM/some other VM)

But, on the other hand, we should not always assign all devices to each netvm -- some users might wish to use more than one netvm and assign some NICs to netvm #1, and some other to netvm #2, etc.
I think the best way would be to keep in our qubes.xml a property for each netvm whether it should be assigned "all NIC devices" (so is a default and only one netvm), or whether the user decided to assign some select devices to it, in which case we should be updating the .conf files accordingly.
qvm-pref could be used to set which NICs are assigned for each NetVM (by default we would assume a netvm that doesn't have this propery is a default one and get all the NICs on start).