Ask Your Question

Revision history [back]

I have the same error in queens,can't create vm in the compute node. when I drop database nova,create it again´╝îthe compute node is ok. But,if you drop the nova db,your all compute node will be lost.

MariaDB [(none)]> show databases;

+--------------------+
| Database           |
+--------------------+
| information_schema |
| glance             |
| keystone           |
| mysql              |
| neutron            |
| nova               |
| nova_api           |
| nova_cell0         |

MariaDB [(none)]> drop database nova;
MariaDB [(none)]> drop database nova_api;
MariaDB [(none)]> drop database nova_cell0;
MariaDB [(none)]> CREATE DATABASE nova_api;
MariaDB [(none)]> CREATE DATABASE nova;
MariaDB [(none)]> CREATE DATABASE nova_cell0;
MariaDB [(none)]> GRANT ALL PRIVILEGES ON nova_api.* TO 'nova'@'%' IDENTIFIED BY '***';
MariaDB [(none)]> GRANT ALL PRIVILEGES ON nova.* TO 'nova'@'%' IDENTIFIED BY '***';
MariaDB [(none)]> GRANT ALL PRIVILEGES ON nova_cell0.* TO 'nova'@'%' IDENTIFIED BY '***';

[root@controller2 ~]# su -s /bin/sh -c "nova-manage api_db sync" nova
[root@controller2 ~]# su -s /bin/sh -c "nova-manage cell_v2 map_cell0" nova
[root@controller2 ~]# su -s /bin/sh -c "nova-manage cell_v2 create_cell --name=cell1 --verbose" nova
[root@controller2 ~]# su -s /bin/sh -c "nova-manage db sync" nova

systemctl restart openstack-nova-api.service  openstack-nova-consoleauth.service openstack-nova-scheduler.service openstack-nova-conductor.service openstack-nova-novncproxy.service