Ask Your Question
1

keystone-manage db_sync failure after upgrading from Essex to Icehouse

asked 2014-08-26 11:09:46 -0600

Leigh507 gravatar image

Hi All,

Second post on these forums. I am still new to openstack but learning fast :)

So I managed to upgrade and pupettize the upgrade of keystone locally on my machine. Works perfectly there, No quibbles at all.

When rolling it out to a test environment with actual data and an existing keystone DB the puppet run fails on the keystone-manage db_sync

The error thrown is

    2014-08-26 16:07:38.888 11464 CRITICAL keystone [-] OperationalError: (OperationalError) (1060, "Duplicate column name 'valid'") '\nALTER TABLE token ADD valid BOOL' ()
2014-08-26 16:07:38.888 11464 TRACE keystone Traceback (most recent call last):
2014-08-26 16:07:38.888 11464 TRACE keystone   File "/usr/bin/keystone-manage", line 51, in <module>
2014-08-26 16:07:38.888 11464 TRACE keystone     cli.main(argv=sys.argv, config_files=config_files)
2014-08-26 16:07:38.888 11464 TRACE keystone   File "/usr/lib/python2.6/site-packages/keystone/cli.py", line 190, in main
2014-08-26 16:07:38.888 11464 TRACE keystone     CONF.command.cmd_class.main()
2014-08-26 16:07:38.888 11464 TRACE keystone   File "/usr/lib/python2.6/site-packages/keystone/cli.py", line 66, in main
2014-08-26 16:07:38.888 11464 TRACE keystone     migration_helpers.sync_database_to_version(extension, version)
2014-08-26 16:07:38.888 11464 TRACE keystone   File "/usr/lib/python2.6/site-packages/keystone/common/sql/migration_helpers.py", line 139, in sync_database_to_version
2014-08-26 16:07:38.888 11464 TRACE keystone     migration.db_sync(sql.get_engine(), abs_path, version=version)
2014-08-26 16:07:38.888 11464 TRACE keystone   File "/usr/lib/python2.6/site-packages/keystone/openstack/common/db/sqlalchemy/migration.py", line 197, in db_sync
2014-08-26 16:07:38.888 11464 TRACE keystone     return versioning_api.upgrade(engine, repository, version)
2014-08-26 16:07:38.888 11464 TRACE keystone   File "/usr/lib/python2.6/site-packages/migrate/versioning/api.py", line 185, in upgrade
2014-08-26 16:07:38.888 11464 TRACE keystone     return _migrate(url, repository, version, upgrade=True, err=err, **opts)
2014-08-26 16:07:38.888 11464 TRACE keystone   File "<string>", line 2, in _migrate
2014-08-26 16:07:38.888 11464 TRACE keystone   File "/usr/lib/python2.6/site-packages/migrate/versioning/util/__init__.py", line 160, in with_engine
2014-08-26 16:07:38.888 11464 TRACE keystone     return f(*a, **kw)
2014-08-26 16:07:38.888 11464 TRACE keystone   File "/usr/lib/python2.6/site-packages/migrate/versioning/api.py", line 364, in _migrate
2014-08-26 16:07:38.888 11464 TRACE keystone     schema.runchange(ver, change, changeset.step)
2014-08-26 16:07:38.888 11464 TRACE keystone   File "/usr/lib/python2.6/site-packages/migrate/versioning/schema.py", line 90, in runchange
2014-08-26 16:07:38.888 11464 TRACE keystone     change.run(self.engine, step)
2014-08-26 16:07:38.888 11464 TRACE keystone   File "/usr/lib/python2.6/site-packages/migrate/versioning/script/py.py", line 145, in run
2014-08-26 16:07:38.888 11464 TRACE keystone     script_func(engine)
2014-08-26 16:07:38.888 11464 TRACE keystone   File "/usr/lib/python2.6/site-packages/keystone/common/sql/migrate_repo/versions/003_token_valid.py", line 28, in upgrade
2014-08-26 16:07:38.888 11464 TRACE keystone ...
(more)
edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
0

answered 2014-12-16 03:46:32 -0600

NikStSG gravatar image

updated 2014-12-16 03:48:41 -0600

Check your SQL keystone database manually:

# mysql -u root -p<password>

mysql> use keystone;

mysql> show tables;

+-----------------------+

There have been some problems with python-sqlalchemy before. What version do you use? (# yum info python-sqlalchemy)

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2014-08-26 11:09:46 -0600

Seen: 599 times

Last updated: Dec 16 '14