Ask Your Question
0

Urgent : newton nova db sync - not migrating compute_nodes table

asked 2017-01-14 15:45:08 -0500

jkilborn gravatar image

updated 2017-01-14 15:55:11 -0500

I'm upgrading from liberty to netwon. I have keystone, dashboard, glance, cinder working so far. Now doing nova. I created the nova_api database (due to it being added in mitaka).

I ran the su -s /bin/sh "nova-manage api_db sync" nova without any issues

When I try to run su -s /bin/sh -c "nova-manage db sync" nova it outputs the following :

WARNING: cell0 mapping not found - not syncing cell0.

error: There are still 15 unmigrated records in the compute_nodes table. Migration cannot continue until all records have been migrated.

Can't seem to find much help on error with the compute_nodes table migration, and I can't get the nova db to migrate to the newton schema.

Any ideas?

edit retag flag offensive close merge delete

Comments

After more testing, that error is generated as the nova db tries to migrate from 329 to 330. It cant complete this migration and produces the error about the compute_nodes table;

jkilborn gravatar imagejkilborn ( 2017-01-14 16:38:06 -0500 )edit

3 answers

Sort by ยป oldest newest most voted
1

answered 2017-03-10 17:20:58 -0500

Rado gravatar image

Check compute_nodes table in nova database for NULL values for uuid column and remove those.

edit flag offensive delete link more

Comments

Thanks for the response. I finally got back to trying to upgrade my db again. It upgrades from liberty to mitaka fine, but during the upgrade to newton, I get the error again. I looked at the compute_nodes table, and all 15 records have uuid null.

I'm not sure why they are null.

jkilborn gravatar imagejkilborn ( 2017-03-23 11:15:14 -0500 )edit

I found the problem. While mitaka updates the schema (adds a uuid column to compute_nodes as an example), the uuid field doesnt get populated until the nova_compute node starts up, and checks in. Then, the uuid field gets populated. You can't upgrade to newton directly from liberty, due to this issu

jkilborn gravatar imagejkilborn ( 2017-03-23 12:55:07 -0500 )edit
0

answered 2017-01-14 16:26:08 -0500

volenbovsky gravatar image

Hi,

So assumptions: -you need to have CellsV2 starting from Newton -you will deal with single cell. -you have not used CellsV1 -you have test environment. For me it does not look safe ;) and I have not performed upgrade. As you will see in bug, not everything is idempotent so then you can create more problems by running same command more than once. So I think https://bugs.launchpad.net/tripleo/+b... is the thing to read (I hope that you http://docs.openstack.org/releasenote...

All in all I think it is matter of "nova-manage cell_v2 simple_cell_setup --transport-url <url> " , but please read the bug description

http://docs.openstack.org/releasenote... is outcome of that bug with "Adds cell_v2 simple_cell_setup as part of the nova-api database setup" There is also bug https://bugs.launchpad.net/nova/+bug/... and not-yet merged as of today https://review.openstack.org/#/c/2671... which seem to provide more complete picture on all that

edit flag offensive delete link more

Comments

So yeah, to add to that I also learnt that simple_cell_setup is alternative to combo map_cell0/map_cell_and_hosts/map_instances.

volenbovsky gravatar imagevolenbovsky ( 2017-01-14 16:37:15 -0500 )edit

I created the nova_api_cell0, granted the nova user rights. Then ran

[root@div18oscont1 nova]# nova-manage cell_v2 simple_cell_setup --transport-url transport_url=rabbit://....

That completed without errors. But didnt fix the error preventing the db upgrade beyond 329

jkilborn gravatar imagejkilborn ( 2017-01-14 17:37:47 -0500 )edit
0

answered 2017-04-10 14:19:42 -0500

updated 2017-04-11 09:52:36 -0500

No need to remove the soft deleted compute_nodes entries in the DB.

The issue is fixed and included in Newton (14.0.4). See: https://bugs.launchpad.net/nova/+bug/1665719 (https://bugs.launchpad.net/nova/+bug/...) and https://review.openstack.org/#/c/435620/

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: 2017-01-14 15:45:08 -0500

Seen: 1,442 times

Last updated: Apr 11 '17