VirtualBox

Ticket #11998 (new defect)

Opened 2 years ago

Last modified 23 months ago

VBox SVC - Potential memory leak

Reported by: CyberChris Owned by:
Priority: major Component: VM control
Version: VirtualBox 4.2.16 Keywords: VBoxSVC Watcher memory cpu
Cc: Guest type: Windows
Host type: Linux

Description

Hey,

So I have been running several Windows XP guest machines now for a few weeks and noticed that the VBoxSVC process is constantly growing in resident memory usage.

I am using Ubuntu 13.04 with Virtual Box 4.2.10 (from the Ubuntu repo)

I have written a script that uses "vboxmanage" to start, get the info and stop 10 machines. This should hopefully simulate weeks of usage.

The key here is to not let the VBoxSVC process to exit, as this causes the problem to go away.

The real issue here is that the CPU usage goes right up to 100%. Crucially, the CPU usage of the "Watcher" thread over takes all the other threads.

I am not sure where the problem is after some initial debugging of the source code, however it feels like there is some sort of link list that is constantly growing which is then taking longer and longer to process. The issue here is it takes a long time to issue commands to the VM.

Shutting all of the VMs down so that the VBoxSVC process exits does resolve the issue, however is a major inconvenience.

If there is any further logs you require, please let me know. It may be worth mentioning that I have replicated this up from 4.2.10 - 4.2.16.

Cheers! :)

Attachments

top Download (3.2 KB) - added by CyberChris 2 years ago.
Output of top showing the VBoxSVC
top1 Download (1.5 KB) - added by CyberChris 2 years ago.
Output of VBoxSVC showing its running threads
run.pl Download (938 bytes) - added by CyberChris 2 years ago.
Script that runs the machines to replicate the fault
clone.pl Download (445 bytes) - added by CyberChris 2 years ago.
Script to quickly clone N machines for a given machine name
file Download (508.3 KB) - added by CyberChris 2 years ago.
VBox.log for sample_clone_0

Change History

Changed 2 years ago by CyberChris

  • attachment top Download added

Output of top showing the VBoxSVC

Changed 2 years ago by CyberChris

  • attachment top1 Download added

Output of VBoxSVC showing its running threads

comment:1 Changed 2 years ago by frank

We cannot reproduce your problem. We've tried several different timings but the memory consumption of VBoxSVC remains stable. It might also depend on the guest and the installed Guest Additions. Could you attach a VBox.log file of such a VM session? Use just the log file from the last VM session, mainly to get the VM configuration.

Also, were you able to reproduce the problem yourself when using your script? Btw, you can also start VBoxSVC manually, then it will not terminate until you stop it manually.

comment:2 Changed 2 years ago by CyberChris

Hi,

So in my example I had 10 machines cycling for around 3 days (To mimic weeks worth of usage). I can re-start the test and include the VBox.log of a given machine for you no problem. Also, I was able to replicate the issue with the script, but as I said you need multiple machines and you can't let the VBoxSVC process exit so you always have to have at least one machine up, but yes you could launch the SVC manually, I am aware of this :)

When you say "stable" what amount of memory has it got allocated as it starts with 18M resident but in several tests across different hardware constantly grows until the CPU usage is up to 100% and around 350MB.

In terms of guest additions, in the tests I have been carrying out I have not installed any guest additions.

I will attempt to attach the log file asap but thanks so far for investigating this ticket. I can attach the script I have for cloning machines, but really its just a script for calling "vboxmanage" for N times.

Finally, can I just ask what OS you replicated the issue on, or did you use Ubuntu 13.04 as well?

Cheers,

Chris

Changed 2 years ago by CyberChris

Script that runs the machines to replicate the fault

Changed 2 years ago by CyberChris

Script to quickly clone N machines for a given machine name

Changed 2 years ago by CyberChris

  • attachment file Download added

VBox.log for sample_clone_0

comment:3 Changed 2 years ago by CyberChris

Hi Frank,

I just uploaded one of the machines log file. This machine appears to have entered some difficulties, however the problem with the SVC growing in size still continued.

Also, I have replaced my script so that it doesn't background the "vboxmanage" as this was a mistake, but shouldn't have affected things.

Hope this helps and I look forward to your reply :)

Chris

comment:4 Changed 23 months ago by CyberChris

Hey Frank,

Just wondering how this is all going? Any luck replicating that fault?

Cheers,

Chris

comment:5 Changed 23 months ago by frank

Chris, I think I was able to see some memory leak but it's a bit hard to reproduce. We will investigate but not with the highest priority.

Note: See TracTickets for help on using tickets.

www.oracle.com
ContactPrivacy policyTerms of Use