Proxmox reporting VM RAM utilization at 90%+ when in reality is not more than 15%

logui

Member
Feb 22, 2024
65
6
8
I am using OPNsense as a VM in Proxmox, I am not sure if I should use Ballooning or not, but, when the guest is running Proxmox reports around 90%+ RAM usage, when in reality is no more than 15% utilization, I have been playing around with Ballooning ON/OFF, but it doesn't seem to solve the memory reporting issue in Proxmox, any idea why this might be happening, thanks
 
What does 15% mean? Does it mean that 15% is "used" and some other amount is "cache & buffers"? The difference does not matter to PVE, whatever the RAM is used for, it is not free to allocate elsewhere as far as the hypervisor is concerned.

You don't say if you do PCI pass-through of your network card but if you do all memory must be pre-allocated because of DMA.

Finally, balloon doesn't operate until the host memory is 80% used. You also must set min and max memory that are different and have the guest tools installed in the VM.

In general you should not use ballooning. Especially with a router where RAM usage is typically fairly constant. Just only give the VM what it needs in the first place.
 
What does 15% mean? Does it mean that 15% is "used" and some other amount is "cache & buffers"? The difference does not matter to PVE, whatever the RAM is used for, it is not free to allocate elsewhere as far as the hypervisor is concerned.

You don't say if you do PCI pass-through of your network card but if you do all memory must be pre-allocated because of DMA.

Finally, balloon doesn't operate until the host memory is 80% used. You also must set min and max memory that are different and have the guest tools installed in the VM.

In general you should not use ballooning. Especially with a router where RAM usage is typically fairly constant. Just only give the VM what it needs in the first place.
I was using PCI pass-through then changed to Bridge as part of the troubleshooting, the only difference was, as you said, with PCI pass-through all the. memory was allocated at boot, with Bridge it has increased over a short period of time, to almost the same value as PCI.

I have used Ballooning ON and OFF as part of the troubleshooting, but the same no difference.
 
I was using PCI pass-through then changed to Bridge as part of the troubleshooting, the only difference was, as you said, with PCI pass-through all the. memory was allocated at boot, with Bridge it has increased over a short period of time, to almost the same value as PCI.
Most operating systems will use all otherwise-unused RAM as disk cache. That is probably what you are seeing. I don't know how the guest tools report RAM usage for OPNSense but some report cached as "used", some as "available" and some report it as "free". It doesn't really make any real difference to PVE, although it does make a difference to what the little line says in the GUI.

If you want it to use less RAM, give it less.
 

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!