Unable to stop BOINC from running as a service upon system boot

Message boards : Questions and problems : Unable to stop BOINC from running as a service upon system boot
Message board moderation

To post messages, you must log in.

AuthorMessage
anony

Send message
Joined: 26 Mar 16
Posts: 6
United States
Message 85420 - Posted: 25 Mar 2018, 22:13:35 UTC

I'm currently running BOINC version 7.6.31 on Linux Mint 18.3.

The BOINC service runs at boot before any user is logged in, in spite of taking certain actions to stop this. I have verified there are no entries in the Startup Applications settings page. I have also set the /etc/default/boinc-client config value to 0 to disable the init script. I even marked all the boinc packages for complete removal, and reinstalled, but still have the same problem.

Any suggestions? I'd like to have more control over when BOINC runs. Thanks.
ID: 85420 · Report as offensive
MarkJ
Volunteer tester
Help desk expert

Send message
Joined: 5 Mar 08
Posts: 272
Australia
Message 85423 - Posted: 26 Mar 2018, 7:26:38 UTC

You don’t really get any control over the service running.

What you can do is have it not compute through the various settings, like when in use or certain times of the day. You can even give a start delay if you just want to get through the boot sequence. If you really want to micro manage you can even set it to no new tasks and suspend what’s running. The service itself doesn’t use much cpu or memory on its own.

What is your reason for not wanting it to run at start up?
MarkJ
ID: 85423 · Report as offensive
anony

Send message
Joined: 26 Mar 16
Posts: 6
United States
Message 85432 - Posted: 27 Mar 2018, 1:18:42 UTC - in response to Message 85423.  
Last modified: 27 Mar 2018, 1:19:46 UTC

You don’t really get any control over the service running.

What you can do is have it not compute through the various settings, like when in use or certain times of the day. You can even give a start delay if you just want to get through the boot sequence. If you really want to micro manage you can even set it to no new tasks and suspend what’s running. The service itself doesn’t use much cpu or memory on its own.

What is your reason for not wanting it to run at start up?


It seems pretty strange for there to be no option to control whether or not BOINC will run tasks upon booting. In case I wasn't clear, I was following this guide, which indicated I can actually control whether or not the service runs at boot. https://boinc.berkeley.edu/wiki/Installing_BOINC_on_Ubuntu

What happens right now is that BOINC will begin crunching before any user logs in. This has two undesirable effects: First, I want to be able to log in and have all other parts of the OS loaded before BOINC takes a hold of the CPU. In my mind, this can only make logging in to my user account take longer. I'd also like to be able to set up a delayed launch via Startup Applications after 2 minutes or so, after I'm sure everything else has gone about loading.

The second concern is that when logging in to a different user account, BOINC runs regardless. If one opens the activity monitor in the alternate account, they can see the CPU is fully loaded, but yet there will be no visible tasks shown. It would not be fair to other users to have this running and taking up resources, without them being able to do anything about it.
ID: 85432 · Report as offensive
MarkJ
Volunteer tester
Help desk expert

Send message
Joined: 5 Mar 08
Posts: 272
Australia
Message 85435 - Posted: 27 Mar 2018, 10:47:32 UTC
Last modified: 27 Mar 2018, 10:54:49 UTC

If you want to have BOINC wait after starting up edit the config file:
sudo nano /var/lib/boinc-client/cc_config.xml
and paste the following in:
<cc_config>
    <options>
        <start_delay>120</start_delay>
    </options>
</cc_config>

It will read it the next time it starts up. That says we want a 120 second delay before computations start.

There are various other preferences you can set via the manager (not to mention seeing what its actually doing) to control it. BOINC runs tasks at a low priority anyway (nice level of 19) so I don't think you'll find it interfering, but you can tell it via the option settings in the manager that you don't want it computing while the computer is being used and you could also tell it to only use a percentage of the CPU cores. I think you should try it first and see if you notice any impact while you use the machine and adjust if needed.
MarkJ
ID: 85435 · Report as offensive
anony

Send message
Joined: 26 Mar 16
Posts: 6
United States
Message 85472 - Posted: 28 Mar 2018, 2:21:35 UTC - in response to Message 85435.  

If you want to have BOINC wait after starting up edit the config file:
sudo nano /var/lib/boinc-client/cc_config.xml
and paste the following in:
<cc_config>
    <options>
        <start_delay>120</start_delay>
    </options>
</cc_config>

It will read it the next time it starts up. That says we want a 120 second delay before computations start.

There are various other preferences you can set via the manager (not to mention seeing what its actually doing) to control it. BOINC runs tasks at a low priority anyway (nice level of 19) so I don't think you'll find it interfering, but you can tell it via the option settings in the manager that you don't want it computing while the computer is being used and you could also tell it to only use a percentage of the CPU cores. I think you should try it first and see if you notice any impact while you use the machine and adjust if needed.


Thanks for the help. Actually I went through the boinc manager settings pretty thoroughly. I have it set up to crunch at maximum performance even while the computer is being used, so modifying those is out of the question. I just specifically want to disable, not delay the start of the boinc client, as performance in other user accounts is still a concern.

If this is not yet a consideration for developers, I think it should be. One should absolutely have control over whether or not boinc runs at boot.
ID: 85472 · Report as offensive
mmonnin

Send message
Joined: 1 Jul 16
Posts: 146
United States
Message 85536 - Posted: 29 Mar 2018, 13:37:43 UTC

I have the same issue when running GPU tasks with Mint 17 as BOINC started before the drivers loaded so no usable GPUs were recognized.. I just ended up restarting the client so that GPU tasks could run. A start delay would make that much simpler.
ID: 85536 · Report as offensive
Juha
Volunteer developer
Volunteer tester
Help desk expert

Send message
Joined: 20 Nov 12
Posts: 801
Finland
Message 85743 - Posted: 5 Apr 2018, 20:51:51 UTC - in response to Message 85472.  
Last modified: 5 Apr 2018, 20:56:43 UTC

I just specifically want to disable, not delay the start of the boinc client, as performance in other user accounts is still a concern.

If this is not yet a consideration for developers, I think it should be. One should absolutely have control over whether or not boinc runs at boot.


When you install BOINC from distro repository it is installed as a service. You then have to use the methods the OS provides for controlling services. Mint 18 is probably a systemd distro in which case the method is "sudo systemctl <command> boinc-client". systemctl man page explains the commands. Main commands of interest are below.

  • status : tells whether the client is running or not and some other information
  • start : starts the client if it's not running already
  • stop : stops the client if it's running
  • enable : sets the service to start automatically at system boot
  • disable : sets the service to not start automatically



If you prevent the client from starting at system boot you will have to start it yourself, Manager won't be able to do it.

systemd supports user services. I don't know if they would be useful here.

You could add a PreExec step that sets computing to suspended state (by editing client_state.xml) before the client is started. This way you don't have to start the client yourself and resource usage will be minimal until computing is allowed.

Or you could simply not run the client as service. Then the client would run under your user account and when you are logged in. If you run the client under your user account then Manager can start the client. You'd have to have client's data directory somewhere where your user account has full permissions. You'd also need to change Manager's menu entry so that it starts the client in right directory.

ID: 85743 · Report as offensive

Message boards : Questions and problems : Unable to stop BOINC from running as a service upon system boot

Copyright © 2024 University of California.
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation.