On Sat, 4 Jul 2020 14:17:30 +1000, Doug Laidlaw wrote:
I run the BOINC client. Its .service file allows it 1.5 minutes to shut down. Observed time is about 1 minute. If I shut it down with
systemctl before rebooting, it takes the same length of time.
Naturally, that time is added to the total shutdown time. Without
BOINC, the computer shuts down as quickly as I would expect.
I don't think I can do anything about this,
But I suggest you can. I know nothing about BOINC, but if it were I,
I would send a sig term signal and see how long it takes to terminate.
I would be surprised if longer that 20 seconds.
Once I had a reasonable time I would create a drop-in file with the
desired timeout value.
For example I do not like the 300 second timeout for mysqld so I arbitrarily picked 150.
Anytime you want to create a drop-in file use;
systemctl edit whatever_unit_file_here
and just enter what you want changed in a given section.
Whatever you put in drop-in files override the same item in the unit file.
As an example you might do something like
systemctl edit boinc-client.service
and add something like
[Service]
# Give a reasonable amount of time for the client to start up/shut down TimeoutSec=150
I would then stop the service, run
systemctl --system daemon-reload
systemctl start boinc-client
systemctl status boinc-client
That should show you Drop-In: with the new directory and drop-in file.
I can recommend creating install and change scripts to automate
configuration of an install.
Personally I put xx__ in all my configuration file names where possible.
Makes it easy to do something like locate xx__ to find them.
Examples:
/etc/exports.d/xx__local.exports
/usr/lib/systemd/network/10_xx__enp3s0.network
At the moment I have
$ locate xx__ | grep -v /local/bin/ | wc -l
32
drop-in files.
--- MBSE BBS v1.0.7.17 (GNU/Linux-x86_64)
* Origin: A noiseless patient Spider (2:250/1@fidonet)