Re: /etc/cron.daily/apt hangs [deviated discussion]



On Tue, 2009-02-24 at 00:18 +0100, Markus Schönhaber wrote:

Daevid Vincent:

So when I expect all my cron.daily tasks to be running at a given time
in crontab, they're actually all delayed by some random amount. Since
it's name is alphabetically earlier than anything else in the directory,
this 'apt' holds up all the scripts below as they're not fired off in
threads. *sigh*

Hm, you're the first one I know of who expects jobs in cron.daily to be run
precisely at a given time.

I wouldn't say "precisely", however I don't expect some random delay
which looks like a hung task to muck up things on me.

In my understanding jobs in cron.daily are to be
run once a day - whenever that may be throughout the day. And since those jobs
are executed sequentially, it's pretty obvious that any delay in one job (be
it caused by a sleep like in the apt script, a slow network or something else)
will affect the execution time of all following jobs.

True.

If I want something to be executed precisely at a given time, I create a real
cron job for it.

Again. True.

"The random sleep was added to avoid that the big archive
servers/mirrors get hammered at exactly the same time when a lot of
machines are switched on, e.g. 9:00 in the morning. '

Who "switches on" a Unix box??! They normally are running 24/7 right?

Interesting that you ask this question in an Ubuntu mailing list. Since IMO
Ubuntu's main success is based on the fact that it provides an easy to set up
*desktop* Linux.

I've been using Linux since it was Slackware on an Amiga 3000 and came
on 14 floppies.

I've used RedHat, CentOS, Gentoo, and various others as my servers too.

To me, Ubuntu is just a "more supported" and "prettier UI" with less
hassle version of Linux. In another few years, a new contender will come
along that's even better I'm sure.

RedHat pissed me off with their dependency hell in RPMs years ago. And
then the whole split to Fedora was messy at the time.

I switched to Gentoo, but I've grown VERY tired of re-compiling all the
time when the H/W server died, I decided it was time to jump ship to
Ubuntu Server (with the GUI added later) (ironic that now, my new Ubuntu
server is 4 procs and 4GB RAM and could handle it very nicely I
suspect).

And my guess would be that many of those desktops might get switched off in the
evening and switched back on in the morning. At least, this doesn't seem too
unrealistic a guess to me.

Switching off/on a desktop is so bad for the hardware. It's better to
just leave them on. Especially any Unix flavor -- for exactly the
reasons we're discussing here. Crontabs need to be run. Having them all
"catchup" later (via anacron) is a kludge.

Moreover I think we can assume that the people operating the archive servers
know when the load is high and whether the load spikes form a pattern.

Fair enough.
--
ubuntu-users mailing list
ubuntu-users@xxxxxxxxxxxxxxxx
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users


Relevant Pages

  • Re: /etc/cron.daily/apt hangs [solved]
    ... you're the first one I know of who expects jobs in cron.daily to be run ... it caused by a sleep like in the apt script, a slow network or something else) ... will affect the execution time of all following jobs. ... Who "switches on" a Unix box??! ...
    (Ubuntu)
  • CUPS problem printing pictures is very slow
    ... all jobs) and everything is working very well, ... # Server name ... # Browse order (BrowseOrder) ... # Whether or not to use implicit classes. ...
    (Debian-User)
  • CUPS problem printing is slow
    ... all jobs) and everything is working very well, ... # Server name ... # Browse order (BrowseOrder) ... # Whether or not to use implicit classes. ...
    (Debian-User)
  • Re: strange problem with send() and recv()
    ... > I try to write a simple tcp based job queue server. ... > get commands from a client and store them in a queue. ... > The client can query the server about the jobs currently queued. ...
    (comp.lang.c)
  • Re: Very slow network browsing from W2K but not NT
    ... :> I assume the server is running in mixed mode and the NetBIOS over ... :> Are there Cisco switches involved and if not, ... :> it would help to know if using Cisco, how many switches involved and are ... :> portfast enabled on those ports, and hopefully not on trunk ports. ...
    (microsoft.public.win2000.networking)