Ask Your Question
0

Glance & Nova-api id error and how to fix it**

asked 2016-09-08 16:45:07 -0500

fifi gravatar image

updated 2016-09-14 18:14:59 -0500

I created an image with Diskimage-builder and installed python-pip, python-dev, pyhton-eventlet, python-routes, pyhton-webob, and python-paramiko on it. I uploaded this image to the glance. I wanted to delete the uploaded image for some reson, but glance couldn't delete it. In fact glance deleted the image but did not change its status to deleted. After facing this problem, my nova cannot create an instance. My attempts to lunch an instance lead to the following error message:

ERROR (ClientException): The server has either erred or is incapable of performing the requested operation. (HTTP 500) (Request-ID: req-273c3006-846a-4e3c-bac3-3325b1973dfa)

I checked all nova and neutron agent lists. They all are working fine. I reinstalled rabbitmq, and checked my nova.conf for any problem. None of them worked for me. I also check different nova log file and just just found an error in my nova.api log:

2016-09-07 20:48:27.247 20065 ERROR nova.api.openstack [req-94a5eaab-cce7-4b26-b895-a83edf02bb5c None] Caught error: id

Any help would be highly apreciated.

My nova.conf

[DEFAULT]
dhcpbridge_flagfile=/etc/nova/nova.conf
dhcpbridge=/usr/bin/nova-dhcpbridge

logdir=/var/log/nova
state_path=/var/lib/nova
lock_path=/var/lock/nova
force_dhcp_release=True
libvirt_use_virtio_for_bridges=True
verbose=True
ec2_private_dns_show_ip=True
api_paste_config=/etc/nova/api-paste.ini
enabled_apis=ec2,osapi_compute,metadata
rpc_backend = rabbit
rabbit_host = controller
rabbit_password = service_pass
auth_strategy = keystone
my_ip = 10.0.0.11
vncserver_listen = 10.0.0.11
vncserver_proxyclient_address = 10.0.0.11
verbose = True
network_api_class = nova.network.neutronv2.api.API
security_group_api = neutron
linuxnet_interface_driver = nova.network.linux_net.LinuxOVSInterfaceDriver
firewall_driver = nova.virt.firewall.NoopFirewallDriver

service_metadata_proxy = True
metadata_proxy_shared_secret = METADATA_SECRET

[database]
connection = mysql://nova:NOVA_DBPASS@controller/nova

[keystone_authtoken]
auth_uri = http://controller:5000/v2.0
identity_uri = http://controller:35357
admin_tenant_name = service
admin_user = nova
admin_password = service_pass

[neutron]
url = http://controller:9696
auth_strategy = keystone
admin_auth_url = http://controller:35357/v2.0
admin_tenant_name = service
admin_username = neutron
admin_password = service_pass

[glance]
host = controller

My nova.api log:

2016-09-07 20:48:26.383 20043 INFO nova.osapi_compute.wsgi.server [req-04b95aca-82e9-40ca-80a4-983f78dec9f3 None] 10.0.0.11 "GET /v2/3820f4ef246a4859afbcda121114844b/servers/detail?project_id=3820f4ef246a4859afbcda121114844b HTTP/1.1" status: 200 len: 211 time: 0.1374729
2016-09-07 20:48:26.394 20043 INFO nova.osapi_compute.wsgi.server [req-4c16b867-e508-4c98-8dbf-c1a31aaaebf4 None] 10.0.0.11 "GET /v2/3820f4ef246a4859afbcda121114844b/os-keypairs HTTP/1.1" status: 200 len: 212 time: 0.0068040
2016-09-07 20:48:26.578 20050 INFO nova.osapi_compute.wsgi.server [req-827d3318-7f9d-47fb-a399-979700d3f739 None] 10.0.0.11 "GET /v2/3820f4ef246a4859afbcda121114844b/extensions HTTP/1.1" status: 200 len: 22227 time: 0.0785420
2016-09-07 20:48:27.247 20065 ERROR nova.api.openstack [req-94a5eaab-cce7-4b26-b895-a83edf02bb5c None] Caught error: id
2016-09-07 20:48:27.247 20065 TRACE nova.api.openstack Traceback (most recent call last):
2016-09-07 20:48:27.247 20065 TRACE nova.api.openstack   File "/usr/lib/python2.7/dist-packages/nova/api/openstack/__init__.py", line 124, in __call__
2016-09-07 20:48:27.247 20065 TRACE nova.api.openstack     return req.get_response(self.application)
2016-09-07 20:48:27.247 20065 TRACE nova.api.openstack   File "/usr/lib/python2.7/dist-packages/webob/request.py", line 1320, in send
2016-09-07 20:48:27.247 20065 TRACE nova ...
(more)
edit retag flag offensive close merge delete

Comments

Attempt remove package python-pip

curl "https://bootstrap.pypa.io/get-pip.py" -o "get-pip.py"
python get-pip.py
dbaxps gravatar imagedbaxps ( 2016-09-09 08:28:11 -0500 )edit

On RDO yum install python-pip python-devel affects python-novaclient via my experience
I need for instance python-magnumclient to be packaged on RDO to be installed smoothly, rather then installed via pip.

dbaxps gravatar imagedbaxps ( 2016-09-09 08:34:36 -0500 )edit
dbaxps gravatar imagedbaxps ( 2016-09-09 08:38:27 -0500 )edit

Thanks for your reply.

fifi gravatar imagefifi ( 2016-09-16 00:26:48 -0500 )edit

1 answer

Sort by ยป oldest newest most voted
1

answered 2016-09-13 19:49:48 -0500

fifi gravatar image

The error caused by glance. It couldn't send correct image id to nova for furthur processes. To solve this problem

1- I reinstalled glance and python-glanceclient.

2- By default nova call glance client to query image metadata by using glance api version 1. I modify /usr/lib/python2.7/dist-packages/nova/image/api.py as below

def get(self, context, id_or_uri, include_locations=False,   ========changed to========>   def get(self, context, id_or_uri, include_locations=True,

3- In /etc/glance/glance.api.conf make the glance use api version to 2. enable_v2_api = True

4- restart glance-api, glance-registry, and nova-api. Everything should work fine.

edit flag offensive delete link more

Comments

I guess python packages I installed on my image caused this problem.

fifi gravatar imagefifi ( 2016-09-16 00:28:33 -0500 )edit

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: 2016-09-08 16:45:07 -0500

Seen: 439 times

Last updated: Sep 14 '16