[pve-devel] applied: [PATCH qemu-server] fix #6935: vmstatus: use CGroup for host memory usage
Fiona Ebner
f.ebner at proxmox.com
Wed Jan 14 14:34:57 CET 2026
On Fri, 28 Nov 2025 11:36:34 +0100, Fabian Grünbichler wrote:
> after a certain amount of KSM sharing, PSS lookups become prohibitively
> expensive. instead of reverting to the old broken method, simply use the
> cgroup's memory usage as `memhost` value.
>
> this does not account for merged pages because of KSM anymore.
>
> I benchmarked this with 4 VMs running with different levels of KSM sharing. in
> the output below, "merged pages" refers to the contents of
> /proc/$pid/ksm_merging_pages, the extract_* benchmark runs refer to four
> different variants of extracting memory usage, with the actual extraction part
> running 1000x in a loop for each run to amortize perl/process setup costs,
> qm_status_stock is `qm status $vmid --verbose`, and qm_status_pateched is `perl
> -I./src/PVE ./src/bin/qm status $vmid --verbose` with this patch applied.
>
> [...]
Applied, thanks! Added a follow-up to improve the descriptions for the
'mem' and 'memhost' properties as Fabian suggested at the end of the
discussion of the RFC version.
[1/1] fix #6935: vmstatus: use CGroup for host memory usage
commit: 551c0078de6c2986b75a5db589db881723207624
More information about the pve-devel
mailing list