OpenStack Image Registry and Delivery Service (Glance)

glance-cache-prefetcher causes Unknown Scheme errors when using 'file://' images

Reported by Dan Prince on 2011-11-10
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Glance
Critical
Rick Harris
Diablo
Undecided
Unassigned

Bug Description

Trying to prefetch an image. When I run glance-cache-prefetcher after queing an image for prefetching I'm getting the following error:

root@glance1:~# glance-cache-prefetcher --config-file=/etc/glance/glance-cache.conf
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/eventlet/hubs/hub.py", line 336, in fire_timers
    timer()
  File "/usr/lib/python2.7/dist-packages/eventlet/hubs/timer.py", line 56, in __call__
    cb(*args, **kw)
  File "/usr/lib/python2.7/dist-packages/eventlet/greenthread.py", line 192, in main
    result = function(*args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/glance/image_cache/prefetcher.py", line 58, in fetch_image_into_cache
    options=self.options)
  File "/usr/lib/python2.7/dist-packages/glance/store/__init__.py", line 128, in get_from_backend
    store = get_store_from_uri(uri)
  File "/usr/lib/python2.7/dist-packages/glance/store/__init__.py", line 122, in get_store_from_uri
    return get_store_from_scheme(scheme)
  File "/usr/lib/python2.7/dist-packages/glance/store/__init__.py", line 110, in get_store_from_scheme
    raise exception.UnknownScheme(scheme)
UnknownScheme: Unknown scheme '%(scheme)s' found in URI
Details: file
Traceback (most recent call last):
  File "/usr/bin/glance-cache-prefetcher", line 64, in <module>
    app.run()
  File "/usr/lib/python2.7/dist-packages/glance/image_cache/prefetcher.py", line 75, in run
    successes = sum([1 for r in results if r is True])
  File "/usr/lib/python2.7/dist-packages/eventlet/greenpool.py", line 232, in next
    val = self.waiters.get().wait()
  File "/usr/lib/python2.7/dist-packages/eventlet/greenthread.py", line 166, in wait
    return self._exit_event.wait()
  File "/usr/lib/python2.7/dist-packages/eventlet/event.py", line 120, in wait
    current.throw(*self._exc)
  File "/usr/lib/python2.7/dist-packages/eventlet/greenthread.py", line 192, in main
    result = function(*args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/glance/image_cache/prefetcher.py", line 58, in fetch_image_into_cache
    options=self.options)
  File "/usr/lib/python2.7/dist-packages/glance/store/__init__.py", line 128, in get_from_backend
    store = get_store_from_uri(uri)
  File "/usr/lib/python2.7/dist-packages/glance/store/__init__.py", line 122, in get_store_from_uri
    return get_store_from_scheme(scheme)
  File "/usr/lib/python2.7/dist-packages/glance/store/__init__.py", line 110, in get_store_from_scheme
    raise exception.UnknownScheme(scheme)
glance.common.exception.UnknownScheme: Unknown scheme '%(scheme)s' found in URI
Details: file

Changed in glance:
assignee: nobody → Rick Harris (rconradharris)
importance: Undecided → Critical
status: New → In Progress
Jay Pipes (jaypipes) wrote :

FYI, the fix for this should just be importing the glance.store.X modules in the cache prefetcher.

Changed in glance:
milestone: none → essex-2

Reviewed: https://review.openstack.org/1556
Committed: http://github.com/openstack/glance/commit/f394327f3869b8b820f1fdd345c7e6073dd82820
Submitter: Jenkins
Branch: master

 status fixcommitted
 done

commit f394327f3869b8b820f1fdd345c7e6073dd82820
Author: Rick Harris <email address hidden>
Date: Fri Nov 11 18:39:31 2011 +0000

    Making prefetcher call create_stores.

    Fixes bug 888383

    Change-Id: Ia3adc6a30f16f889cd344f8cb3fca4a071871fe4

Changed in glance:
status: In Progress → Fix Committed

Reviewed: https://review.openstack.org/1785
Committed: http://github.com/openstack/glance/commit/3f08f394ee9b3badcd027fc7881548f270442670
Submitter: Jenkins
Branch: stable/diablo

 tag in-stable-diablo
 done

commit 3f08f394ee9b3badcd027fc7881548f270442670
Author: Rick Harris <email address hidden>
Date: Fri Nov 11 18:39:31 2011 +0000

    Making prefetcher call create_stores.

    Fixes bug 888383

    (cherry picked from commit f394327f3869b8b820f1fdd345c7e6073dd82820)

    Change-Id: Ia3adc6a30f16f889cd344f8cb3fca4a071871fe4

Thierry Carrez (ttx) on 2011-12-14
Changed in glance:
status: Fix Committed → Fix Released
Thierry Carrez (ttx) on 2012-04-05
Changed in glance:
milestone: essex-2 → 2012.1
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers