[Bug 525674] Re: apt-check hangs, preventing login via SSH

ChristianEhrhardt 525674 at bugs.launchpad.net
Wed Oct 7 13:28:16 UTC 2015


Here the bigger, but more architecturally complete solution for
wily&upstream (which is actually identical at this time).

Summary:
- move the actual updating part out of the pam based trigger completely (avoids slowdown)
- pam based motd now only prints the cached info (if existing)
- hook into apt with APT::Update::Post-Invoke-Success to update the cached file (thanks mvo and pitti for that good IRC discussion)
- removed one level of indirection (apt hook -> stamp file -> on pam login check stamp -> update) to the more separate
  (apt hook -> update cached info) (on pam login -> print cached info)
- while the chance of a concurrent update is now (almost) impossible it keeps the atomic cache update and cleanup to be sure

It was working find in all my builds and tests on wily.
Attaching for review ...

** Patch removed: "Fix for wily"
   https://bugs.launchpad.net/ubuntu/+source/update-notifier/+bug/525674/+attachment/4486127/+files/wily_package.debdiff

** Patch removed: "Fix for upstream"
   https://bugs.launchpad.net/ubuntu/+source/update-notifier/+bug/525674/+attachment/4486128/+files/upstream_package.debdiff

-- 
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/525674

Title:
  apt-check hangs, preventing login via SSH

Status in update-notifier package in Ubuntu:
  Confirmed

Bug description:
  Binary package hint: update-notifier

  While investigating protracted hangs in the remote login process, I
  noticed that apt-check is called to update the list of available
  updates and print the number of updatable packages in the MOTD. As it
  so happens, apt-check often hangs in mid-update, which effectively
  prevents remote login via SSH from taking place.

  ProblemType: Bug
  Architecture: i386
  Date: Mon Feb 22 12:20:16 2010
  DistroRelease: Ubuntu 10.04
  Package: update-notifier-common 0.96
  PackageArchitecture: all
  ProcEnviron:
   LANGUAGE=fi_FI.UTF-8
   PATH=(custom, user)
   LANG=fi_FI.UTF-8
   SHELL=/bin/bash
  ProcVersionSignature: Ubuntu 2.6.32-14.20-generic
  SourcePackage: update-notifier
  Uname: Linux 2.6.32-14-generic i686

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/update-notifier/+bug/525674/+subscriptions



More information about the foundations-bugs mailing list