← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1664495] [NEW] Got ImportError: No module named setup when migrate db

 

Public bug reported:

ENV: deploy neutron newton branch by using Kolla.

when running

    neutron-db-manage --config-file /etc/neutron/neutron.conf --config-
file /etc/neutron/plugins/ml2/ml2_conf.ini upgrade head

Get following

2017-02-14 09:23:22.518158 | INFO:__main__:Writing out command to execute
2017-02-14 09:23:22.518175 | Traceback (most recent call last):
2017-02-14 09:23:22.518202 |   File "/var/lib/kolla/venv/bin/neutron-db-manage", line 10, in <module>
2017-02-14 09:23:22.518215 |     sys.exit(main())
2017-02-14 09:23:22.518251 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/neutron/db/migration/cli.py", line 686, in main
2017-02-14 09:23:22.518278 |     return_val |= bool(CONF.command.func(config, CONF.command.name))
2017-02-14 09:23:22.518316 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/neutron/db/migration/cli.py", line 205, in do_upgrade
2017-02-14 09:23:22.518334 |     run_sanity_checks(config, revision)
2017-02-14 09:23:22.518400 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/neutron/db/migration/cli.py", line 670, in run_sanity_checks
2017-02-14 09:23:22.518414 |     script_dir.run_env()
2017-02-14 09:23:22.518447 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/alembic/script/base.py", line 407, in run_env
2017-02-14 09:23:22.518466 |     util.load_python_file(self.dir, 'env.py')
2017-02-14 09:23:22.518501 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/alembic/util/pyfiles.py", line 93, in load_python_file
2017-02-14 09:23:22.518603 |     module = load_module_py(module_id, path)
2017-02-14 09:23:22.518647 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/alembic/util/compat.py", line 79, in load_module_py
2017-02-14 09:23:22.518677 |     mod = imp.load_source(module_id, path, fp)
2017-02-14 09:23:22.518719 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/neutron/db/migration/alembic_migrations/env.py", line 24, in <module>
2017-02-14 09:23:22.518742 |     from neutron.db.migration.models import head  # noqa
2017-02-14 09:23:22.518780 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/neutron/db/migration/models/head.py", line 65, in <module>
2017-02-14 09:23:22.518806 |     utils.import_modules_recursively(os.path.dirname(models.__file__))
2017-02-14 09:23:22.518846 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/neutron/common/utils.py", line 865, in import_modules_recursively
2017-02-14 09:23:22.518867 |     modules.extend(import_modules_recursively(dir_))
2017-02-14 09:23:22.518907 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/neutron/common/utils.py", line 861, in import_modules_recursively
2017-02-14 09:23:22.518924 |     importlib.import_module(module)
2017-02-14 09:23:22.518975 |   File "/usr/lib64/python2.7/importlib/__init__.py", line 37, in import_module
2017-02-14 09:23:22.518993 |     __import__(name)
2017-02-14 09:23:22.519010 | ImportError: No module named setup

[0] http://logs.openstack.org/07/433507/1/check/gate-kolla-dsvm-deploy-centos-source-centos-7-nv/80744bf/console.html#_2017-02-14_09_23_22_503742
[1] https://github.com/openstack/kolla/blob/stable/newton/docker/neutron/neutron-server/extend_start.sh#L6

** Affects: neutron
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/1664495

Title:
  Got ImportError: No module named setup when migrate db

Status in neutron:
  New

Bug description:
  ENV: deploy neutron newton branch by using Kolla.

  when running

      neutron-db-manage --config-file /etc/neutron/neutron.conf
  --config-file /etc/neutron/plugins/ml2/ml2_conf.ini upgrade head

  Get following

  2017-02-14 09:23:22.518158 | INFO:__main__:Writing out command to execute
  2017-02-14 09:23:22.518175 | Traceback (most recent call last):
  2017-02-14 09:23:22.518202 |   File "/var/lib/kolla/venv/bin/neutron-db-manage", line 10, in <module>
  2017-02-14 09:23:22.518215 |     sys.exit(main())
  2017-02-14 09:23:22.518251 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/neutron/db/migration/cli.py", line 686, in main
  2017-02-14 09:23:22.518278 |     return_val |= bool(CONF.command.func(config, CONF.command.name))
  2017-02-14 09:23:22.518316 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/neutron/db/migration/cli.py", line 205, in do_upgrade
  2017-02-14 09:23:22.518334 |     run_sanity_checks(config, revision)
  2017-02-14 09:23:22.518400 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/neutron/db/migration/cli.py", line 670, in run_sanity_checks
  2017-02-14 09:23:22.518414 |     script_dir.run_env()
  2017-02-14 09:23:22.518447 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/alembic/script/base.py", line 407, in run_env
  2017-02-14 09:23:22.518466 |     util.load_python_file(self.dir, 'env.py')
  2017-02-14 09:23:22.518501 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/alembic/util/pyfiles.py", line 93, in load_python_file
  2017-02-14 09:23:22.518603 |     module = load_module_py(module_id, path)
  2017-02-14 09:23:22.518647 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/alembic/util/compat.py", line 79, in load_module_py
  2017-02-14 09:23:22.518677 |     mod = imp.load_source(module_id, path, fp)
  2017-02-14 09:23:22.518719 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/neutron/db/migration/alembic_migrations/env.py", line 24, in <module>
  2017-02-14 09:23:22.518742 |     from neutron.db.migration.models import head  # noqa
  2017-02-14 09:23:22.518780 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/neutron/db/migration/models/head.py", line 65, in <module>
  2017-02-14 09:23:22.518806 |     utils.import_modules_recursively(os.path.dirname(models.__file__))
  2017-02-14 09:23:22.518846 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/neutron/common/utils.py", line 865, in import_modules_recursively
  2017-02-14 09:23:22.518867 |     modules.extend(import_modules_recursively(dir_))
  2017-02-14 09:23:22.518907 |   File "/var/lib/kolla/venv/lib/python2.7/site-packages/neutron/common/utils.py", line 861, in import_modules_recursively
  2017-02-14 09:23:22.518924 |     importlib.import_module(module)
  2017-02-14 09:23:22.518975 |   File "/usr/lib64/python2.7/importlib/__init__.py", line 37, in import_module
  2017-02-14 09:23:22.518993 |     __import__(name)
  2017-02-14 09:23:22.519010 | ImportError: No module named setup

  [0] http://logs.openstack.org/07/433507/1/check/gate-kolla-dsvm-deploy-centos-source-centos-7-nv/80744bf/console.html#_2017-02-14_09_23_22_503742
  [1] https://github.com/openstack/kolla/blob/stable/newton/docker/neutron/neutron-server/extend_start.sh#L6

To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/1664495/+subscriptions


Follow ups