VMware Communities
dragongc
Enthusiast
Enthusiast

Running Worksation and Firefox (on host) - High CPU usage.

Hi all,

A little bit of background information:

Host - a laptop with Ubuntu 14.04 64-Bit (tested on both 3.13 and 3.16 kernels - aka "new hardware stack, 14.04.2"), Intel i7, 12 GB RAM, SSD

Workstation - 10 and 11

Firefox - tested from 30 to 35, installed on the host

I've got such an issue:

Whenever the FF process runs on the host, alongside a guest VM, there is a high CPU usage. The guest can be of any type - Linux, Windows, BSD, etc. It doesn't matter if the guest do anything or not.

Firefox alone or Workstation/Player alone -  no issue at all. I can even use Firefox with Workstation as a client for ESXi server without any problems.

There is no pattern with these CPU spikes. Sometimes I don't have to open any tabs at all. It is enough to run the FF process, even in the safe mode without any addons.

I've reinstalled both, cleaned configuration, tested without any other software.

I've got one more option - reinstall the host system, but I'd like to avoid this path ๐Ÿ˜ž

I've spent a couple of weeks looking for the solution, but still no luck.

Any constructive help will be well received (Use Chrome instead of FF isn't helpful ๐Ÿ˜‰ )

Regards

Gregory

13 Replies
continuum
Immortal
Immortal

Is the problem related to the Windowmanager you use ?
If possible I would check next if the behaviour is the same with Xfce or IceWM

Next I would switch off the non-essential VMware-services - maybe you do not need them all


________________________________________________
Do you need support with a VMFS recovery problem ? - send a message via skype "sanbarrow"
I do not support Workstation 16 at this time ...

Reply
0 Kudos
dragongc
Enthusiast
Enthusiast

First of all, thank you for you interest and input.

Second - your idea with changing the WM is appealing but it has two drawbacks for me:

- I like Ubuntu Unity ๐Ÿ˜‰

- Installing another WM adds a hundred of additional packages. From my experience, it's really hard to clean this up. Literally it is better to reinstall ๐Ÿ™‚

I think I might narrowed down the issue a bit. Something is wrong with CPU scheduling.

When I use a guest with One CPU, the issue is less visible, but still appears.

However whenever there is a VM with two vCPUs or two VMs (each with one CPU), the situation is very bad.

I've used Linux namespaces, and jailed FF process using Firejail. I'm not a big Linux expert, but IMHO this should rule out any race conditions.

As you can image, although the FF process was in the jail environment and wasn't aware of any other process, the issue still existed.

I wonder if there is a problem with Intel Turbo Boost or maybe new Intel P-state governor.

I've also upgraded to 11.1, I'm going to check it today.

One more think - Could you elaborate your second advise "... switch off the non-essential VMware-services ... "

Regards

Gregory

jchessma
Contributor
Contributor

I'll be interested in hearing any progress you make on this. I am having a similar issue with kUbuntu 15.04 (so KDE window manager) and Workstation 11.1.2.  Firefox (39.0) becomes extremely slow with periodic (and regular) freezes with the same occurring in VMware Workstation. Shutting down either FF or Workstation resolves the problem and there is no conflict with other browsers (such as Chrome).  The problem also seems to get worse if a guest has more the 2G of RAM assigned to it (4G brings things to a halt).

My system is a Lenovo T440s with 12G of RAM and a 1T SSD so 4G should not be a problem though I'd be happy if it worked smoothly with 2G.  One thought I had is that I am using full disk encryption and was thinking that could be causing a disk access problem. Of course the issue only appears with Firefox so that seems to kill that thought. I had also been thinking that the problem might be related to a specific Firefox plugin but have not had a chance to go through and disable each plugin.

Thanks!

FenyX
Contributor
Contributor

I'd be interested too. It's not a job-breaker but annoying. I have the exact same problem and it has been reproduced with VMWare Workstation v11 & v12 under:

- openSUSE x86_64 / KDE 4

- Kubuntu x86_64 / KDE 5

- Xubuntu x86_64 / Xfce 4

- Fedora x86_64 / Gnome 3 (without Unity)

- Windows 7 Ent x64

- Windows 8.1 Ent x64

The testing machines were Thinkpad T420 Core i5 SSD 16GB RAM and Thinkpad x230 Core i7 SSD 16GB RAM.

I can reproduce the CPU issues with Firefox ESR 38.2 and Firefox 40.0, Chromium/Chrome but nor Opera nor Opera Beta (former Opera Next). Nor Midori nor Lynx lol, but I've tested just for fun Smiley Wink

There's really something wrong buds, the cause couldn't be only your client's systems configuration. My first reaction has been to think that it was only occuring under Linux, suspecting any kind of kernel bug. But after having discussed it with colleagues using Windows, we understood that it wasn't related to the OS platform. Could we finally expect some expert review and support?

Reply
0 Kudos
nevenzhal
Contributor
Contributor

Since you are comfortable to test various browsers may I suggest that you also test Pale Moon. If is a FF derivative without the superfluous junk like Hello and such. You can install and run it side-by-side with standard FF on the same machine.

If the problem disappears, than the root cause points to the items removed from FF (and those are listed on the PM site).

Reply
0 Kudos
FenyX
Contributor
Contributor

I've edited my post to add Chromium/Chrome, one colleague had the same issue with this browser on Windows 7. So I've tested on Linux as I'm not a Windows user at all and yes, the same issue exist with Chromium. I didn't see it the first time because I've been using a different VM at that time, using only one CPU core as described in the first post of this topic. My fault.

Pale Moon is not such a miracle, I've used it in the past but the difference with Firefox ESR (the ff version it's based on) was very tiny in terms of performance. Anyway, I gave a try to your suggestion under Linux, and I can reproduce the same issue once again.

You suggested indirectly that the browser CPU consumption could be the cause but I think that it's more relative to the way CPU tasks are adressed by these softwares, including VMWare. But I'm not skilled enough to understand in depth. Note that I don't load any website or tab in browsers when testing. Just the search engine home page.

Thanks to you nevenzhal, but we're searching for a solution, not a workaround Smiley Happy


Edit:

because of my first mistake I double-checked browsers again and even if Opera seems to open quite smoothly, the issue is the same for Opera Beta (that use the Chrome/Webkit engine). I think it would be the same with Safari as it's also powered by the Webkit engine.
My Opera installation is not up-to-date, it's an old version using Presto. So the bug would exist for Webkit and Gecko layout engines but not for Presto? Not sure as it's hard to believe, maybe something wrong in my test. Could require more testing. Feel free to contribute.

Reply
0 Kudos
dragongc
Enthusiast
Enthusiast

I can see one common denominator - SSD. Mine is Samsung EVO 850, with the latest firmware and I use build in hardware encryption.

However two of mine colleagues have got the same model (different sizes). Both of them are using Windows 7 and no encryption. They haven't got any issues with VM and FF.

In another thread someone wrote that using "vblank_mode=0 vmware" resolved the issue. But he/she has got an external GPU. It doesn't help in my configuration.

Also I've updated Workstation to 11.1 and FF to 40 and hardware enable stack (Kernel 3.19 and X to 17.2). The issue still appears. At this point I'm reluctant to buy upgrade for 12. It could be a waste of money ๐Ÿ˜ž

Reply
0 Kudos
Tarr3128
Contributor
Contributor

Hi,

I have been experiencing since upgrading to Workstation 11 and still experience it with Workstation 12. Workstation 10 was not affected to a noticeable degree most of the time, not completely sure. I am using Archlinux on a Notebook with a Nvidia 5200M. I had this issue before upgrading to SSD, so this can't be the issue. Setting __GL_SYNC_TO_VBLANK=0 seem to solve the problem.

A fix would be really nice because frankly it is not really possible to use VMware Workstation while Chromium is running. The workaround does the job, but still this is just bad.

Michael

Reply
0 Kudos
a500drvr
Contributor
Contributor

Did anyone get an answer on this?

I am having the same issue with FF.  Chrome works fine.  Windows 7 machine running VMWorkstation 12.1..

High CPU and all apps become unresponsive, still looking for answers.

Reply
0 Kudos
erichnewell
Contributor
Contributor

This problem had been plaguing me for months...today I think I've finally sussed it. It was compiz/X11 settings syncing. I am uncertain if all of my current settings are necessary but the final one that was the "magic fix" was disabling  "X11 Sync Objects" for compiz.

Compiz Settings Manager -> General -> OpenGL -> X11 Sync Objects tab -> Uncheck "Enable"

Other details that may be relevant and/or settings I have in place in an effort to fix this that may or may not also be required:

  1. Discrete video card: Nvidia Titan
  2. VMWare Workstation Pro version 12.1.1 build-3770994
  3. Linux Mint Mate 18 with Compiz / OpenGL enabled
  4. Compiz Settings Manager -> General -> OpenGL -> General tab -> Uncheck "Sync to VBlank"
  5. Nvidia X Server Settings -> OpenGL Settings -> Uncheck "Sync to VBlank"
  6. I have the following set at boot: GRUB_CMDLINE_LINUX_DEFAULT="intel_iommu=igfx_off"
  7. For Firefox, I have "layers.acceleration.force-enabled" set to "true"
  8. Finally, I have a small stub which launches vmware with vblank disabled:

cat /usr/local/bin/vmwareNoVBlank

#!/bin/bash

vblank_mode=0 vmware

As now configured, I am running several VMs of various flavors alongside 4 different Firefox profiles. Each of those has several plugins ranging from Firebug to ABP, and I can run google maps in 3D streetview with lightning speed. Spinning my six separate workspaces while running 3D objects on some and video on others and the VMs...no tearing or crashing! :smileygrin:

I sincerely hope these notes help someone else, as I've been tearing my hair out over this for quite some time and am now super happy with my setup. Everything runs super smooth and fast!

OscarNiemi
Contributor
Contributor

oh yes! I finally got it to work Smiley Happy

I've tried everything but when you add the following to /etc/rc.local before the exit 0 row your machine will be like a different machine.

#VMWare and firefox CPU fix

if test -f /sys/kernel/mm/transparent_hugepage/enabled; then

echo never > /sys/kernel/mm/transparent_hugepage/enabled

fi

if test -f /sys/kernel/mm/transparent_hugepage/defrag; then

echo never > /sys/kernel/mm/transparent_hugepage/defrag

fi

sfrigon
Contributor
Contributor

Thank you.

I had the same problem and your solution fixed it. (Host: Ubuntu 16.04, VMwareยฎ Workstation 12 Pro version 12.5.0).  It was a show stopper for me, I was about to switch to another alternative, but luckily I found your solution Smiley Happy

It makes sense too because I was seeing something related to hugepage in "top" when the problem occurred.

Reply
0 Kudos
PDiracDelta
Contributor
Contributor

Wow, I've been struggling with VMWare on Linux for 2 years now, and this finally solved it.

You have my gratitude, lots of it!

Reply
0 Kudos