Your message dated Tue, 01 Apr 2014 19:03:27 +0200
with message-id <1427149.K8XOYv88lj@gyllingar>
and subject line Re: Bug#740380: logrotate warnings when running under systemd
has caused the Debian Bug report #740380,
regarding logrotate warnings when running under systemd
to be marked as done.
This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.
(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)
--
740380: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=740380
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: cups
Version: 1.7.1-7
Severity: normal
The logrotate script use a pre-start script to stop the cups service and
a post-rotate script to start cups again.
Under systemd this leads to a warning, since the socket and path are still
active and could lead to having the service activated on-demand.
# invoke-rc.d cups stop
Warning: Stopping cups.service, but it can still be activated by:
cups.socket
cups.path
My suggestion would be to use a single post-rotate script + restart.
As cups will still have the file descriptor open, you should use the
delaycompress option, so cups can continue to write to foo.1.log
My suggestion would be something like:
diff --git a/logrotate.d/cups-daemon b/logrotate.d/cups-daemon
index d96e11d..09b7145 100644
--- a/logrotate.d/cups-daemon
+++ b/logrotate.d/cups-daemon
@@ -3,20 +3,10 @@
missingok
rotate 7
sharedscripts
- prerotate
- if [ -e /var/run/cups/cupsd.pid ]; then
- invoke-rc.d --quiet cups stop > /dev/null
- touch /var/run/cups/cupsd.stopped
- fi
- endscript
postrotate
- if [ -e /var/run/cups/cupsd.stopped ]; then
- rm /var/run/cups/cupsd.stopped
- invoke-rc.d --quiet cups start > /dev/null
- sleep 10
- fi
+ invoke-rc.d --quiet cups restart > /dev/null
endscript
- compress
+ delaycompress
notifempty
create
}
Since the "sleep 10" didn't make any sense to me, I removed that as well.
-- System Information:
Debian Release: jessie/sid
APT prefers unstable
APT policy: (500, 'unstable'), (200, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 3.13-1-amd64 (SMP w/4 CPU cores)
Locale: LANG=de_DE.utf8, LC_CTYPE=de_DE.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Versions of packages cups depends on:
ii cups-client 1.7.1-7
ii cups-common 1.7.1-7
ii cups-core-drivers 1.7.1-7
ii cups-daemon 1.7.1-7
ii cups-filters 1.0.46-1
ii cups-ppdc 1.7.1-7
ii cups-server-common 1.7.1-7
ii debconf [debconf-2.0] 1.5.52
ii ghostscript 9.05~dfsg-8+b1
ii libavahi-client3 0.6.31-4
ii libavahi-common3 0.6.31-4
ii libc-bin 2.18-3
ii libc6 2.18-3
ii libcups2 1.7.1-7
ii libcupscgi1 1.7.1-7
ii libcupsimage2 1.7.1-7
ii libcupsmime1 1.7.1-7
ii libcupsppdc1 1.7.1-7
ii libgcc1 1:4.8.2-16
ii libstdc++6 4.8.2-16
ii libusb-1.0-0 2:1.0.17-1+b1
ii lsb-base 4.1+Debian12
ii poppler-utils 0.22.5-4
ii procps 1:3.3.9-4
Versions of packages cups recommends:
ii avahi-daemon 0.6.31-4
ii colord 1.0.6-1
ii cups-filters [ghostscript-cups] 1.0.46-1
ii printer-driver-gutenprint 5.2.9-1
Versions of packages cups suggests:
ii cups-bsd 1.7.1-7
pn cups-pdf <none>
ii foomatic-db 20140106-1
pn hplip <none>
pn printer-driver-hpcups <none>
ii smbclient 2:4.1.5+dfsg-1
ii udev 204-7
-- debconf information excluded
--- End Message ---
--- Begin Message ---
Version: 1.7.1-9
Le jeudi, 6 mars 2014 14.58:46, vous avez écrit :
> I have not yet seen the new version in unstable. Of course it looks
> like it should work - unless cups actually logs messages during the
> logrotate action...
This is now fixed as of 1.7.1-9.
Cheers,
OdyX
signature.asc
Description: This is a digitally signed message part.
--- End Message ---