Running latest trunk, glance-cache-prefetcher exceptions when starting:
Traceback (most recent call last):
File "/usr/bin/glance-cache-prefetcher", line 65, in <module>
conf, app = config.load_paste_app('glance-prefetcher', options, args)
File "/usr/lib/pymodules/python2.6/glance/common/config.py", line 304, in load_paste_app
app = deploy.loadapp("config:%s" % conf_file, name=app_name)
File "/usr/lib/pymodules/python2.6/paste/deploy/loadwsgi.py", line 247, in loadapp
return loadobj(APP, uri, name=name, **kw)
File "/usr/lib/pymodules/python2.6/paste/deploy/loadwsgi.py", line 272, in loadobj
return context.create()
File "/usr/lib/pymodules/python2.6/paste/deploy/loadwsgi.py", line 710, in create
return self.object_type.invoke(self)
File "/usr/lib/pymodules/python2.6/paste/deploy/loadwsgi.py", line 146, in invoke
return fix_call(context.object, context.global_conf, **context.local_conf)
File "/usr/lib/pymodules/python2.6/paste/deploy/util.py", line 56, in fix_call
val = callable(*args, **kw)
File "/usr/lib/pymodules/python2.6/glance/image_cache/prefetcher.py", line 88, in app_factory
return Prefetcher(conf)
File "/usr/lib/pymodules/python2.6/glance/image_cache/prefetcher.py", line 41, in __init__
self.cache = ImageCache(options)
File "/usr/lib/pymodules/python2.6/glance/image_cache/__init__.py", line 39, in __init__
self.init_driver()
File "/usr/lib/pymodules/python2.6/glance/image_cache/__init__.py", line 59, in init_driver
self.configure_driver()
File "/usr/lib/pymodules/python2.6/glance/image_cache/__init__.py", line 68, in configure_driver
self.driver.configure()
File "/usr/lib/pymodules/python2.6/glance/image_cache/drivers/sqlite.py", line 97, in configure
self.set_paths()
File "/usr/lib/pymodules/python2.6/glance/image_cache/drivers/sqlite.py", line 105, in set_paths
self.incomplete_dir = os.path.join(self.base_dir, 'incomplete')
File "/usr/lib/python2.6/posixpath.py", line 67, in join
elif path == '' or path.endswith('/'):
AttributeError: 'NoneType' object has no attribute 'endswith'
This bug is caused by a missing 'image_cache_dir' option in glance-api.conf. Yes, you have to repeat the option in multiple config files. This specific case was caused by the older definition of 'image_ cache_datadir' . Note the difference between 'dir' and 'datadir'.