Can not upload UEC_image to Glance...

Bug #801436 reported by Hugo Kou
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Glance
Invalid
Undecided
Unassigned

Bug Description

Using "uec-publish-tarball" for images....
Host : Natty b64 server
Nova version : 2011.3~d2~20110621.1202-0ubuntu0ppa1~natty2
Glance version : 2011.3~d2~20110621.141-0ubuntu0ppa1~natty1

TTY image could be upload and fire up correctly .....
But UEC image failed_upload and the size of ami is 0.

#euca-describe-images
IMAGE ami-00000005 MAV_1/maverick-server-uec-amd64.img.manifest.xml failed_upload public x86_64 machine aki-00000004

#glance index
Found 5 public images...
ID Name Disk Format Container Format Size
---------------- ------------------------------ -------------------- -------------------- --------------
5 None ami ami 0
4 None aki aki 4408496

Tried images both b64 / b32
http://uec-images.ubuntu.com/maverick/current/
http://uec-images.ubuntu.com/natty/current/

Revision history for this message
Jay Pipes (jaypipes) wrote :

Hi! Could you please let me know what version of python-webob you have? I think you may be experiencing this bug: https://bitbucket.org/ianb/webob/issue/12/fix-for-issue-6-broke-chunked-transfer ...

Jay Pipes (jaypipes)
Changed in glance:
status: New → Incomplete
Revision history for this message
Hugo Kou (tonytkdk) wrote :

Hello Jay P.

There's the version of python-webob

ii python-webob 1.0.8-0~ppanatty1 Python module providing WSGI request and response objects

Revision history for this message
Hugo Kou (tonytkdk) wrote :

After checked
https://bugs.launchpad.net/glance/+bug/799008

Is that same issue ?

But the version of python-webob is 1.0.8 in my environment .

Revision history for this message
Hugo Kou (tonytkdk) wrote :
Download full text (3.5 KiB)

More clue...
Tried to add image with glance CLI tool....

==================================
root@api001:~/image/maver# glance add name="TEST_MAV" is_public=true disk_format=aki container_format=aki < maverick-server-uec-amd64-vmlinuz-virtual
Added new image with ID: 10
==================================
ID Name Disk Format Container Format Size
---------------- ------------------------------ -------------------- -------------------- --------------
10 TEST_MAV aki aki 4408496
==================================

But while I add ami , there's got some error , I believe that will help.....

=================================
# glance add name="TEST_MAV_AMI" is_public=true disk_format=ami container_format=ami kernel_id=10 < maverick-server-uec-amd64.img

[TRACE]
Internal Server error: Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/eventlet/wsgi.py", line 336, in handle_one_response
    result = self.application(self.environ, start_response)
  File "/usr/lib/pymodules/python2.7/webob/dec.py", line 147, in __call__
    resp = self.call_func(req, *args, **self.kwargs)
  File "/usr/lib/pymodules/python2.7/webob/dec.py", line 208, in call_func
    return self.func(req, *args, **kwargs)
  File "/usr/lib/pymodules/python2.7/glance/common/wsgi.py", line 113, in __call__
    response = req.get_response(self.application)
  File "/usr/lib/pymodules/python2.7/webob/request.py", line 1053, in get_response
    application, catch_exc_info=False)
  File "/usr/lib/pymodules/python2.7/webob/request.py", line 1022, in call_application
    app_iter = application(self.environ, start_response)
  File "/usr/lib/pymodules/python2.7/webob/dec.py", line 159, in __call__
    return resp(environ, start_response)
  File "/usr/lib/pymodules/python2.7/routes/middleware.py", line 131, in __call__
    response = self.app(environ, start_response)
  File "/usr/lib/pymodules/python2.7/webob/dec.py", line 159, in __call__
    return resp(environ, start_response)
  File "/usr/lib/pymodules/python2.7/webob/dec.py", line 147, in __call__
    resp = self.call_func(req, *args, **self.kwargs)
  File "/usr/lib/pymodules/python2.7/webob/dec.py", line 208, in call_func
    return self.func(req, *args, **kwargs)
  File "/usr/lib/pymodules/python2.7/glance/common/wsgi.py", line 307, in __call__
    action, request)
  File "/usr/lib/pymodules/python2.7/glance/common/wsgi.py", line 328, in dispatch
    return method(*args, **kwargs)
  File "/usr/lib/pymodules/python2.7/glance/api/v1/images.py", line 517, in create
    return self._deserialize(request)
  File "/usr/lib/pymodules/python2.7/glance/api/v1/images.py", line 512, in _deserialize
    data = request.body if self.has_body(request) else None
  File "/usr/lib/pymodules/python2.7/webob/request.py", line 483, in _body__get
    self.make_body_seekable() # we need this to have content_length
  File "/usr/lib/pymodules/python2.7/webob/request.py", line 739, in make_body_seekable
    self.copy_body()
  File "/usr/lib/pymodules/python2.7/webob/request.py", line 755, in copy_body
    self.bod...

Read more...

Revision history for this message
Jay Pipes (jaypipes) wrote : Re: [Bug 801436] Re: Can not upload UEC_image to Glance...
Download full text (4.1 KiB)

Hi again Hugo!

OK, this should be fixed now. Please update Glance and try this again.

Cheers!
jay

On Mon, Jun 27, 2011 at 12:05 AM, Hugo Kou <email address hidden> wrote:
> More clue...
> Tried to add image with glance CLI tool....
>
> ==================================
> root@api001:~/image/maver# glance add name="TEST_MAV" is_public=true disk_format=aki container_format=aki < maverick-server-uec-amd64-vmlinuz-virtual
> Added new image with ID: 10
> ==================================
> ID               Name                           Disk Format          Container Format     Size
> ---------------- ------------------------------ -------------------- -------------------- --------------
> 10               TEST_MAV                       aki                  aki                         4408496
> ==================================
>
>
> But while I add ami , there's got some error , I believe that will help.....
>
> =================================
> # glance add name="TEST_MAV_AMI" is_public=true disk_format=ami container_format=ami kernel_id=10 < maverick-server-uec-amd64.img
>
> [TRACE]
> Internal Server error: Traceback (most recent call last):
>  File "/usr/lib/python2.7/dist-packages/eventlet/wsgi.py", line 336, in handle_one_response
>    result = self.application(self.environ, start_response)
>  File "/usr/lib/pymodules/python2.7/webob/dec.py", line 147, in __call__
>    resp = self.call_func(req, *args, **self.kwargs)
>  File "/usr/lib/pymodules/python2.7/webob/dec.py", line 208, in call_func
>    return self.func(req, *args, **kwargs)
>  File "/usr/lib/pymodules/python2.7/glance/common/wsgi.py", line 113, in __call__
>    response = req.get_response(self.application)
>  File "/usr/lib/pymodules/python2.7/webob/request.py", line 1053, in get_response
>    application, catch_exc_info=False)
>  File "/usr/lib/pymodules/python2.7/webob/request.py", line 1022, in call_application
>    app_iter = application(self.environ, start_response)
>  File "/usr/lib/pymodules/python2.7/webob/dec.py", line 159, in __call__
>    return resp(environ, start_response)
>  File "/usr/lib/pymodules/python2.7/routes/middleware.py", line 131, in __call__
>    response = self.app(environ, start_response)
>  File "/usr/lib/pymodules/python2.7/webob/dec.py", line 159, in __call__
>    return resp(environ, start_response)
>  File "/usr/lib/pymodules/python2.7/webob/dec.py", line 147, in __call__
>    resp = self.call_func(req, *args, **self.kwargs)
>  File "/usr/lib/pymodules/python2.7/webob/dec.py", line 208, in call_func
>    return self.func(req, *args, **kwargs)
>  File "/usr/lib/pymodules/python2.7/glance/common/wsgi.py", line 307, in __call__
>    action, request)
>  File "/usr/lib/pymodules/python2.7/glance/common/wsgi.py", line 328, in dispatch
>    return method(*args, **kwargs)
>  File "/usr/lib/pymodules/python2.7/glance/api/v1/images.py", line 517, in create
>    return self._deserialize(request)
>  File "/usr/lib/pymodules/python2.7/glance/api/v1/images.py", line 512, in _deserialize
>    data = request.body if self.has_body(request) else None
>  File "/usr/lib/pymodules/python2.7/webob/request.py", line 483, in _body__get
>    self.make_body_see...

Read more...

Revision history for this message
Hugo Kou (tonytkdk) wrote :

Hello Jap P.

There's a report.
Is the "fix" version number 2011.3~d2~20110624.142-0ubuntu0ppa1~natty or 2011.3~d2~20110627.145-0ubuntu0ppa1~natty1

The latest update with trunk PPA will get version 142...... And the issue is still same with version 141 , failed to upload UEC image.

Could u plz tell me which change is for this issue?
http://bazaar.launchpad.net/~hudson-openstack/glance/trunk/changes/145?start_revid=145

Cheers
Hugo Kuo

Revision history for this message
Jay Pipes (jaypipes) wrote :

Hi!

There was a bug in Glance where the request body attribute was being
read accidentally, resulting in Glance attempting to read the entire
disk file into memory instead of iterating over chunks of the disk
file. This was fixed in r145:

http://bazaar.launchpad.net/~hudson-openstack/glance/trunk/revision/145

Please let us know after updating to trunk if this fixes your issues.
From looking at your stack trace, I believe it will.

Cheers,
jay

On Mon, Jun 27, 2011 at 8:23 PM, Hugo Kou <email address hidden> wrote:
> Hello Jap P.
>
> There's a report.
> Is the "fix" version number 2011.3~d2~20110624.142-0ubuntu0ppa1~natty  or  2011.3~d2~20110627.145-0ubuntu0ppa1~natty1
>
> The latest update with trunk PPA will get version 142...... And the
> issue is still same with version 141 , failed to upload UEC image.
>
> Could u plz tell me which change is for this issue?
> http://bazaar.launchpad.net/~hudson-openstack/glance/trunk/changes/145?start_revid=145
>
> Cheers
> Hugo Kuo
>
> --
> You received this bug notification because you are a member of Glance
> Bug Team, which is subscribed to Glance.
> https://bugs.launchpad.net/bugs/801436
>
> Title:
>  Can not upload UEC_image to Glance...
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/glance/+bug/801436/+subscriptions
>

Revision history for this message
Hugo Kou (tonytkdk) wrote :

Hello , Jay

Due to the trunk is not available yet.... apt-get will get 142version.

SO , I direct to rewrite the code as the r145 description.

And it works now.

Keep testing for more bug report.

Cheers
Hugo Kuo

Revision history for this message
Thierry Carrez (ttx) wrote :

Glance PPA build is now fixed (a new build dependency - python-httplib2 - was added while the packagers were looking in the other direction)

Jay Pipes (jaypipes)
Changed in glance:
status: Incomplete → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.