"ImportError: No module named config": Installing virtualenv sahara on Ubuntu 14.04

asked 2015-07-29 10:57:14 -0600

Michael Steffens gravatar image

I'm facing the same issue the one answered in https://ask.openstack.org/en/question.... As recommended in the current Sahara installation guide I'm using a Python virtual environment, however. Trying to set up the DB then results in pretty much the same failure:

root@cloudcont1:/opt# sahara-venv/bin/sahara-db-manage --config-file sahara-venv/etc/sahara.conf upgrade head
Traceback (most recent call last):
  File "sahara-venv/bin/sahara-db-manage", line 7, in <module>
    from sahara.db.migration.cli import main
  File "/opt/sahara-venv/local/lib/python2.7/site-packages/sahara/db/__init__.py", line 20, in <module>
    from sahara.db.api import *  # noqa
  File "/opt/sahara-venv/local/lib/python2.7/site-packages/sahara/db/api.py", line 34, in <module>
    from oslo.config import cfg
ImportError: No module named config

However, reinstalling doesn't fix anything, as

root@cloudcont1:/opt# sahara-venv/bin/pip install oslo.config

results in package files being placed into


Please note the underscore separating "oslo" and "config", rather than a proper path separator.

This is probably the reason why the module isn't found, isn't it? But why does the virtualenv pip produce it, and how can I fix it?

edit retag flag offensive close merge delete