[Bug 1200044] [NEW] update-motd-updates-available wastes 1 second on every login by forking hundreds of /usr/bin/stat

Anders Kaseorg andersk at mit.edu
Thu Jul 11 01:45:38 UTC 2013


Public bug reported:

The /usr/lib/update-notifier/update-motd-updates-available script
executed on console logins is painfully slow, taking almost a second to
run.  Debugging reveals that this is because it forks /usr/bin/stat
hundreds of times.

The entire NEED_UPDATE_CHECK logic can be replaced with a single call to
find -newer, which speeds up the script by a factor of 20.

** Affects: update-notifier (Ubuntu)
     Importance: Undecided
         Status: New

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

Title:
  update-motd-updates-available wastes 1 second on every login by
  forking hundreds of /usr/bin/stat

Status in “update-notifier” package in Ubuntu:
  New

Bug description:
  The /usr/lib/update-notifier/update-motd-updates-available script
  executed on console logins is painfully slow, taking almost a second
  to run.  Debugging reveals that this is because it forks /usr/bin/stat
  hundreds of times.

  The entire NEED_UPDATE_CHECK logic can be replaced with a single call
  to find -newer, which speeds up the script by a factor of 20.

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




More information about the foundations-bugs mailing list