unattended-upgrades not working on 9.10?

Josef Wolf jw at raven.inka.de
Fri Apr 2 17:13:15 UTC 2010


On Fri, Apr 02, 2010 at 08:08:49AM -0700, NoOp wrote:
> On 04/02/2010 06:15 AM, Josef Wolf wrote:
> > Hello,
> > 
> > I have installed the unattended-upgrades packages and configured apt to do
> > automatic upgrades:
> > 
> >    jw at raven:~ $ cat /etc/apt/apt.conf
> >    APT::Periodic::Enable 1;
> >    APT::Periodic::Update-Package-Lists 1;
> >    APT::Periodic::Download-Upgradeable-Packages 1;
> >    APT::Periodic::AutocleanInterval 1;
> >    APT::Periodic::Unattended-Upgrade 1;
> >    APT::Periodic::MaxAge 365;
> >    APT::Periodic::MaxSize 256;
> >    APT::Periodic::MinAge 60;
> >    DPkg::Pre-Invoke {"/bin/mount -o remount,exec /tmp; /bin/mount /boot";};
> >    DPkg::Post-Invoke {"/bin/mount -o remount /tmp; /bin/umount /boot";};
> 
> Perhaps this will help:
> https://help.ubuntu.com/community/AutomaticSecurityUpdates

Thanks for your reply, NoOp!

The instructions you mention seem to be outdated (refers to 7.10) and
inconsistent:

- What good are the APT::Periodic settings if I have to put
  "aptitude safe-upgrade" into crontab? safe-upgrade will work without
  APT::Periodic settings.

- What's the point of creating my own cron entry when there's
  /etc/cron.daily/apt that tells me that it will honor the APT::Periodic
  settings?

So I guess /etc/cron.daily/apt should do the work and I am not supposed to
set up my own cron entry for that. A little more investigation shows up this:

/etc/cron.daily/apt actually _tries_ to do the upgrades, as can be seen in
its stamp directory:

    jw at tm8371-u:~$ ls -l /var/lib/apt/periodic
    total 0
    -rw-r--r-- 1 root root 0 2010-04-02 07:50 autoclean-stamp
    -rw-r--r-- 1 root root 0 2010-04-02 07:50 download-upgradeable-stamp
    -rw-r--r-- 1 root root 0 2010-04-02 07:49 update-stamp
    -rw-r--r-- 1 root root 0 2010-04-02 07:49 update-success-stamp
    -rw-r--r-- 1 root root 0 2010-04-02 07:50 upgrade-stamp

When I run /usr/bin/unattended-upgrade (that's what the apt cron entry runs
in the end) manually, I get:

  jw at tm8371:~$ LANG=C unattended-upgrade -d
  Initial blacklisted packages: 
  Starting unattended upgrades script
  Allowed origins are: ["['Ubuntu', 'karmic-security']"]
  Checking: tzdata (["<Origin component:'main' archive:'karmic-updates'
  origin:'Ubuntu' label:'Ubuntu' site:'archive.ubuntu.com' isTrusted:True>"])
  Checking: devicekit-disks (["<Origin component:'main' archive:'karmic-updates'
  origin:'Ubuntu' label:'Ubuntu' site:'archive.ubuntu.com' isTrusted:True>"])
  pkgs that look like they should be upgraded: 
  Done downloading            
  blacklist: []
  InstCount=0 DelCount=0 BrokenCout=0
  No packages found that can be upgraded unattended

So it finds the tzdata and devicekit-disks packages, but it thinks they don't
need to be upgraded.

BTW: any pointers to information about the priority of the settings in
     /etc/apt/apt.conf and /etc/apt/apt.conf.d/* files?




More information about the ubuntu-users mailing list