unattended-upgrades.service ignores (changes in) /etc/apt/preferences.d/ files

Bug #1734285 reported by Richard Arends
14
This bug affects 3 people
Affects Status Importance Assigned to Milestone
unattended-upgrades (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

unattended-upgrades.service ignores (changes in) /etc/apt/preferences.d/ files that are done after the service has started.

For example we 'pin' firefox on to a specific version and if a configuration file is placed after the service is started, the pinning is ignored. In our sitation that results in a newer firefox then we want at this moment.

We run Ubuntu on 2000+ workstations and our users often start a workstation and let it run for days/weeks before rebooting and thus restarting the service unattended-upgrades again.

I did not test if changes in other apt files are ignored also.

Revision history for this message
Balint Reczey (rbalint) wrote :

Files in /etc/apt/preferences.d/ are read when unattended-upgrade is run and not when u-u.service is started thus it is safe to assume that configuration changes take place without restarting u-u.service.
On the other hand there are cases when u-u does not respect pinning like the one reported here: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=838920
Are all the repositories trusted on the affected systems?

Changed in unattended-upgrades (Ubuntu):
status: New → Incomplete
Revision history for this message
Richard Arends (l-lauuchpad-s) wrote :

Hi Reczey,

Thanks for looking at this bug report. We observed that configuration changes on pinning files are only effective after restarting u-u.service. All the repos that we use, are trusted.

With regards,
Richard.

Balint Reczey (rbalint)
Changed in unattended-upgrades (Ubuntu):
status: Incomplete → Confirmed
Revision history for this message
Borim (borim) wrote :

I have the same problem, unattended-upgrades ignores files under /etc/apt/preferences.d/*, but also after restarting the PC. The result is that unattended-upgrades breaks regularly my system :(

To fix this I have to run `apt upgrade` after unattended-upgrades updated programs to problematic versions.

As a workaround I blacklisted these programs in unattended-upgrades config: /etc/apt/apt.conf.d/50unattended-upgrades

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.