BOINC / boinc

Open-source software for volunteer computing and grid computing.
https://boinc.berkeley.edu
GNU Lesser General Public License v3.0
2.03k stars 449 forks source link

client: measure CPU time of VBox apps correctly #5867

Closed davidpanderson closed 3 weeks ago

davidpanderson commented 3 weeks ago

We were checking for VBoxSVC.exe and, if a VBox app is running, counting its CPU time as BOINC-related. Should be 'VBoxHeadless.exe' on Win. May be different on Mac/Linux, so use 'vbox', case-insensitive

computezrmle commented 3 weeks ago

Not all vbox processes are necessarily BOINC related. Imagine VMs running in the background to provide special services like

Thus, only those processes should be included that are in the BOINC process tree. In addition there may be more than 1 BOINC client running on a computer and each of them has its own process tree.

AenBleidd commented 3 weeks ago

@davidpanderson, please fix Windows build

davidpanderson commented 3 weeks ago

The VBoxHeadless.exe processes are in the VBoxSVC.exe process tree, the BOINC client tree. I don't know how to identify them as BOINC jobs.

In any case: the only thing this affects is the "suspend if non-BOINC CPU usage exceeds X" pref, whose purpose is to ensure fast interactive response, e.g. if the user does a compile. It's critical that we not suspend BOINC because of its own computation.

codecov[bot] commented 3 weeks ago

Codecov Report

Attention: Patch coverage is 0% with 2 lines in your changes missing coverage. Please review.

Project coverage is 10.75%. Comparing base (f27cc8e) to head (b9eb3c6). Report is 86 commits behind head on master.

Files with missing lines Patch % Lines
lib/procinfo.cpp 0.00% 2 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #5867 +/- ## ============================================ + Coverage 10.51% 10.75% +0.23% Complexity 1068 1068 ============================================ Files 280 280 Lines 36021 36552 +531 Branches 8441 8471 +30 ============================================ + Hits 3789 3930 +141 - Misses 31843 32233 +390 Partials 389 389 ``` | [Files with missing lines](https://app.codecov.io/gh/BOINC/boinc/pull/5867?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=BOINC) | Coverage Δ | | |---|---|---| | [lib/procinfo.h](https://app.codecov.io/gh/BOINC/boinc/pull/5867?src=pr&el=tree&filepath=lib%2Fprocinfo.h&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=BOINC#diff-bGliL3Byb2NpbmZvLmg=) | `0.00% <ø> (ø)` | | | [lib/procinfo.cpp](https://app.codecov.io/gh/BOINC/boinc/pull/5867?src=pr&el=tree&filepath=lib%2Fprocinfo.cpp&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=BOINC#diff-bGliL3Byb2NpbmZvLmNwcA==) | `0.00% <0.00%> (ø)` | | ... and [102 files with indirect coverage changes](https://app.codecov.io/gh/BOINC/boinc/pull/5867/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=BOINC)
AenBleidd commented 3 weeks ago

@computezrmle, could this be later better handled with the new functionality introduced in #5870?