Ocata, openstack server list Unexpected API Error

asked 2017-05-02 05:26:11 -0500

Yury gravatar image

Hello.
I'm trying to install openstack according to https://docs.openstack.org/ocata/install-guide-rdo/ (https://docs.openstack.org/ocata/inst...) I've created the instance successfully, but when I tried to check status of an instance (https://docs.openstack.org/ocata/install-guide-rdo/launch-instance-provider.html (https://docs.openstack.org/ocata/inst...)), I got:

[root@controller ~]# openstack server list
Unexpected API Error. Please report this at http://bugs.launchpad.net/nova/ and attach the Nova API log if possible.
<class 'sqlalchemy.exc.operationalerror'=""> (HTTP 500) (Request-ID: req-fedf828c-bd75-41b2-b0fd-1c26ea4f3a89)
[root@controller ~]# 

The instance was created successfully. Here is a part of my nova-api.log:

2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions [req-23c6c8d7-5b50-4976-84ab-3a9f1498ee32 - - - - -] Unexpected exception in API method
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions Traceback (most recent call last):
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions   File "/usr/lib/python2.7/site-packages/nova/api/openstack/extensions.py", line 338, in wrapped
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions     return f(*args, **kwargs)
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions   File "/usr/lib/python2.7/site-packages/nova/api/validation/__init__.py", line 181, in wrapper
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions     return func(*args, **kwargs)
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions   File "/usr/lib/python2.7/site-packages/nova/api/validation/__init__.py", line 181, in wrapper
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions     return func(*args, **kwargs)
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions   File "/usr/lib/python2.7/site-packages/nova/api/openstack/compute/servers.py", line 214, in detail
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions     servers = self._get_servers(req, is_detail=True)
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions   File "/usr/lib/python2.7/site-packages/nova/api/openstack/compute/servers.py", line 352, in _get_servers
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions     sort_keys=sort_keys, sort_dirs=sort_dirs)
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions   File "/usr/lib/python2.7/site-packages/nova/compute/api.py", line 2429, in get_all
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions     sort_dirs=sort_dirs)
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions   File "/usr/lib/python2.7/site-packages/nova/compute/api.py", line 2569, in _get_instances_by_filters
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions     expected_attrs=fields, sort_keys=sort_keys, sort_dirs=sort_dirs)
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions   File "/usr/lib/python2.7/site-packages/oslo_versionedobjects/base.py", line 184, in wrapper
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions     result = fn(cls, context, *args, **kwargs)
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions   File "/usr/lib/python2.7/site-packages/nova/objects/instance.py", line 1220, in get_by_filters
2017-05-02 12:57:59.080 2800 ERROR nova.api.openstack.extensions ...
(more)
edit retag flag offensive close merge delete

Comments

Are DB tables populated? is raising error connecting to nova_api db

Eduardo Gonzalez gravatar imageEduardo Gonzalez ( 2017-05-02 08:13:10 -0500 )edit

Also confirm grant all privileges on nova_api.* to 'nova'@'%' identified by 'password'; privilege has been granted (same for nova database).

barry.davis gravatar imagebarry.davis ( 2017-05-02 08:44:47 -0500 )edit

I think so. I can connect to the nova_api database as nova user and see the tables. In addition, for example, 'nova-manage cell_v2 list_cells', 'openstack flavor list' and so on return the correct values.

Yury gravatar imageYury ( 2017-05-02 08:50:52 -0500 )edit

About privileges. I've just connected to databases as the user nova from the host compute1 and inserted, selected and then deleted few records in tables, just for testing purposes. Any other ideas?

Yury gravatar imageYury ( 2017-05-02 09:24:19 -0500 )edit