kodi: give kodi enough time to properly shut down

The current stop timeout of 5 seconds is way too low and
leads to systemd frequently killing kodi while it's still
shutting down. This is really bad since it can potentially
lead to corrupted files or databases and should be avoided
at all costs.

eg plain kodi 18.4 setup with only pvr.hts installed takes
about 6 seconds to stop on RPi4.

Increase the stop timeout to 30 seconds to allow proper shutdown
on slower systems.

While that is still a lot lower than the 90 seconds
systemd default it should both be enough for very slow systems
and also for us and users to notice kodi issues - in which case
those issues have to be investigated.

Signed-off-by: Matthias Reichl <hias@horus.com>
This commit is contained in:
Matthias Reichl 2019-09-16 14:16:16 +02:00
parent 536a2d0014
commit 7cfe729d29

View File

@ -18,7 +18,7 @@ ExecStartPre=-/usr/lib/kodi/kodi-config
ExecStart=/usr/lib/kodi/kodi.sh --standalone -fs $KODI_ARGS $KODI_DEBUG
ExecStop=/bin/kill -TERM $MAINPID
ExecStopPost=-/usr/lib/kodi/kodi-safe-mode
TimeoutStopSec=5
TimeoutStopSec=30
Restart=always
RestartSec=2
StartLimitInterval=0