Justin-

Please see a bug filed against Glance earlier today:
https://bugs.launchpad.net/bugs/981081  As it turns out, Essex glance
does not actually run migrations against a new database anymore, it
instead cheats (see description in that bug).   The new Ubuntu package
contains a patch that requires an extra step in creation of the glance
database, we need to properly version control it and set it at version
0, to ensure all migrations are actually run:

glance-manage version_control 0
glance-manage db_sync

I should note that previously 2012.1-0ubuntu1, db_sync does not actually
create the schema but  glance-registry startup.  If you were to stop
glance-registry entirely, run db_sync, and inspect the glance database,
the only thing that is created is a migrate_versions table wrongly
claiming the db is versioned at version 13.  Startup of glance-registry
is actually creating the schema, albeit poorly, and migrate is not being
used at all.

I've opted to refuse attempts to db_sync without first version_control,
because ending up in the situation that db_sync is run without
version_control results in 1, a database schema that only represents the
current sqlalchemy models 2, greatly complicates incrementally
downgrading or upgrading the database in the future.

This is a new issue and its possible we might work out a better solution
that can be applied upstream and to our packages.  In the meantime, run
'glance-manage version_control 0 && glance-manage db_sync' before
migrating a new database (this is needed for using vanilla stable/essex
branch as well)

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/981111

Title:
  New database is not under version_controll

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/glance/+bug/981111/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to