[Series-upgrade] doesn't install python3 packages (or they get uninstalled)

Bug #1934306 reported by Alex Kavanagh
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Glance-Simplestreams-Sync Charm
Fix Released
Undecided
Alex Kavanagh

Bug Description

At some point between bionic-queens and focal-ussuri, g-s-s stopped syncing images as the python3-keystoneauth packages weren't installed, amongst others.

I *think* it occurred during the series upgrade when 'unused' packages were purged, but I'm not sure.

Running the sync action produces the error:

$ juju run-action --wait glance-simplestreams-sync/0 sync-images
unit-glance-simplestreams-sync-0:
  UnitId: glance-simplestreams-sync/0
  id: "2307"
  message: exit status 1
  results:
    ReturnCode: 1
    Stderr: |
      Traceback (most recent call last):
        File "/usr/share/glance-simplestreams-sync/glance_simplestreams_sync.py", line 40, in <module>
          from keystoneclient.v2_0 import client as keystone_client
      ModuleNotFoundError: No module named 'keystoneclient'
  status: failed
  timing:
    completed: 2021-06-30 16:05:51 +0000 UTC
    enqueued: 2021-06-30 16:05:46 +0000 UTC
    started: 2021-06-30 16:05:50 +0000 UTC

The workaround, is to run on the unit:

$ sudo apt install python3-glanceclient python3-yaml python3-keystoneclient python3-swiftclient

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to charm-glance-simplestreams-sync (master)
Changed in charm-glance-simplestreams-sync:
status: New → In Progress
Changed in charm-glance-simplestreams-sync:
assignee: nobody → Alex Kavanagh (ajkavanagh)
tags: added: charm-upgrade series-upgrade
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to charm-glance-simplestreams-sync (master)

Reviewed: https://review.opendev.org/c/openstack/charm-glance-simplestreams-sync/+/799091
Committed: https://opendev.org/openstack/charm-glance-simplestreams-sync/commit/787a9c5ae9d20fc6d714f010739bcbd765d024db
Submitter: "Zuul (22348)"
Branch: master

commit 787a9c5ae9d20fc6d714f010739bcbd765d024db
Author: Alex Kavanagh <email address hidden>
Date: Thu Jul 1 15:37:41 2021 +0100

    Ensure py3 pkgs installed on series-upgrade

    On series-upgrade the g-s-s stopped syncing due python packages required
    by the sync file (that is run in the context of the unit, rather than
    the charm) not being present. I believe they may have been removed
    during the series-upgrade when unused packages were removed.

    This patch ensures that on both upgrade and series upgrade, all the
    packages that are needed are installed.

    Change-Id: I8dfa9b0111fa3f204364e2c0833595bf8b219a7c
    Closes-Bug: #1934306

Changed in charm-glance-simplestreams-sync:
status: In Progress → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to charm-glance-simplestreams-sync (stable/21.04)
Changed in charm-glance-simplestreams-sync:
milestone: none → 21.10
Changed in charm-glance-simplestreams-sync:
status: Fix Committed → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on charm-glance-simplestreams-sync (stable/21.04)

Change abandoned by "James Page <email address hidden>" on branch: stable/21.04
Review: https://review.opendev.org/c/openstack/charm-glance-simplestreams-sync/+/799322
Reason: Review targets obsolete stable branch

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.