PackageReporter kicks in during do-release-upgrade

Bug #1699179 reported by Dariusz Gadomski on 2017-06-20
16
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Landscape Client
Undecided
Unassigned
landscape-client (Ubuntu)
Medium
Andreas Hasenack
Trusty
Medium
Simon Poirier
Xenial
Medium
Simon Poirier
Artful
Medium
Unassigned
Bionic
Medium
Andreas Hasenack

Bug Description

[Impact]

 * This issue affects users of the release-upgrade feature of landscape.

 * Landscape package monitor would previously race during an upgrade
   and possibly grab apt locks, thus making the upgrade fail.

 * The fix adds checks during package operations to make sure a
   release upgrade is not in progresss.

[Test Case]

 * in /etc/landscape/client.conf , set "apt_update_interval=1800" and
   "log_level=debug" and restart the client.

 * Launch a release upgrade from landscape-server. Look for messages
   in the package-monitor logs stating "conditions not met"

[Regression Potential]

 * Unlikely, as this has already been released to newer ubuntu releases
   and is fairly well tested.

 * Any issue with related changes would likely only affect the client
   getting new package info, but won't affect other functionality.

[Original description]

Affected release: Ubuntu 14.04.5
Version of package: 14.12-0ubuntu5.14.04

Steps to reproduce:
1. Run do-release-upgrade to upgrade to 16.04.2.
2. Trigger the package-reporter to kick in while do-release-upgrade is working but not having the package database locked.
3. Package database is locked by package-reporter, do-release-upgrade fails to access it and exits.

Expected result:
Landscape detects that there's an release upgrade in progress and will wait for it to finish.

Actual result:
PackageReporter locks the apt database, do-release-upgrade cannot access it, exits with an error and may leave the system in an unusable state.

* Link to Dariusz's PR on GitHub:
https://github.com/CanonicalLtd/landscape-client/pull/14

Related branches

summary: - package-reporter kicks in during do-release-upgrade
+ PackageReporter kicks in during do-release-upgrade
description: updated
Changed in landscape-client (Ubuntu):
assignee: nobody → Dariusz Gadomski (dgadomski)
Eric Desrochers (slashd) on 2017-10-17
tags: added: sts sts-sru-needed
Eric Desrochers (slashd) on 2017-10-17
description: updated
Changed in landscape-client (Ubuntu Artful):
assignee: Dariusz Gadomski (dgadomski) → nobody
Eric Desrochers (slashd) on 2017-11-02
tags: added: sts-sponsor-slashd
Eric Desrochers (slashd) on 2017-11-02
tags: removed: sts-sponsor-slashd
Dariusz Gadomski (dgadomski) wrote :

Added debdiff proposal for bionic.

The attachment "landscape-client_16.03-0ubuntu4.debdiff" seems to be a debdiff. The ubuntu-sponsors team has been subscribed to the bug report so that they can review and hopefully sponsor the debdiff. If the attachment isn't a patch, please remove the "patch" flag from the attachment, remove the "patch" tag, and if you are member of the ~ubuntu-sponsors, unsubscribe the team.

[This is an automated message performed by a Launchpad user owned by ~brian-murray, for any issue please contact him.]

tags: added: patch
Andreas Hasenack (ahasenack) wrote :

Can the attached debdiff be updated to match what actually landed in landscape-client trunk according to https://github.com/CanonicalLtd/landscape-client/commit/c926cfaf3ad1a8759f0b269540391bbfc20dc00a ?

Andreas Hasenack (ahasenack) wrote :

I have a branch with the updated diff, thanks @simpoir.

While building, I noticed that the unit tests have several failures in releases >= zesty (not introduced by this fix). I would like to see these passing before our next upload: https://bugs.launchpad.net/landscape-client/+bug/1736576

Changed in landscape-client:
status: New → Fix Committed
milestone: none → 18.01
Eric Desrochers (slashd) on 2018-01-16
no longer affects: landscape-client (Ubuntu Zesty)
Changed in landscape-client (Ubuntu Bionic):
assignee: nobody → Andreas Hasenack (ahasenack)
status: New → In Progress
Brian Murray (brian-murray) wrote :

The bug description is mostly ready for the SRU process but is missing a statement regarding the regression potential of the fix.

Launchpad Janitor (janitor) wrote :
Download full text (3.9 KiB)

This bug was fixed in the package landscape-client - 18.01-0ubuntu1

---------------
landscape-client (18.01-0ubuntu1) bionic; urgency=medium

  * New upstream release 18.01:
    - Ported to python3 (LP: #1577850)
    - move Replaces/Breaks landscape-client-ui rules to landscape-common
      (LP: #1560424)
    - Add a libpam-systemd Depends if built for xenial (LP: #1590838)
    - Some units not reporting swift usage (LP: #1588404)
    - Fix missing install directories for landscape-common and drop
      usr/share/landscape as its only used and created by landscape-client.
      (LP: #1680842)
    - Fix VM detection for Xen, by returning "xen" only for paravirtualized and
      HVM hosts, not for dom0. (LP: #1601818)
    - Add an indication of truncation to process output that has been truncated
      prior to delivery to the server. (LP: #1629000)
    - add /snap/bin to the PATH when executing scripts. (LP: #1635634)
    - Save the original sources.list file when a repository profile is
      associated with a computer and restore it when the profile is removed.
      (LP: #1607529)
    - Drop the legacy HAService plugin, which is no longer used.
    - Avoid double-decoding package descriptions in build_skeleton_apt, which
      causes an error with Xenial python-apt. (LP: #1655395)
    - Remove dead dbus code and textmessage (confirmed not supported in server
      for ~2 years). (LP: #1657372)
    - Move bzr-builddeb conf file from deprecated location to debian/
      (LP: #1658796)
    - Support for new server error message about there being too many pending
      computers already (LP: #1662530)
    - Add a timestamp to the package reporter result (LP: #1674252)
    - Check if ubuntu-release-upgrader is running before apt-update (LP: #1699179)
    - Implicitly trust file-local sources managed by landscape. On upgrades,
      add the trusted flag to the landscape file-local apt source file if it's
      not there. (LP: #1736576)
    - Use local system tools to change the user's password (LP: #1743558)
  * clean up packaging and getting in sync with the new landscape version:
    - d/rules: drop extra:suggests which is unused since 13.07.1-0ubuntu2
    - Remove antique postinst code. No supported landscape-client version
      installs cronjobs anymore (since a long time).
    - d/landscape-client.docs: the README file is now a markdown file, so
      install that instead.
    - d/landscape-common.postinst: no need to single out
      /var/lib/landscape/.gnupg when fixing ownerships, just do it over
      the entire parent directory.
    - guard user and group removal via an empty .cleanup.* file in post, so we
      only remove the user/group if we were the ones who created them at
      install time.
    - lintian: remove absolute path from update-motd calls in maintainer
      scripts
    - d/rules: drop special handling for dapper, hardy and lucid, which are no
      longer supported.
    - d/rules: make sure we have an "extra:Depends=" in substvars even if it's
      empty
    - d/rules: drop dh_pycentral handling, it's obsolete
  * Dropped (already included in this version):
    - d/p/set-vm-info-to-kvm-for-aws-C5-instances.patch:
  ...

Read more...

Changed in landscape-client (Ubuntu Bionic):
status: In Progress → Fix Released
Changed in landscape-client:
status: Fix Committed → Fix Released
Changed in landscape-client (Ubuntu Trusty):
importance: Undecided → Medium
Changed in landscape-client (Ubuntu Xenial):
importance: Undecided → Medium
Changed in landscape-client (Ubuntu Artful):
importance: Undecided → Medium
Changed in landscape-client (Ubuntu Bionic):
importance: Undecided → Medium
Simon Quigley (tsimonq2) wrote :

Unsubscribing sponsors because there's nothing to sponsor.

Changed in landscape-client (Ubuntu Artful):
status: New → Won't Fix
Simon Poirier (simpoir) on 2018-11-01
description: updated
Changed in landscape-client (Ubuntu Cosmic):
status: New → In Progress
importance: Undecided → Medium
assignee: nobody → Simon Poirier (simpoir)
Andreas Hasenack (ahasenack) wrote :

cosmic is not affected, since back then it got the package from bionic while cosmic was the development series. I'm therefore dropping the cosmic task.

no longer affects: landscape-client (Ubuntu Cosmic)
Changed in landscape-client (Ubuntu Xenial):
status: New → In Progress
assignee: nobody → Simon Poirier (simpoir)
Changed in landscape-client (Ubuntu Trusty):
status: New → In Progress
assignee: nobody → Simon Poirier (simpoir)

An upload of landscape-client to xenial-proposed has been rejected from the upload queue for the following reason: "Includes a change without an SRU bug attached to it".

Timo Aaltonen (tjaalton) wrote :

An upload of landscape-client to trusty-proposed has been rejected from the upload queue for the following reason: "Includes a change without an SRU bug attached to it".

Hello Dariusz, or anyone else affected,

Accepted landscape-client into xenial-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/landscape-client/16.03-0ubuntu2.16.04.5 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-xenial to verification-done-xenial. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-xenial. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in landscape-client (Ubuntu Xenial):
status: In Progress → Fix Committed
tags: added: verification-needed verification-needed-xenial
Timo Aaltonen (tjaalton) wrote :

Hello Dariusz, or anyone else affected,

Accepted landscape-client into trusty-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/landscape-client/14.12-0ubuntu6.14.04.4 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-trusty to verification-done-trusty. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-trusty. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in landscape-client (Ubuntu Trusty):
status: In Progress → Fix Committed
tags: added: verification-needed-trusty
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers