[Pkg-varnish-devel] Bug#795359: varnish: invoke-rc.d reload failed in logrotate for varnishlog/varnishncsa if they don't running
Romain Dessort (Evolix)
rdessort at evolix.fr
Thu Aug 13 10:15:44 UTC 2015
Package: varnish
Version: 4.0.2-1
Severity: minor
Tags: patch
Hello,
If varnishlog/varnishncsa daemons are not launched (the default after
installing Varnish), logrotate output the following errors when trying to run
invoke-rc.d reload:
/etc/cron.daily/logrotate:
Job for varnishlog.service failed. See 'systemctl status varnishlog.service' and 'journalctl -xn' for details.
invoke-rc.d: initscript varnishlog, action "reload" failed.
error: error running non-shared postrotate script for /var/log/varnish/varnish.log of '/var/log/varnish/varnish.log '
Job for varnishncsa.service failed. See 'systemctl status varnishncsa.service' and 'journalctl -xn' for details.
invoke-rc.d: initscript varnishncsa, action "reload" failed.
error: error running non-shared postrotate script for /var/log/varnish/varnishncsa.log of '/var/log/varnish/varnishncsa.log '
run-parts: /etc/cron.daily/logrotate exited with return code 1
Output of systemctl status:
# systemctl status varnishlog.service
● varnishlog.service - Varnish HTTP accelerator log daemon
Loaded: loaded (/lib/systemd/system/varnishlog.service; enabled)
Active: failed (Result: exit-code) since Fri 2015-07-31 15:41:12 CEST; 1 weeks 5 days ago
Process: 1062 ExecStart=/usr/bin/varnishlog -a -w /var/log/varnish/varnish.log (code=exited, status=1/FAILURE)
Main PID: 1062 (code=exited, status=1/FAILURE)
Aug 10 06:18:02 lb02 systemd[1]: Unit varnishlog.service cannot be reloaded because it is inactive.
Aug 11 06:18:02 lb02 systemd[1]: Unit varnishlog.service cannot be reloaded because it is inactive.
Aug 12 06:18:02 lb02 systemd[1]: Unit varnishlog.service cannot be reloaded because it is inactive.
Aug 13 06:18:02 lb02 systemd[1]: Unit varnishlog.service cannot be reloaded because it is inactive.
Aug 13 12:04:26 lb02 systemd[1]: Unit varnishlog.service cannot be reloaded because it is inactive.
Output of journalctl -xn:
# journalctl -xn
[...]
Aug 13 12:04:26 lb02 systemd[1]: Unit varnishlog.service cannot be reloaded because it is inactive.
The attached patch check if services are actives before reloading them.
-- System Information:
Debian Release: 8.1
Architecture: amd64 (x86_64)
Kernel: Linux 3.16.0-4-amd64 (SMP w/2 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
Versions of packages varnish depends on:
ii adduser 3.113+nmu3
ii gcc 4:4.9.2-2
ii init-system-helpers 1.22
ii libc6 2.19-18
ii libc6-dev [libc-dev] 2.19-18
ii libedit2 3.1-20140620-2
ii libjemalloc1 3.6.0-3
ii libncurses5 5.9+20140913-1+b1
ii libpcre3 2:8.35-3.3
ii libtinfo5 5.9+20140913-1+b1
ii libvarnishapi1 4.0.2-1
varnish recommends no packages.
Versions of packages varnish suggests:
pn varnish-doc <none>
-- Configuration Files:
/etc/logrotate.d/varnish changed [not included]
/etc/varnish/default.vcl changed [not included]
-- debconf-show failed
--
Romain Dessort <rdessort at evolix.fr> GnuPG: 3072D/724BC532
Evolix − Hébergement et Infogérance Open Source http://www.evolix.fr/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: logrotate-varnish.patch
Type: application/octet-stream
Size: 599 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-varnish-devel/attachments/20150813/45b7730b/attachment.obj>
More information about the Pkg-varnish-devel
mailing list