Have you been checking out different versions of the code? Seems like you might have extra .pyc files in your nova/db/sqlalchemy/migrate_repo/versions/ directory that you need to clean out.
Vish On Nov 22, 2012, at 4:32 AM, Afef MDHAFFAR <afef.mdhaf...@gmail.com> wrote: > Hi all, > > I got this error message when I try de synchronise the database. Could you > please help me to fix it? > > nova-manage db sync > Command failed, please check log for more info > 2012-11-22 12:30:14 CRITICAL nova [-] <VerNum(142)> > 2012-11-22 12:30:14 TRACE nova Traceback (most recent call last): > 2012-11-22 12:30:14 TRACE nova File "/usr/local/bin/nova-manage", line 7, > in <module> > 2012-11-22 12:30:14 TRACE nova execfile(__file__) > 2012-11-22 12:30:14 TRACE nova File "/opt/stack/nova/bin/nova-manage", line > 1175, in <module> > 2012-11-22 12:30:14 TRACE nova main() > 2012-11-22 12:30:14 TRACE nova File "/opt/stack/nova/bin/nova-manage", line > 1162, in main > 2012-11-22 12:30:14 TRACE nova fn(*fn_args, **fn_kwargs) > 2012-11-22 12:30:14 TRACE nova File "/opt/stack/nova/bin/nova-manage", line > 758, in sync > 2012-11-22 12:30:14 TRACE nova return migration.db_sync(version) > 2012-11-22 12:30:14 TRACE nova File "/opt/stack/nova/nova/db/migration.py", > line 32, in db_sync > 2012-11-22 12:30:14 TRACE nova return IMPL.db_sync(version=version) > 2012-11-22 12:30:14 TRACE nova File > "/opt/stack/nova/nova/db/sqlalchemy/migration.py", line 77, in db_sync > 2012-11-22 12:30:14 TRACE nova return > versioning_api.upgrade(get_engine(), repository, version) > 2012-11-22 12:30:14 TRACE nova File > "/usr/local/lib/python2.7/dist-packages/migrate/versioning/api.py", line 186, > in upgrade > 2012-11-22 12:30:14 TRACE nova return _migrate(url, repository, version, > upgrade=True, err=err, **opts) > 2012-11-22 12:30:14 TRACE nova File "<string>", line 2, in _migrate > 2012-11-22 12:30:14 TRACE nova File > "/opt/stack/nova/nova/db/sqlalchemy/migration.py", line 44, in > patched_with_engine > 2012-11-22 12:30:14 TRACE nova return f(*a, **kw) > 2012-11-22 12:30:14 TRACE nova File > "/usr/local/lib/python2.7/dist-packages/migrate/versioning/api.py", line 345, > in _migrate > 2012-11-22 12:30:14 TRACE nova changeset = schema.changeset(version) > 2012-11-22 12:30:14 TRACE nova File > "/usr/local/lib/python2.7/dist-packages/migrate/versioning/schema.py", line > 80, in changeset > 2012-11-22 12:30:14 TRACE nova changeset = > self.repository.changeset(database, start_ver, version) > 2012-11-22 12:30:14 TRACE nova File > "/usr/local/lib/python2.7/dist-packages/migrate/versioning/repository.py", > line 225, in changeset > 2012-11-22 12:30:14 TRACE nova changes = > [self.version(v).script(database, op) for v in versions] > 2012-11-22 12:30:14 TRACE nova File > "/usr/local/lib/python2.7/dist-packages/migrate/versioning/repository.py", > line 189, in version > 2012-11-22 12:30:14 TRACE nova return self.versions.version(*p, **k) > 2012-11-22 12:30:14 TRACE nova File > "/usr/local/lib/python2.7/dist-packages/migrate/versioning/version.py", line > 140, in version > 2012-11-22 12:30:14 TRACE nova return self.versions[VerNum(vernum)] > 2012-11-22 12:30:14 TRACE nova KeyError: <VerNum(142)> > 2012-11-22 12:30:14 TRACE nova > root@controller:~# > > > Thank you, > Afef > > > _______________________________________________ > Mailing list: https://launchpad.net/~openstack > Post to : openstack@lists.launchpad.net > Unsubscribe : https://launchpad.net/~openstack > More help : https://help.launchpad.net/ListHelp _______________________________________________ Mailing list: https://launchpad.net/~openstack Post to : openstack@lists.launchpad.net Unsubscribe : https://launchpad.net/~openstack More help : https://help.launchpad.net/ListHelp