Bug#770440: debian-policy: policy should mention systemd timers
Package: debian-policy
Severity: normal
Dear Maintainers,
I've seen that util-linux was the first package that started providing
a native systemd timer for fstrim, but this change got reverted.
> util-linux (2.25.2-3) unstable; urgency=medium
> * Ship fstrim timer/service units as examples only (Closes: #767194)
> - this works around #757891 and #767429 / #760168
> -- Andreas Henriksson <andreas@fatal.se> Thu, 06 Nov 2014 13:54:04 +0100
The policy should mention how to handle systemd native timers
to avoid these kind of bugs in the future;
when other packages will start shipping native timers.
Here is the spirit of this change:
+To maintaint compatability with SysV Init;
+packages that ships native timers must also ship corresponding
+crontabs. (/etc/cron.daily|weekly|monthly/) would remain unaffected.
+
+These cron jobs must then also ensure that systemd is not
+currently running to avoid duplicate execution.
+
+A canonical way to both ensure that systemd is not currently running
+and that package hasn't be removed would be:
+m h d m w user test -e /run/systemd/system || test -e /usr/bin/<var>pkg</var> && /usr/bin/<var>pkg</var>
Here is a more elaborate draft:
https://github.com/ajtowns/debian-init-policy/pull/6/files
Alexandre Detiste
-- System Information:
Distributor ID: Raspbian (--> this is not at all Raspbian specific)
Description: Raspbian GNU/Linux testing (jessie)
Release: testing
Codename: jessie
Architecture: armv6l
Kernel: Linux 3.12.28+ (PREEMPT)
Locale: LANG=fr_BE.UTF-8, LC_CTYPE=fr_BE.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Reply to: