Lock assigned pass-through device to VM

ruffpl

Active Member
Jan 11, 2020
37
2
28
40
Is there some way to block, auto update by Proxmox (or any other way) pci device that is signed to VM? It happens sometimes when I reboot my home server- like on picture after reboot it added onboard nvme drive to Windows Server instead LSI controller with ssd drive attached to it (before reboot pci controller was 0000:07, after reboot it jumped to 08) .
 

Attachments

  • zxc.PNG
    zxc.PNG
    53.4 KB · Views: 15
Last edited:
What kernel are you on (uname -r)? As far as I can tell this shouldn't happen and was apparently a bug on 5.9? It can also happen after a kernel upgrade or bios upgrade (eventhough it shouldn't) but it should stay the same on a reboot.
 
Last edited:
Kernel 5.15.83-1-pve, I made update to 7.3 from 7.2 (or some other 7 version) that was installed as fresh system
 
Hi, sorry for the delay.
I talked to my colleague, who is more knowledgeable on the subject, about this. It seems you are just unlucky with your motherboard. Apparently, some BIOSes just change the pci numbering on reboot. In a future patch there should be a feature that warns you when a different pci devices is passed through than the time before but it isn't possible to automatically find the right device, since there is no way to identify unique devices (unlike NICs, pci don't have something like a mac address, so it wouldn't be possible to tell e.g. two gtx 1050s apart from one another).

What you can do is see if there is a new BIOS for your mainboard that fixes this. If it doesn't you could also write a little script that, on boot, checks lspci, parses out the ID you need and then overwrite your vm .conf. (not ideal, I know, sorry). Or, not reboot too often and manually check.

Hope this helps
 
  • Like
Reactions: bobmc

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!