ERROR: Backup of VM <id> failed - PCI device <device> already in use by VMID '<id>'

marcosscriven

Member
Mar 6, 2021
142
12
23
I got the following error when backing up overnight:

Code:
ERROR: Backup of VM 114 failed - PCI device '0000:15:00.0' already in use by VMID '107'

Now I know why this is - just as it says, the PCI device (a GPU in this case), is already in use.

However, I wonder what the recommended solution is? I have various VMs that are all setup to use the same GPU, and often I'll leave one running doing some kind of background job.

I don't therefore want to have to stop the VM that has the GPU currently, just to backup all the others. Is there a way to automate this so the VM being backed up doesn't demand the PCI device is available?
 
Sorry to bump this, but curious how other people manage this? All I can think is either you simply have to script bringing down all hosts the share a PCI resource before backup (not ideal), or there's some way to script removing the resource as a dependency before and after backup (if it's not already the one running and using it).

But if that's the case, I could imagine that just being a backup option.
 
the issue here is that doing a backup requires the VM to be started in a sort of "paused" state at least. because we allow the VM to be resume/started while it is in this state and being backed up, we use the full, regular config for this (except for templates, because they are not supposed to be fully started ever, so we can use a minimized config there). we'd need to introduce an option that allows you to choose to use such a minimized config for a regular VM as well (which would mean that you cannot start that VM without waiting for the backup to finish, or aborting it first).
 
  • Like
Reactions: marcosscriven
the issue here is that doing a backup requires the VM to be started in a sort of "paused" state at least. because we allow the VM to be resume/started while it is in this state and being backed up, we use the full, regular config for this (except for templates, because they are not supposed to be fully started ever, so we can use a minimized config there). we'd need to introduce an option that allows you to choose to use such a minimized config for a regular VM as well (which would mean that you cannot start that VM without waiting for the backup to finish, or aborting it first).
Thanks - are you saying that essentially right now this would have to be a new feature, and there's not a recommended way to work around it?

Where's the best place to formally request such a feature? Also, would an alternative be for passthrough failures simply mean the backup was tried without the thing that failed to passthrough (rather than a minimal config)?
 
yes, this would be a new feature, but one where most building blocks already exists. https://bugzilla.proxmox.com would be the place to file and track this.

I don't think just dropping the passthrough parts really makes sense - the result is the same (the VM cannot be resumed as the config and the running state don't match), so we might as well have a single, unified way of transforming a config into a "no-resume, start-for-backup-only" config ;)
 
  • Like
Reactions: marcosscriven