Unattended Upgrades

If none of the more specific forums is the right place to ask

Unattended Upgrades

Postby cfb » 2018-03-07 18:10

As far as I can tell, unattended upgrades have been implemented i Debian 9 (Stretch). I am not sure, if it has always been like that in Stretch or is the result of some upgrade along the way. I have a number of Debian 9 (xfce) installations and they all set up like the following.
In "/etc/apt/apt.conf.d/20auto-upgrades" I see these lines:
Code: Select all
APT::Periodic::Update-Package-Lists "1";
APT::Periodic::Unattended-Upgrade "1";.

and in "/etc/apt/apt.conf.d/50unattended-upgrades" this (commented out lines removed):
Code: Select all
Unattended-Upgrade::Origins-Pattern {
        "origin=Debian,codename=${distro_codename},label=Debian-Security";
};

As I understand it, these settings mean that "debian-security" upgrades are done automatically and unattended.
Can you confirm my findings?
cfb
 
Posts: 28
Joined: 2017-01-08 16:39

Re: Unattended Upgrades

Postby cfb » 2018-03-08 08:18

From my OP, it may not have been entirely clear that what I meant to say was that unattended upgrades are now the default in Debian 9. It may have been mentioned somewhere, but I have not seen it.
You can turn it off with this command:
Code: Select all
# dpkg-reconfigure -plow unattended-upgrades

More info here: https://wiki.debian.org/UnattendedUpgrades
cfb
 
Posts: 28
Joined: 2017-01-08 16:39

Re: Unattended Upgrades

Postby Dai_trying » 2018-03-08 08:23

I don't like to have my system updated without my knowledge and always change /etc/apt/apt.conf.d/20auto-upgrades to read

Code: Select all
APT::Periodic::Update-Package-Lists "1";
APT::Periodic::Unattended-Upgrade "0";.

That way apt will update the database and my updater will notify me of any available updates and I can decide to install them (or not).
Dai_trying
 
Posts: 531
Joined: 2016-01-07 12:25

Re: Unattended Upgrades

Postby None1975 » 2018-03-08 14:35

From Debian wiki
As of Debian 9 (Stretch) both the unattended-upgrades and apt-listchanges packages are installed by default and upgrades are enabled with the GNOME desktop.
OS: Debian 9.4 / WM: Xmonad
Debian Wiki | DontBreakDebian, My config files in github
Linux User #607425
User avatar
None1975
 
Posts: 625
Joined: 2015-11-29 18:23
Location: Lithuania, Vilnius

Re: Unattended Upgrades

Postby cfb » 2018-03-08 15:44

...upgrades are enabled with the GNOME desktop.

I had already read that in the wiki.
However, I am, as I wrote in the OP, using Xfce, and they are still enabled. That is what I find surprising.
cfb
 
Posts: 28
Joined: 2017-01-08 16:39

Re: Unattended Upgrades

Postby debiman » 2018-03-10 11:33

how did you install your current debian and how did you install xfce?
User avatar
debiman
 
Posts: 2790
Joined: 2013-03-12 07:18

Re: Unattended Upgrades

Postby cfb » 2018-03-11 06:57

Following "debiman's" question, I installed Debian a couple of times in QEMU/KVM: A base Debian (without DE) and Debian with Xfce. In both cases unattended upgrades were not enabled. In fact, package "unattended-upgrades" was not even installed.

Then, clearly, I must have installed the package myself at some point in the past.

Digging through my APT history log files, I have now found out, how unattended upgrades got enabled on my systems:

A few months ago, I was trying out Docker containers, and following the installation instructions on the Docker site, I installed package "software-properties-common", which provides command "add-apt-repository". Well, package "software-properties-common" depends on package "python3-software-properties" which again recommends package "unattended-upgrades". So, package "unattended-upgrades" got installed and unattended upgrades of security fixes got enabled.

Package "software-properties-common" was probably unnecessary, as I believe it was only used for adding the Docker repository to "/etc/apt/sources.list". I might as well have done it by hand.
cfb
 
Posts: 28
Joined: 2017-01-08 16:39

Re: Unattended Upgrades

Postby debiman » 2018-03-11 07:28

install-recommends are tricky.
sometimes they make sense, but often they don't.
i keep them disabled.
User avatar
debiman
 
Posts: 2790
Joined: 2013-03-12 07:18


Return to General Questions

Who is online

Users browsing this forum: cooler01, HankB and 5 guests

fashionable