UnicodeEncodeError when snapshotting an instance or uploading an image (Essex)
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Glance |
Won't Fix
|
Medium
|
Unassigned | ||
OpenStack Compute (nova) |
Invalid
|
Medium
|
Unassigned |
Bug Description
Hi,
With the last Essex packages on Ubuntu, I'am not able to give a name on a snapshot with an accented character.
Command:
nova image-create c67bb8ea-
returns:
ERROR: The server has either erred or is incapable of performing the requested operation. (HTTP 500)
Nova API logs :
2012-06-05 14:19:02 DEBUG nova.image.glance [req-82eba2b0-
2012-06-05 14:19:02 DEBUG nova.image.glance [req-82eba2b0-
2012-06-05 14:19:02 ERROR nova.api.openstack [req-82eba2b0-
2012-06-05 14:19:02 TRACE nova.api.openstack Traceback (most recent call last):
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack return req.get_
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack application, catch_exc_
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack app_iter = application(
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack return self.app(env, start_response)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack return resp(environ, start_response)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack return resp(environ, start_response)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack return resp(environ, start_response)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack response = self.app(environ, start_response)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack return resp(environ, start_response)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack resp = self.call_func(req, *args, **self.kwargs)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack return self.func(req, *args, **kwargs)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack content_type, body, accept)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack action_result = self.dispatch(meth, request, action_args)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack return method(req=request, **action_args)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack return f(*args, **kwargs)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack extra_propertie
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack return func(self, context, target, *args, **kwargs)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack return f(self, context, instance, *args, **kw)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack extra_propertie
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack recv_meta = self.image_
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack sent_service_
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack res = self.do_
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack return func(self, *args, **kwargs)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack headers=headers)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack return func(self, method, url, body, headers)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack c.request(method, path, body, headers)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack self._send_
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack self.putheader(hdr, value)
2012-06-05 14:19:02 TRACE nova.api.openstack File "/usr/lib/
2012-06-05 14:19:02 TRACE nova.api.openstack hdr = '%s: %s' % (header, '\r\n\t'
2012-06-05 14:19:02 TRACE nova.api.openstack UnicodeEncodeError: 'ascii' codec can't encode character u'\xe9' in position 5: ordinal not in range(128)
2012-06-05 14:19:02 TRACE nova.api.openstack
2012-06-05 14:19:02 INFO nova.api.openstack [req-82eba2b0-
Changed in nova: | |
status: | Confirmed → Invalid |
Besides snapshot creation, I'm not able to upload an image with accented character too.
For example:
glance add name="测试VM" is_public=true container_ format= ovf disk_format=qcow2 < ~/Downloads/ precise- server- cloudimg- amd64-disk1. img
Output:
Failed to add image. Got error:
'ascii' codec can't decode byte 0xe6 in position 0: ordinal not in range(128)
Note: Your image metadata may still be in the registry, but the image's status will likely be 'killed'.