action-managed upgrade to Ocata does not install cinder-api apache2 wsgi

Bug #1726527 reported by Edward Hope-Morley
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Cinder Charm
Fix Released
High
Edward Hope-Morley

Bug Description

There is a race condition in the cinder charm whereby if you perform an action-managed upgrade to Openstack Ocata (from any release) it will fail to install the apache wsgi config for cinder-api. This is due to the fact that the check for which config files need to be installed contains a condition that is only met after the packages have been upgraded and as a result returns false when going from < Ocata to Ocata. Co-incidentally if any charm hook that write configs runs post-upgrade (e.g. config-changed), this issue goes away since the config is then written to disk and apache restarted. So the fix for this should be to simply take into account that an upgrade is in progress and the target release will require new configs.

Tags: openstack sts
description: updated
Changed in charm-cinder:
assignee: nobody → Edward Hope-Morley (hopem)
summary: - action-managed upgraded to Ocata does not install cinder-api apache2
- wsgi
+ action-managed upgrade to Ocata does not install cinder-api apache2 wsgi
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to charm-cinder (master)

Fix proposed to branch: master
Review: https://review.openstack.org/514480

Changed in charm-cinder:
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to charm-cinder (master)

Reviewed: https://review.openstack.org/514480
Committed: https://git.openstack.org/cgit/openstack/charm-cinder/commit/?id=c1653c21136d0cb10a3b3ee41c6aeeacdb51c00a
Submitter: Zuul
Branch: master

commit c1653c21136d0cb10a3b3ee41c6aeeacdb51c00a
Author: Edward Hope-Morley <email address hidden>
Date: Mon Oct 23 23:24:14 2017 +0100

    Ensure upgrade installs correct configs

    When we do an openstack upgrade we must ensure that
    release version dependant decisions are made at the
    right time. In this patch we ensure that we choose
    configs after the target release packages have been
    installed so as to be sure that e.g. when upgrading
    from Newton to Ocata the apache2 wsgi conf is
    installed for the cinder-api.

    Change-Id: I9414940535406c7c7491636839a328df1ac9235b
    Closes-Bug: 1726527

Changed in charm-cinder:
status: In Progress → Fix Committed
Revision history for this message
Corey Bryant (corey.bryant) wrote :

Ed, does this affect any other charms? I've not looked through all charms but keystone at least looks like it may be affected.

Revision history for this message
Edward Hope-Morley (hopem) wrote :

@corey.bryant I will check that now.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Reviewed: https://review.openstack.org/514740
Committed: https://git.openstack.org/cgit/openstack/charm-cinder/commit/?id=5a5e542f9a1affc3519396f0d2a70e797226c9d4
Submitter: Zuul
Branch: master

commit 5a5e542f9a1affc3519396f0d2a70e797226c9d4
Author: Edward Hope-Morley <email address hidden>
Date: Tue Oct 24 17:19:31 2017 +0100

    Part 2 of upgrades fix in commit c1653c2

    In the first patch I forgot to ensure that we also
    reload the configs that are globally declared in
    cinder_hooks and therefore loaded on import. So here
    it is.

    Change-Id: I613959fa91912b388aea8bd6926d085956c1d67e
    Closes-Bug: #1726527

James Page (james-page)
Changed in charm-cinder:
status: Fix Committed → Fix Released
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.