Memory Limit with PCIE GPU Passthrough

simonw

New Member
Mar 20, 2023
9
2
3
Hello!

I use Proxmox 7.3.6 and have a strange problem with a memory limit of 32 GB for a vm in combination with PCIE. If I use more memory e.g. 64 GB or 128 GB the VM is not able to start with:

Mar 20 23:18:32 pcl1 pvestatd[12324]: VM 222 qmp command failed - VM 222 qmp command 'query-proxmox-support' failed - unable to connect to VM 222 qmp socket - Connection refused

Any hints for this?

Best regards

Simon
 
I had a similar problem with 22GiB. Maybe this answer can help you?
@leesteken Thank you for your hint. I will try this after the working hour.
I had that problem because of memory hotplug. If you are not using memory hotplug, then probably it's something different.

I use Proxmox 7.3.6 and have a strange problem with a memory limit of 32 GB for a vm in combination with PCIE. If I use more memory e.g. 64 GB or 128 GB the VM is not able to start with:
If there are no related error messages in the journalctl then it's most likely that there is not enough free memory. Note that because of possible device-initiated DMA, all VM memory must be pinned into actual host memory (and ballooning and KSM don't work). Therefore a VM with passthrough needs all memory all the time.
 
I did not use memory hot plug or something like this, but your hint saved me. Thanks it works now :)

Check the following file:
cat /sys/module/vhost/parameters/max_mem_regions which had 64
--------------------------------------------------------------------------------------------------
Make following changes on all nodes of the cluster
Add/edit file: /etc/modprobe.d/vhost.conf
options vhost max_mem_regions=509
--------------------------------------------------------------------------------------------------
Reboot each node after the changes.
Verify the changes:
cat /sys/module/vhost/parameters/max_mem_regions
--------------------------------------------------------------------------------------------------
Start VM which was throwing the error.
 
  • Like
Reactions: leesteken