Bug#744753: anacron: Anacron not triggered when system resumes under systemd

Lennart Poettering lennart at poettering.net
Fri Jun 27 19:10:51 BST 2014


On Wed, 04.06.14 11:48, Sam Morris (sam at robots.org.uk) wrote:

> 
> On Tue, Jun 03, 2014 at 08:25:25PM +0200, Lennart Poettering wrote:
> > On Tue, 03.06.14 05:43, Michael Biebl (biebl at debian.org) wrote:
> > 
> > > Lennart, do you have better solution for such services which need to be
> > > restarted on suspend/resume?
> > 
> > Why would a service need something like this? This sounds systematically
> > flawed... I'd really try to focus on that and fix the software in question.
> 
> The service in question, when started, checks to see if any of its cron
> jobs haven't been run for a specified period, running them if they
> haven't, then exits. It's intended as a replacement for the
> daily/weekly/monthly cron jobs, which will not run if your computer is
> turned off when their time arrives.

Well, I know that much. But a service which needs to be restarted on
cases like this sounds wrong. Thats a hack really. The service should
just watch time changes and react correctly to that. i.e. use
TFD_TIMER_CANCEL_ON_SET. THis will report wallclock changes relative to
monotonic time, which is what you want to watch for this. All system
resumes will trigger this, of course.

Lennart

-- 
Lennart Poettering, Red Hat




More information about the Pkg-systemd-maintainers mailing list