Qemu memory leak
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
qemu (Ubuntu) |
Expired
|
Undecided
|
Unassigned |
Bug Description
Only firefox and a 12gb RAM vm opened and 32gb ram are filled. htop and gnome-system-
## Host environment
- Operating system: Ubuntu 22.04
- OS/kernel version: Linux pc 5.15.0-39-generic #42-Ubuntu SMP Thu Jun 9 23:42:32 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
- Architecture: x86_64
- QEMU flavor: virt-manager's qemu
- QEMU version: QEMU emulator version 6.2.0 (Debian 1:6.2+dfsg-
## Emulated/
- Operating system: ubuntu 22.04
- OS/kernel version:Linux pc 5.15.0-40-generic #43-Ubuntu SMP Wed Jun 15 12:54:21 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
- Architecture: x86_64
## Description of problem
After starting/using my VM for a while, RAM fills up to the 32gb maximum, and firefox starts closing tabs and etc. This didn't happen in ubuntu 21.10 or earlier ubuntus. I've been using virt-manager + qemu for years and only had this after upgrading to ubuntu 22.04.
## Steps to reproduce
1. Launch virt-manager ubuntu VM with 12gb ram maximum (as an example)
2. RAM entire 32gb gets filled but nothing in gnome-system-
3. Firefox starts closing tabs because RAM is full. Remember that only a 12gb RAM vm and firefox with a few tabs are running, and it fills all 32gb of RAM. Ram starts filling slowly and in 1 hour it fills the entire 32gb. For some reason htop shows a smaller usage, but I'm pretty sure all 32gb are being used as the computer starts freezing and almost crashing (I think swap is being used so it slows down but do not crash)
4. have to restart the computer for RAM to get normal again
Image of gnome system monitor: https:/
Hello,
Thank you for submitting this bug report. I attempted to reproduce the issue on my 22.04 system with 32gb of RAM, allocating 12 to a qemu vm instance, but didn't run into a memory leak. Although it may just be difficult to encounter unless the right conditions are met.
As the RAM usage is increasing are you able to see any specific process taking up a large amount of it either in the system monitor processes tab or in htop?
Also would you be able to share the XML config of your virtual system? It may help determine the cause of the leak.
Thanks!