[Bug 1563854] Re: update-notifier updates-available does not reset after dpkg run
Launchpad Bug Tracker
1563854 at bugs.launchpad.net
Tue Apr 5 07:47:38 UTC 2016
This bug was fixed in the package update-notifier - 3.167
---------------
update-notifier (3.167) xenial; urgency=medium
* Use mktemp -p in the target directory to avoid a cross-filesystem move.
* Also update motd if the dpkg status database has changed (LP: #1563854)
-- Adam Conrad <adconrad at ubuntu.com> Mon, 04 Apr 2016 15:22:20 -0600
** Changed in: update-notifier (Ubuntu)
Status: Confirmed => Fix Released
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to update-notifier in Ubuntu.
https://bugs.launchpad.net/bugs/1563854
Title:
update-notifier updates-available does not reset after dpkg run
Status in update-notifier package in Ubuntu:
Fix Released
Bug description:
From /etc/apt/apt.conf.d/99update-notifier the script /usr/lib/update-
notifier/update-motd-updates-available is started on a successful
"apt-get update" run. It will update /var/lib/update-notifier/updates-
available with the number of new packages that are installable (and
this is inserted into the dynamic motd which is shown on every login).
In the past /var/lib/update-notifier/updates-available was replaced by
an empty line from the Dpkg::post-invoke hook. This is missing in
Xenial, so motd will incorrectly claim to have installable packages
until there are again new ones after a updating the apt cache.
Delta in /etc/apt/apt.conf.d/99update-notifier:
-DPkg::Post-Invoke {"if [ -d /var/lib/update-notifier ]; then touch /var/lib/update-notifier/dpkg-run-stamp; fi; if [ -e /var/lib/update-notifier/updates-available ]; then echo > /var/lib/update-notifier/updates-available; fi "; };
+DPkg::Post-Invoke {"if [ -d /var/lib/update-notifier ]; then touch /var/lib/update-notifier/dpkg-run-stamp; fi";};
+APT::Update::Post-Invoke-Success {"/usr/lib/update-notifier/update-motd-updates-available 2>/dev/null || true";};
It looks like before the file was re-created by update-motd on every
login. And maybe while moving this to post-apt-get-update the reset
was dropped.
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/update-notifier/+bug/1563854/+subscriptions
More information about the foundations-bugs
mailing list