Revision history [back]

click to hide/show revision 1
initial version

500 error when trying to create image

I am following the tutorial to create the Openstack deployment. I am as far as creating the Cirros test image. When using the command:

glance image-create --name "cirros-0.3.2-x86_64" --disk-format qcow2 --container-format bare --is-public True --progress < cirros-0.3.2-x86_64-disk.img

I get the following error:

Request returned failure status.
HTTPInternalServerError (HTTP 500)

Here is the log tail:

controller:/tmp/images # vim /var/log/glance/api.log
    app_iter = application(self.environ, start_response)
  File "/usr/lib/python2.7/site-packages/paste/urlmap.py", line 203, in __call__
    return app(environ, start_response)
  File "/usr/lib/python2.7/site-packages/webob/dec.py", line 144, in __call__
    return resp(environ, start_response)
  File "/usr/lib/python2.7/site-packages/routes/middleware.py", line 131, in __call__
    response = self.app(environ, start_response)
  File "/usr/lib/python2.7/site-packages/webob/dec.py", line 144, in __call__
    return resp(environ, start_response)
  File "/usr/lib/python2.7/site-packages/webob/dec.py", line 130, in __call__
    resp = self.call_func(req, *args, **self.kwargs)
  File "/usr/lib/python2.7/site-packages/webob/dec.py", line 195, in call_func
    return self.func(req, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/glance/common/wsgi.py", line 644, in __call__
    request, **action_args)
  File "/usr/lib/python2.7/site-packages/glance/common/wsgi.py", line 668, in dispatch
    return method(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/glance/common/utils.py", line 436, in wrapped
    return func(self, req, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/glance/api/v1/images.py", line 791, in create
    image_meta = self._reserve(req, image_meta)
  File "/usr/lib/python2.7/site-packages/glance/api/v1/images.py", line 524, in _reserve
    image_meta = registry.add_image_metadata(req.context, image_meta)
  File "/usr/lib/python2.7/site-packages/glance/registry/client/v1/api.py", line 161, in add_image_metadata
    return c.add_image(image_meta)
  File "/usr/lib/python2.7/site-packages/glance/registry/client/v1/client.py", line 163, in add_image
    res = self.do_request("POST", "/images", body=body, headers=headers)
  File "/usr/lib/python2.7/site-packages/glance/registry/client/v1/client.py", line 107, in do_request
    **kwargs)
  File "/usr/lib/python2.7/site-packages/glance/common/client.py", line 69, in wrapped
    return func(self, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/glance/common/client.py", line 386, in do_request
    headers=copy.deepcopy(headers))
  File "/usr/lib/python2.7/site-packages/glance/common/client.py", line 83, in wrapped
    return func(self, method, url, body, headers)
  File "/usr/lib/python2.7/site-packages/glance/common/client.py", line 527, in _do_request
    raise exception.NotAuthenticated(res.read())
NotAuthenticated: Authentication required
2014-05-08 16:29:02.727 2875 INFO glance.wsgi.server [27b6562b-5cb5-4d80-ae46-620b2aa58374 0a003bee08a548ddb6bfb2f0871a7ca9 259a71bdc7864f34b2aac82ebea5f653 - - -] 192.168.80.140 - - [08/May/2014 16:29:02] "POST /v1/images HTTP/1.1" 500 139 0.335661

I can see the Authentication Required message, but I have successfully stored the admin credentials, I can check by using the keystone token-get function.

I have also checked that the ports are open and listening on 9191 and 9292:

controller:/tmp/images # netstat -aon | grep :9191
tcp        0      0 0.0.0.0:9191            0.0.0.0:*               LISTEN      off (0.00/0/0)
controller:/tmp/images # netstat -aon | grep :9292
tcp        0      0 0.0.0.0:9292            0.0.0.0:*               LISTEN      off (0.00/0/0)

I can tell I am just missing something silly, but I can't see! Any suggestions?

Thanks!