Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 23 May 2017 23:30:57 +0100
From:      RW <rwmaillists@googlemail.com>
To:        freebsd-hackers@freebsd.org
Subject:   Re: anti-dog-piling and ntpd leap files
Message-ID:  <20170523233057.59cd2393@gumby.homeunix.com>
In-Reply-To: <CAOtMX2j-Do-hvOE5-oVXb2ygA=%2BzvT2zyrVgAbKD6jwP_VHFAQ@mail.gmail.com>
References:  <D8A7B030-8D3D-4C16-8DB0-73C0A305FE78@webweaving.org> <20170522125307.76c9de6d@gumby.homeunix.com> <1104C7A7-5893-4602-9E34-5C212D987DAE@webweaving.org> <CAOtMX2guiGNaoWd6cqCJiWEE8SLUp1%2B2q87LJ7otM5VfmmSXtA@mail.gmail.com> <20170522143102.70035d8d@gumby.homeunix.com> <CAOtMX2j-Do-hvOE5-oVXb2ygA=%2BzvT2zyrVgAbKD6jwP_VHFAQ@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, 22 May 2017 08:09:54 -0600
Alan Somers wrote:

> On Mon, May 22, 2017 at 7:31 AM, RW via freebsd-hackers
> <freebsd-hackers@freebsd.org> wrote:

> > That doesn't sound like a good idea. If they aren't backgrounded
> > they'll block the rest of periodic daily for up to an hour. Not
> > much of a problem on a server, but it would be when periodic is run
> > from anacron at boot time.  
> 
> Actually, there are already many periodic scripts from ports that
> include foreground sleeps, mostly notably 410.pkg-audit. 

I didn't know that and I think there is a POLA violation there because
if you run "time periodic daily" from a terminal there is no warning
that delays are being skipped. This happens in the new version too.

>  Do those
> cause problems for anacron?  I wouldn't think so, because anacron
> knows to restart a job that didn't complete the last time it was run.

It's more about knowing when they run. I have some local scripts that
aren't entirely atomic, nothing catastrophic would happen if they were
interrupted, but I'd rather they completed. I've been avoiding
shutting down during what I thought was a very narrow window, but
turns out to be 75 minutes wider than I thought.

Another thing is that periodic tasks can be I/O and CPU intensive and
some people may be good reason to get them out of the way at boot time,
rather than have them randomly kick-in.

The updated version is an improvement because the single delay can be
configured, but you have to know it's there.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20170523233057.59cd2393>