]> granicus.if.org Git - vnstat/commitdiff
increase example systemd service restart delay from default 100ms to 2s, configure...
authorTeemu Toivola <git@humdi.net>
Mon, 6 May 2019 15:44:21 +0000 (18:44 +0300)
committerTeemu Toivola <git@humdi.net>
Mon, 6 May 2019 21:28:06 +0000 (00:28 +0300)
CHANGES
examples/systemd/vnstat.service

diff --git a/CHANGES b/CHANGES
index b5207fa9fe96a5720f8b77078de47386c0996734..83e39d7147181d26150fccf21ba47626c0e7896f 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -3,6 +3,9 @@
    - Traffic rate wasn't being shown for the last entry of most lists during
      the first update of the next period (first SaveInterval minutes of each
      new hour, day, month and year)
+   - Systemd example service file could result in database file write issues
+     if the used systemd version supported ProtectSystem=strict but didn't
+     support StateDirectory (issue seen at least with systemd 232 in Debian 9)
 
 
 2.2 / 28-Apr-2018
index 9a399944d7ece434f3855794f4d2d7f8d59320b0..104082e0fb262196610ed804442fc32c327fa4e3 100644 (file)
@@ -2,14 +2,18 @@
 Description=vnStat network traffic monitor
 Documentation=man:vnstatd(1) man:vnstat(1) man:vnstat.conf(5)
 After=network.target
+StartLimitIntervalSec=20
+StartLimitBurst=4
 
 [Service]
 ExecStart=/usr/sbin/vnstatd -n
 ExecReload=/bin/kill -HUP $MAINPID
 Restart=on-failure
+RestartSec=2
 
 # Hardening
 ProtectSystem=strict
+ReadWritePaths=/var/lib
 StateDirectory=vnstat
 PrivateDevices=yes
 ProtectKernelTunables=yes