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

process priority flags don't work for wrapper tasks #3764

Closed IanSteveC closed 4 years ago

IanSteveC commented 4 years ago

Describe the bug setting process_priority_special doesn't seem to work on the wrapper tasks at GPUGRID. setting this flag to '2', the tasks still run at nice 19.

Steps To Reproduce

  1. set the process_priority and process_priority_special flags in the cc_config.xml
  2. observe no affect on wrapper gpu app tasks (GPUGRID)

Expected behavior with process_priority_special, I would expect that the nice values for the wrapper tasks would be reflective of my setting. setting a value of '2' should implement nice 0, etc.

System Information

The only project I run that uses wrappers is GPUGRID which uses a wrapper for their GPU applications, I don't know about other projects.

davidpanderson commented 4 years ago

The cc_config.xml flags control the priority of the wrapper, but not the priority of the actual (wrapped) application. Currently there's no way to set that, AFAIK.

RichardHaselgrove commented 4 years ago

The wrapper app documentation https://boinc.berkeley.edu/trac/wiki/WrapperApp says that the project can set the priority via the job template file (job.xml.32charID, in this case). GPUGrid have either chosen not to use this, not been aware of the tag, or not been aware of the normal priority level for GPU apps under BOINC.

Under Windows, I normally run Process Lasso for other reasons, so it is trivial to add this rule.

Under Linux, I have confirmed that a modified job.xml file is left untouched by the routine downloading of new task data: I have yet to test whether the file survives the integrity checking when BOINC restarts. That might require one of the normal protective techniques like making the file read-only.

RichardHaselgrove commented 4 years ago

The edited job.xml file does survive a restart under Linux, so that might be worth doing.

IanSteveC commented 4 years ago

I can manually set the priority in linux of the wrapped application with a script running looping schedtool commands.

Richard, are you proposing that BOINC be modified to edit the job.xml file to solve this issue on the BOINC side, or only as a client-side workaround?

IanSteveC commented 4 years ago

Also, I tried to edit the job.xml file to add in the flag, but BOINC overwrites this with a new file (erasing my edit). I was only able to force the change by setting job.xml to read-only and some sudo chattr +i action. I did verify that the priority change in the edited job.xml file takes effect once a new task starts

RichardHaselgrove commented 4 years ago

@davidpanderson did say "Currently there's no way to set that, AFAIK." (my emphasis). If he feels that there's an ongoing likelihood of project administrators making this sort of misconfiguration, he might think it's worth adding a client override. Or maybe it would be easier to put on training courses for new administrators?

IanSteveC commented 4 years ago

it could be implemented for BOINC to check the existence of the priority flag in the job.xml file of any project with a wrapper, and change it to reflect the user preference in cc_config, no? that's essentially what I'm doing manually, I just want BOINC to do for me.

davidpanderson commented 4 years ago

The right approach is for the client to pass the cc_config priority settings to the wrapper, which can then start the app with the appropriate priority. I'll do this, but it won't take effect until projects update their wrapper.

AenBleidd commented 4 years ago

Closed via #3948