[Openstack-operators] folsom -> grizzly keystone-manage db_sync error

Björn Hagemeier b.hagemeier at fz-juelich.de
Tue Aug 6 13:26:20 UTC 2013


Hi Jonathan,

without reading your full thread, I found the same problem yesterday 
while upgrading. I deleted the extra users from DB and everything worked 
fine.

There's a bug related to update issues from folsom to grizzly in which I 
meant to report what I had to do, but didn't do yet. I'll do after 
sending this email.

https://bugs.launchpad.net/keystone/+bug/1131174

The cause of the "problem" is that originally there was no enforcement 
of referential integrity of the DB, which has now been added. 
Transforming the old data, which possibly contains integrity violations, 
can cause these problems. So actually, it is a good thing, but legacy 
data may not quite fit in.

I think the table from which I deleted the entries was 
user_project_metadata. You'll find the right place anyhow.


Cheers,
Björn

On 06.08.2013 15:05, Jonathan Proulx wrote :
>
> I believe this relates to deleted users.
>
> The old metadata table has entries for user_id's that have no
> corresponding entry in the user table.  I've not quite worked out the
> SQL for showing these lines but it appears they also have no roles in
> the projects they are associated with.  Just a little more coffee and I
> think I've got it.
>
> If my suspicion is correct then the patch is pretty easy just don't try
> to migrate rows where the role list is null.
>
> -Jon
>
>
> On Tue, Aug 6, 2013 at 8:38 AM, Jonathan Proulx <jon at jonproulx.com
> <mailto:jon at jonproulx.com>> wrote:
>
>     On Tue, Aug 6, 2013 at 2:15 AM, Robert van Leeuwen
>     <Robert.vanLeeuwen at spilgames.com
>     <mailto:Robert.vanLeeuwen at spilgames.com>> wrote:
>
>          > On Ubuntu 12.04 using cloud-archieve repos I just upgraded
>         keystone to grizzly from folsom,
>          > but 'keystone-manage db_sync' is failing with something like:
>
>          > sqlalchemy.exc.IntegrityError: (IntegrityError) (1452,
>         'Cannot add or update a child row: a foreign key
>
>          > Any clues on how to get my db to sync?
>
>         Jon,
>
>         Could you check if your tables are innodb?
>         I've seen something similar when the tables where myisam.
>
>         Cheers,
>         Robert van Leeuwen
>
>
>
>
>     They are innodb, SHOW TABLE STATUS confirms.
>
>     Thanks,
>     -Jon
>
>
>
>
> _______________________________________________
> OpenStack-operators mailing list
> OpenStack-operators at lists.openstack.org
> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-operators
>


-- 
Dipl.-Inform. Björn Hagemeier
Federated Systems and Data
Juelich Supercomputing Centre
Institute for Advanced Simulation

Phone: +49 2461 61 1584
Fax  : +49 2461 61 6656
Email: b.hagemeier at fz-juelich.de
Skype: bhagemeier
WWW  : http://www.fz-juelich.de/jsc

JSC is the coordinator of the
John von Neumann Institute for Computing
and member of the
Gauss Centre for Supercomputing

-------------------------------------------------------------------------------------
-------------------------------------------------------------------------------------
Forschungszentrum Juelich GmbH
52425 Juelich
Sitz der Gesellschaft: Juelich
Eingetragen im Handelsregister des Amtsgerichts Dueren Nr. HR B 3498
Vorsitzender des Aufsichtsrats: MinDir Dr. Karl Eugen Huthmacher
Geschaeftsfuehrung: Prof. Dr. Achim Bachem (Vorsitzender),
Karsten Beneke (stellv. Vorsitzender), Prof. Dr.-Ing. Harald Bolt,
Prof. Dr. Sebastian M. Schmidt
-------------------------------------------------------------------------------------
------------------------------------------------------------------------------------- 

-------------- next part --------------
A non-text attachment was scrubbed...
Name: b_hagemeier.vcf
Type: text/x-vcard
Size: 376 bytes
Desc: not available
URL: <http://lists.openstack.org/pipermail/openstack-operators/attachments/20130806/d9c85fe0/attachment.vcf>


More information about the OpenStack-operators mailing list