bitwarden / clients

Bitwarden client apps (web, browser extension, desktop, and cli).
https://bitwarden.com
Other
9.29k stars 1.25k forks source link

Two percent CPU usage every ten seconds when idle on Mac #2598

Open evgenyneu opened 2 years ago

evgenyneu commented 2 years ago

Steps To Reproduce

  1. Install Bitwarden desktop app on macOS Monterey 12.0.1, MacBook Pro 14" M1 Pro laptop.
  2. In Terminal run top or htop (install with brew install htop).
  3. Do not run any other programs including web browsers.

Expected Result

All Bitwadren processes combined do not use more than 0.1% CPU juice.

Actual Result

Bitwarden processes use about 2% CPU every ten seconds.

Screenshots or Videos

https://user-images.githubusercontent.com/880411/146317739-c081e786-3b11-4854-98ae-a14c5d0d54e3.mp4

Additional Context

No response

Operating System

macOS

Operating System Version

12.0.1

Installation method

Mac App Store

Build Version

1.30.0 (1935)

jlucansky commented 2 years ago

Cumulatively bitwarden background processes consume for about 1 hour of your battery for running full day! I just tested by myself couple of times. You can get almost 1 hour for free if you just quit bitwarden desktop app for a day!

evgenyneu commented 2 years ago

Anyone knows what's causing that CPU spike every 10 seconds?

rnayabed commented 2 years ago

On windows too, it keeps using 0.2-0.3% CPU all the time on idle.

kernkraft235 commented 1 year ago

The constant CPU usage doesn't seem to be permanent. After the following sequence of events Bitwarden.exe is using effectively zero CPU (previously it was constant 1-2%)

  1. I right-clicked bitwarden.exe in detail's tab of task manager after noticing it's high cpu time
  2. I selected "analyze wait chain". Nothing popped up, but my bitwarden gui window closed
  3. I tried to reopen gui from tray, windows pops up but is whited out, only menu shows.
  4. I exit bitwarden by rightclicking tray icon and selecting exit
  5. I restart bitwarden and unlock using windows hello

Here's some extra info that may help:

karlemilnikka commented 2 months ago

I can confirm the same issue with Bitwarden Desktop 2024.8.1 (28903) on macOS 14.6.1. I only use the desktop app for unlocking the vaults in the Firefox browser addon (2024.8.1) now that it works again. Re-installing the desktop app didn’t make a difference.