Bug 1139239 - RHOS4->RHOS5 upgrade fails due to wrong version of python-migrate installed
Summary: RHOS4->RHOS5 upgrade fails due to wrong version of python-migrate installed
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-heat
Version: 5.0 (RHEL 6)
Hardware: Unspecified
OS: Unspecified
urgent
high
Target Milestone: z1
: 5.0 (RHEL 6)
Assignee: Zane Bitter
QA Contact: Dafna Ron
URL:
Whiteboard:
Depends On: 1133905
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-09-08 13:06 UTC by Lon Hohberger
Modified: 2014-09-30 17:52 UTC (History)
11 users (show)

Fixed In Version: openstack-heat-2014.1.2-2.0.el6ost
Doc Type: Bug Fix
Doc Text:
The openstack-heat package did not specify the version of the python-migrate package it actually required. As a result, if any old, incompatible version of python-migrate was installed, installing openstack-heat did not cause it to be updated to the required version. With this update, the minimum version is specified explicitly and the users can now run Orchestration database migrations after upgrading from RHOS 4 to RHEL-OSP 5 without needing to manually upgrade the python-migrate package.
Clone Of: 1133905
Environment:
Last Closed: 2014-09-30 17:52:06 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2014:1344 0 normal SHIPPED_LIVE openstack-heat bug fix advisory 2014-09-30 21:49:55 UTC

Description Lon Hohberger 2014-09-08 13:06:46 UTC
+++ This bug was initially created as a clone of Bug #1133905 +++

Dafna was following our upgrade documentation and ran into the following error while trying to upgrade the Cinder database:

  Can't determine the existing sync level.
  Please ensure the database is running and already initialised.

The actual error from /var/log/cinder/cinder-manage.log, was:

  TRACE cinder   File "/usr/lib/python2.6/site-packages/cinder/utils.py", line 423, in __get_backend
  TRACE cinder     self.__backend = __import__(name, None, None, fromlist)
  TRACE cinder   File "/usr/lib/python2.6/site-packages/cinder/db/sqlalchemy/migration.py", line 21, in <module>
  TRACE cinder     from migrate.versioning import api as versioning_api
  TRACE cinder   File "/usr/lib/python2.6/site-packages/migrate/versioning/api.py", line 33, in <module>
  TRACE cinder     from migrate.versioning import (repository, schema, version,
  TRACE cinder   File "/usr/lib/python2.6/site-packages/migrate/versioning/schema.py", line 10, in <module>
  TRACE cinder     from sqlalchemy import exceptions as sa_exceptions
  TRACE cinder ImportError: cannot import name exceptions

This is caused because after upgrading the openstack packages, python-migrate is still at version python-migrate-0.7.1-1.el6ost.noarch, while version python-migrate-0.8.2-2.el6ost.noarch is required.  The workaround is to manually upgrade python-migrate:

    yum upgrade python-migrate

The solution is to set a versioned Requires: on all of the openstack packages that require python-migrate.  According to 'repoquery --whatrequires python-migrate', this is:

  openstack-heat-common
  python-ceilometer
  python-cinder
  python-glance
  python-keystone
  python-nova

--- Additional comment from Lars Kellogg-Stedman on 2014-08-26 08:38:16 EDT ---

Using the openstack-cinder spec file as an example, I would probably change:

Requires:         python-sqlalchemy
Requires:         python-migrate

To:

Requires:         python-sqlalchemy >= 0.8.4
Requires:         python-migrate >= 0.8.2

--- Additional comment from Lars Kellogg-Stedman on 2014-08-26 13:48:48 EDT ---

Fixed in:

openstack-heat-2014.1.2-2.0.el6ost
openstack-ceilometer-2014.1.2-2.el6ost
openstack-cinder-2014.1.2-3.el6ost
openstack-glance-2014.1.2-3.el6ost
openstack-nova-2014.1.2-4.el6ost

This was previously fixed in:

openstack-keystone-2014.1.2.1-2.el6ost

Comment 3 Dafna Ron 2014-09-11 16:09:39 UTC
we do not fail on upgrade and the package exists after upgrade: 
[root@RHEL6 ~]# rpm -qa |grep python-sqlalchemy
python-sqlalchemy-0.8.4-1.el6ost.x86_64
python-sqlalchemy0.7-0.7.8-1.el6ost.x86_64
[root@RHEL6 ~]# rpm -qa |grep python-migrat
python-migrate-0.8.2-2.el6ost.noarch
[root@RHEL6 ~]#

Comment 6 errata-xmlrpc 2014-09-30 17:52:06 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2014-1344.html


Note You need to log in before you can comment on or make changes to this bug.