Commit Graph

66 Commits

Author SHA1 Message Date
David Anderson 290145dd96 Plumbing for sporadic app feature. Not finished. 2023-09-21 10:00:45 -07:00
Vitalii Koshura 44742026e2
Remove trailing whitespaces. Add CI script to verify in on every commit
Signed-off-by: Vitalii Koshura <lestat.de.lionkur@gmail.com>
2023-05-05 20:08:17 +02:00
David Anderson 245f93c22e client, Win: add a cc_config.xml option <no_rdp_check>.
If set, it skips the check to see if Remote Desktop Protocol (RDP) is in use,
allowing GPU apps to run while using RDP.
This should be done only if you have configured RDP as described here:
https://knowledge.civilgeo.com/knowledge-base/enabling-gpu-rendering-for-microsoft-remote-desktop/
2023-03-13 13:50:40 -07:00
David Anderson f616edc60a client and wrapper: fix process priority mismatch
It turns out we have two different encodings of process priority:
1) specified in cc_config.xml and used by the client: 0 (low) to 4 (high)
2) specified in job.xml and used by the wrapper: 1 (low) to 5 (high).

This didn't cause any problems until recently when I added code
to pass the cc_config.xml info to the wrapper;
it was interpreting it on the 1-5 scale.

Fix: have the wrapper convert it (add one).

Also: I forgot to have the client actually put the priority into
in the app_init_data.xml file.
2020-08-27 23:20:12 -07:00
davidpanderson ddf3a7e4bb Merge remote-tracking branch 'remotes/origin/master' into dpa_log_init 2020-04-24 23:52:14 -07:00
davidpanderson 62222e20c6 client: initialize log flags to task, sched_ops, file_xfer 2020-04-24 23:51:18 -07:00
David Anderson 1fceef042e client: allow specifying device name in cc_config.xml
If cc_config.xml contains <device_name>x</device_name>,
report that to projects rather than the name returned by gethostname()
2020-04-19 20:35:37 -07:00
David Anderson a79d60b889
client: make max_std(err/out)_file_size double
File sizes should always be double, not int

This fixes #3435

Signed-off-by: Vitalii Koshura <lestat.de.lionkur@gmail.com>
2020-01-29 07:42:43 +01:00
David Anderson 7b6cda76bb
Merge branch 'master' into dpa_ignore_tty 2019-12-27 18:38:41 -08:00
David Anderson 219a540550 client: get rid of the use of memset() to initialize structs to zero.
Instead: declare a static const instance (whose data members are zero)
and copy that.
This avoid the error-prone need to assign each member,
and it works even if there are virtual function tables.
2019-11-05 00:16:02 -08:00
David Anderson 7fa68ec0ea client: changes to GUI RPC file fetch mechanism
- disable it unless <allow_gui_rpc_get/> is in cc_config.xml
- return 400 and 403 HTTP replies in various error cases
- allow .html, .js, and .css filename extensions
- allow directories in path (but not ..).
    Files could be e.g. in project directories.
2019-07-16 23:52:34 -07:00
David Anderson 0b5bae4cc9 client: fix work fetch bug when max_concurrent used
For projects P with MC restrictions, during RR simulation,
we keep track of the max # of instances used by P,
subject to the restrictions, and use that to calculate its "MC shortfall".

Problem: if P doesn't have any jobs, the max # instances is zero,
so MC shortfall is zero, so we erroneously don't request work for P.

Solution: initialize max # of instances to the min of the restrictions;
we'll always be able to use at least that many instances.
2019-04-20 13:46:55 -07:00
David Anderson 81a880c74d client: improve work fetch in presence of max concurrent
Re-enable work buffering in the presence of max concurrent constraints.
See https://boinc.berkeley.edu/trac/wiki/WorkFetchMaxConcurrent
2019-03-25 21:43:30 -07:00
David Anderson 88b4baf8ce client: add <ignore_tty> config file option (Unix)
TTY devices starting with the given string(s) will be skipped
in checking for system idleness.
2019-03-02 19:50:49 -08:00
Charlie Fenton b1e629a5fb Move network_test_url tag from cc_config.xml into new nvc_config.xml file, since WCG modifies this for their branded builds (along with new version check info) and it is probably never modified for standard (unbranded) BOINC 2018-07-18 19:10:30 -07:00
Charlie Fenton 4f09c1979b Move client_version_check_url, client_download_url and client_new_version_text tags from cc_config.xml into new nvc_config.xml file.
If nvc_config.cml file is absent, use default values.
Branded installers can create or replace this file to customize these values.
Standard (unbranded) BOINC installers should either delete the file or create or replace it with one containing default values.
2018-07-14 04:59:06 -07:00
Vitalii Koshura f8f6443074
[Client] [WSL] Extend detection.
Move WSL detection to get_host_info().
Enumerate available WSLs from registry.
Add wslapi library loading.
Add support of multiple installed wsl distros detection.
Detect only installed and configured distros.
Add extra information parse.
Add wslinfo files to save and parse wsl info.
Add dont_use_wsl param to cc_config.
Add missed hostinfo_wsl.cpp when building win client using gcc.
Fix small issues.
Small refactoring.

Signed-off-by: Vitalii Koshura <lestat.de.lionkur@gmail.com>
2018-06-24 03:08:11 +03:00
David Anderson 5b6f648570 client/lib: add GUI RPCs for reading and writing app_config.xml files.
These will allow GUIs (e.g. BoincTasks) to provide dialogs for editing app config info.
2017-05-11 20:16:35 -07:00
David Anderson 4a9cc3e725 client/lib: code shuffle preparatory to adding app_config GUI RPC 2017-05-11 01:53:50 -07:00
David Anderson 13a5b9bf3e change multiple-inclusion guard names to BOINC_FILENAME_H 2017-04-07 23:54:49 -07:00
David Anderson 6c58c5b3f5 tweak, no functional change 2016-06-29 13:05:12 -07:00
David Anderson 2581ac688d Add <no_opencl/> option in cc_config.xml 2016-04-23 20:47:31 -07:00
Preston Maness fc4446f602
Reinstate and Improve XScreenSaver Idle Detection
The set of commits on this pull request:

https://github.com/BOINC/boinc/pull/1453

first reinstated previously existing code to utilize the XScreenSaver
(XSS) X extension when determining a system's idle state (there was
also additional DPMS code that was not reinstated).

Original removal:

bfae1032e5

The code would attempt to open a connection to the display at the client
binary's DISPLAY environment variable and, if unable to connect, always
report busy (undesirable).

The original motivation for reinstating this code was that the remaining
idle detection mechanisms did not detect mouse or keyboard movement if
an Xserver was responsible for them. Only activities in terminals were
detected. Through the course of extending and improving this code, the
following changes have been made:

  * As per "man Xserver", each local Xserver should have a socket file
    at standard location /tmp/.X11-unix/ with standard naming scheme
"Xn", where n is the number of the DISPLAY. This code will open this
directory and parse its contents for open DISPLAYs, adding them to a
vector for later interrogation of idle time by xss_idle. If no DISPLAYs
were found, a static guess-list from DISPLAY :0 to DISPLAY :6 is set and
interrogated.
  * xss_idle uses the XScreenSaver X extension's API, as documented at
    "man 3 xss". Certain checks are performed to determine if the X
server is accessible, and if so, whether it has the XScreenSaver
extension. If it does, then we obtain information on the DISPLAY's idle
time and determine whether the Xserver is idle or not.
  * The user running the boinc client (typically the "boinc" user for
    most distributions), must have access to the Xserver for XSS idle
detection to work. Dropping an appropriate file in /etc/X11/Xsession.d/
(Debian flavours) or /etc/X11/xinit/xinitrc.d/ (Fedora and others)
should permit Xservers to run something like "xhost +SI:localuser:boinc"
on start. If the boinc client cannot access an Xserver/DISPLAY, it
simply skips it and treats it as though it is idle. If no DISPLAY is
accessible, then xss_idle is effectively passed through --xss_idle will
report the system as idle-- and idle detection is left to other
mechanisms.
  * A debug logging flag "idle_detection_debug" was added. If this
    flag is defined in the cc_config.xml file as "1", then verbose
debugging information related to boinc's idle detection determinations is
provided to the Event Log. This logging flag may also be utilized
by other components of idle detection as/if needed/desired.
2015-12-30 17:03:35 -06:00
David Anderson ef6c241587 client (Win): lowering I/O priority is an option rather than the default
Apparently even the thread-level version (SetThreadPriority())
caused the client to starve and become unresponsive if
something else was doing lots of disk I/O.
2015-11-25 00:52:54 -08:00
David Anderson 3c8ceb028d client: add config option to not lower client priority
We added code a couple of months ago to lower client priority:
on Win, this is SetPriorityClass(),
which lowers I/O and memory priority as well as CPU.
This has the desired effect, i.e. to reduce the performance impact
of BOINC when it's doing things like copying large files.
However, it means that BOINC can take a long time to start at boot,
which may be disconcerting to some users.
2015-11-11 10:33:24 -08:00
David Anderson 517cc53c67 client: add separate config item for process priority of GPU/NCI/wrapper jobs 2015-09-29 22:40:40 -07:00
Vitalii Koshura 6200349f36 Fix issue #1128 2015-09-28 20:36:18 +03:00
David Anderson fb31a869ed client: add <dont_suspend_nci> config option.
If set, non-CPU-intensive jobs are exempted from mass suspend
(e.g. suspend CPU, time of day, CPU throttling).
You can still suspend them individually.
2015-01-05 12:58:40 -08:00
David Anderson bda8d7bc56 client: remove <data_dir> option from cc_config.xml
This leads to confusion;
e.g. if you do "read config files" it will look for cc_config.xml
in the new directory, not find it, and set default options.
Also, log files end up in old directory.
Also, gui_rpc_auth.cfg will be in new directory,
and the Manager won't look there.
2014-10-22 20:08:48 -07:00
David Anderson f8538c29b3 client: add <dont_use_vbox> cc_config option 2014-09-25 01:28:19 -07:00
David Anderson 1e2fcb4b68 client/lib: change CONFIG to CC_CONFIG, config to cc_config.
Eliminates ambiguity of "config" global var, which is used in server code.
This confuses IDEs that are looking at all the code at once.
2014-05-08 00:51:18 -07:00
David Anderson 1be9c1e0b1 lib: add code to write GPU exclusions in CC_CONFIG XML 2014-04-02 00:54:14 -07:00
David Anderson 276f8130a6 client: show event log line limit in event log at startup 2013-06-07 15:20:14 -07:00
David Anderson 1446fdddbe client: add <android_debug> log flag; shows battery/wifi RPC info 2013-06-04 11:25:11 -07:00
David Anderson e12e1d0138 client: add <client_new_version_text> config option
Lets you customize the notice that's generated when a new client version is available
2013-05-20 10:28:19 -07:00
Charlie Fenton 93aad6826c client & MGR: add support for <max_event_log_lines>N</max_event_log_lines> in cc_config.xml
Default is 2000
0 means unlimited
2013-05-18 03:25:44 -07:00
David Anderson 71b6508313 - client: add <fetch_on_update> config option;
requests work when you update a project
    even if it's not highest priority
2013-03-07 11:28:43 +01:00
David Anderson c17d20ccd9 - client: show sysmon messages correctly.
This was supposed to be in my 507cd79 commit, but it got botched somehow.
- client: the <task> debug flag enables suspend/resume messages
    for both CPU and GPU.
    Previously CPU messages were always shown,
    and GPU messages were shown if <cpu_sched_debug> was set.
- client: fix bug where reschedule wasn't being done on GPU suspend or resume.
2013-03-05 14:05:04 +01:00
Charlie Fenton bc69fe301d Restore changes lost due to GIT confusion 2013-03-04 17:01:36 +01:00
Rom Walton 516eff60b0 - client: Hook up the XML portion of the Intel GPU detection code so
the server scheduler knows about it.
    - client: Print out the peak flops for the Intel GPU, the regular
        OpenCL descriptions do not show peak flops.
2013-03-04 15:30:03 +01:00
Charlie Fenton ce87ec9848 OpenCL: First pass at adding support for Intel Ivy Bridge GPUs 2013-03-04 15:23:39 +01:00
David Anderson 6391a8c401 - remote job submission: show 20 batches, with link to show all
- XML parser: make low-level functions inline, in an attempt
    (unsuccessful, as far as I can tell) to boost performance
2013-03-01 16:26:08 +01:00
David Anderson b2a4cd4d91 svn path=/trunk/boinc/; revision=25691 2012-05-18 17:38:16 +00:00
David Anderson 0f3491baa7 - client: add <suspend_debug> log flag
svn path=/trunk/boinc/; revision=25585
2012-04-20 17:46:27 +00:00
David Anderson c34093e374 - web: don't show account keys on account page;
rewrite the page explaining and showing account keys.
- client: remove <std_debug> log flag
- client: remove <zero_debts> config option


svn path=/trunk/boinc/; revision=25581
2012-04-19 07:36:47 +00:00
David Anderson d2cf999563 - client: on startup, check file size as well as existence
- client: add <async_file_debug> log flag
- client: do decompress (both sync and async) to a temp file,
    then rename
- client: if a file's status is VERIFY_PENDING on startup,
    set it to NOT_PRESENT; that will trigger a verify
- client: do async copy only if size is above threshold


svn path=/trunk/boinc/; revision=25222
2012-02-09 00:47:04 +00:00
David Anderson bba4ce24ce - client: compute projects' disk share (based on resource share).
Report it (along with disk usage) in scheduler request messages.
    This will allow the scheduler to send file-delete commands
    if the project is using more than its share.
- client: add <disk_usage_debug> log flag
- create_work: add --help, show --command_line option


svn path=/trunk/boinc/; revision=24968
2012-01-02 05:53:42 +00:00
David Anderson a7e7da6bff - client: show error messages (as notices) when get an error
parsing cc_config.xml
- client: if an <exclude_cpu> element in cc_config.xml
    specifies a nonexistent app, show an error msg with
    a list of existing app names
- web: increase the default mem limit from 64MB to 256MB
    TODO: change user_hosts.php to show N at a time


svn path=/trunk/boinc/; revision=24593
2011-11-14 23:31:12 +00:00
David Anderson a4f09b9c1b - intermediate checkin so that I can edit on Unix
svn path=/trunk/boinc/; revision=24592
2011-11-14 23:05:42 +00:00
David Anderson b95ac02c5b - client: change the way project priorities are computed,
so that they do what they're supposed to
    (i.e. enforce resource shares)
- client: change log flag <debt_debug> to <priority_debug>
- client simulator: update REC even with large delta-t.
- client simulator: handle "no new work" apps correctly


svn path=/trunk/boinc/; revision=24429
2011-10-19 06:37:03 +00:00