yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #05530
[Bug 1208652] Re: Migration 152 loses indexes on postgres columns
** Changed in: nova
Status: Fix Committed => Fix Released
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1208652
Title:
Migration 152 loses indexes on postgres columns
Status in OpenStack Compute (Nova):
Fix Released
Bug description:
Because the deleted column is dropped and recreated on a table it
invalidates the indexes which postgres loses. The migration does
nothing to fix this.
For example, on the migrations table.
Version 151:
openstack_citest=# select * from pg_indexes where tablename = 'migrations';
public | migrations | migrations_pkey | | CREATE UNIQUE INDEX migrations_pkey ON migrations USING btree (id)
public | migrations | migrations_instance_uuid_and_status_idx | | CREATE INDEX migrations_instance_uuid_and_status_idx ON migrations USING btree (deleted, instance_uuid, status)
public | migrations | migrations_by_host_nodes_and_status_idx | | CREATE INDEX migrations_by_host_nodes_and_status_idx ON migrations USING btree (deleted, source_compute, dest_compute, source_node, dest_node, status)
Version 152:
openstack_citest=# select * from pg_indexes where tablename = 'migrations';
public | migrations | migrations_pkey | | CREATE UNIQUE INDEX migrations_pkey ON migrations USING btree (id)
Two things probably need to be done here.
1) Create a new migration to fix all of the old indexes.
2) Make sure the downgrade of migration 152 adds back in the lost indexes to restore the previous state correctly.
#2 is blocking migration 144's downgrade as it tries to remove the now
missing index.
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1208652/+subscriptions