mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-01-10 03:47:29 -03:00
Merge #16569: Increase init file stop timeout
7fb7acfc20
Set init stop timeout to 10 min (setpill) Pull request description: `bitcoind` can take a long time to flush its db cache to disk upon shutdown. Systemd sends a `SIGKILL` after a timeout, causing unclean shutdowns and triggering a long "Rolling forward" at the next startup. Disabling the timeout should prevent this from happening, and does not break systemd's `restart` logic. Addresses #13736. ACKs for top commit: instagibbs: utACK7fb7acfc20
Tree-SHA512: 16e0ce5a9ecf0628f8d93d68db3f5a78ab36021d9bede05a90c84f144db2e87e17707a6eb910cb7c018c265ce2c81d43de2988bd79e4a2d8554515db8fb5aa36
This commit is contained in:
commit
99cebc922c
4 changed files with 4 additions and 3 deletions
|
@ -16,7 +16,7 @@ expect fork
|
||||||
|
|
||||||
respawn
|
respawn
|
||||||
respawn limit 5 120
|
respawn limit 5 120
|
||||||
kill timeout 60
|
kill timeout 600
|
||||||
|
|
||||||
pre-start script
|
pre-start script
|
||||||
# this will catch non-existent config files
|
# this will catch non-existent config files
|
||||||
|
|
|
@ -39,7 +39,7 @@ start() {
|
||||||
|
|
||||||
stop() {
|
stop() {
|
||||||
echo -n $"Stopping $prog: "
|
echo -n $"Stopping $prog: "
|
||||||
killproc $prog
|
killproc $prog -t600
|
||||||
RETVAL=$?
|
RETVAL=$?
|
||||||
echo
|
echo
|
||||||
[ $RETVAL -eq 0 ] && rm -f $lockfile
|
[ $RETVAL -eq 0 ] && rm -f $lockfile
|
||||||
|
|
|
@ -30,4 +30,4 @@
|
||||||
# Note that this will be mapped as argument to start-stop-daemon's
|
# Note that this will be mapped as argument to start-stop-daemon's
|
||||||
# '--retry' option, which means you can specify a retry schedule
|
# '--retry' option, which means you can specify a retry schedule
|
||||||
# here. For more information see man 8 start-stop-daemon.
|
# here. For more information see man 8 start-stop-daemon.
|
||||||
BITCOIND_SIGTERM_TIMEOUT=60
|
BITCOIND_SIGTERM_TIMEOUT=600
|
||||||
|
|
|
@ -29,6 +29,7 @@ ExecStartPre=/bin/chgrp bitcoin /etc/bitcoin
|
||||||
Type=forking
|
Type=forking
|
||||||
PIDFile=/run/bitcoind/bitcoind.pid
|
PIDFile=/run/bitcoind/bitcoind.pid
|
||||||
Restart=on-failure
|
Restart=on-failure
|
||||||
|
TimeoutStopSec=600
|
||||||
|
|
||||||
# Directory creation and permissions
|
# Directory creation and permissions
|
||||||
####################################
|
####################################
|
||||||
|
|
Loading…
Reference in a new issue