← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1231224] Re: No handlers could be found for logger "106_add_foreign_keys"

 

We don't have a 106_add_foreign_keys anymore. :)

** Changed in: nova
       Status: Triaged => Invalid

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1231224

Title:
  No handlers could be found for logger "106_add_foreign_keys"

Status in OpenStack Compute (Nova):
  Invalid

Bug description:
  I tried to run "nova-manage db sync" with mysql cluster, encounting
  the following errors, but the (most) tables were created.  the mysql
  process without cluster is ok!

  If I dump a normal nova database from mysql(without cluster), and then 
  mysql asdfsdfasdf < nova.sql,to write data to mysql cluster, this worked OK. A bug on sqlalchemy ?

  Software involved:
  nova-2012.2.5 (nova folsom)
  mysql cluster (mysql-5.6.11 ndb-7.3.2)
  MySQL_python-1.2.3
  sqlalchemy_migrate-0.7.2
  SQLAlchemy-0.7.9


  
  log:

  No handlers could be found for logger "106_add_foreign_keys"
  2013-09-26 02:09:23 17100 CRITICAL nova [-] (IntegrityError) (1215, 'Cannot add foreign key constraint') 'ALTER TABLE security_group_instance_association ADD CONSTRAINT security_group_instance_association_instance_uuid_fkey FOREIGN KEY(instance_uuid) REFERENCES instances (uuid)' ()
  2013-09-26 02:09:23 17100 TRACE nova Traceback (most recent call last):
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/bin/nova-manage", line 5, in <module>
  2013-09-26 02:09:23 17100 TRACE nova     pkg_resources.run_script('nova==2012.2.5', 'nova-manage')
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/distribute-0.6.28-py2.7.egg/pkg_resources.py", line 499, in run_script
  2013-09-26 02:09:23 17100 TRACE nova     self.require(requires)[0].run_script(script_name, ns)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/distribute-0.6.28-py2.7.egg/pkg_resources.py", line 1239, in run_script
  2013-09-26 02:09:23 17100 TRACE nova     execfile(script_filename, namespace, namespace)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/nova-2012.2.5-py2.7.egg/EGG-INFO/scripts/nova-manage", line 1404, in <module>
  2013-09-26 02:09:23 17100 TRACE nova     main()
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/nova-2012.2.5-py2.7.egg/EGG-INFO/scripts/nova-manage", line 1391, in main
  2013-09-26 02:09:23 17100 TRACE nova     fn(*fn_args, **fn_kwargs)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/nova-2012.2.5-py2.7.egg/EGG-INFO/scripts/nova-manage", line 760, in sync
  2013-09-26 02:09:23 17100 TRACE nova     return migration.db_sync(version)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/nova-2012.2.5-py2.7.egg/nova/db/migration.py", line 32, in db_sync
  2013-09-26 02:09:23 17100 TRACE nova     return IMPL.db_sync(version=version)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/nova-2012.2.5-py2.7.egg/nova/db/sqlalchemy/migration.py", line 79, in db_sync
  2013-09-26 02:09:23 17100 TRACE nova     return versioning_api.upgrade(get_engine(), repository, version)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/sqlalchemy_migrate-0.7.2-py2.7.egg/migrate/versioning/api.py", line 186, in upgrade
  2013-09-26 02:09:23 17100 TRACE nova     return _migrate(url, repository, version, upgrade=True, err=err, **opts)
  2013-09-26 02:09:23 17100 TRACE nova   File "<string>", line 2, in _migrate
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/nova-2012.2.5-py2.7.egg/nova/db/sqlalchemy/migration.py", line 44, in patched_with_engine
  2013-09-26 02:09:23 17100 TRACE nova     return f(*a, **kw)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/sqlalchemy_migrate-0.7.2-py2.7.egg/migrate/versioning/api.py", line 366, in _migrate
  2013-09-26 02:09:23 17100 TRACE nova     schema.runchange(ver, change, changeset.step)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/sqlalchemy_migrate-0.7.2-py2.7.egg/migrate/versioning/schema.py", line 91, in runchange
  2013-09-26 02:09:23 17100 TRACE nova     change.run(self.engine, step)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/sqlalchemy_migrate-0.7.2-py2.7.egg/migrate/versioning/script/py.py", line 145, in run
  2013-09-26 02:09:23 17100 TRACE nova     script_func(engine)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/nova-2012.2.5-py2.7.egg/nova/db/sqlalchemy/migrate_repo/versions/106_add_foreign_keys.py", line 43, in upgrade
  2013-09-26 02:09:23 17100 TRACE nova     refcolumns=[instances.c.uuid]).create()
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/sqlalchemy_migrate-0.7.2-py2.7.egg/migrate/changeset/constraint.py", line 44, in create
  2013-09-26 02:09:23 17100 TRACE nova     self.__do_imports('constraintgenerator', *a, **kw)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/sqlalchemy_migrate-0.7.2-py2.7.egg/migrate/changeset/constraint.py", line 32, in __do_imports
  2013-09-26 02:09:23 17100 TRACE nova     run_single_visitor(engine, visitorcallable, self, *a, **kw)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/sqlalchemy_migrate-0.7.2-py2.7.egg/migrate/changeset/databases/visitor.py", line 75, in run_single_visitor
  2013-09-26 02:09:23 17100 TRACE nova     fn(element, **kwargs)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/sqlalchemy_migrate-0.7.2-py2.7.egg/migrate/changeset/ansisql.py", line 266, in visit_migrate_foreign_key_constraint
  2013-09-26 02:09:23 17100 TRACE nova     self._visit_constraint(*p, **k)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/sqlalchemy_migrate-0.7.2-py2.7.egg/migrate/changeset/ansisql.py", line 278, in _visit_constraint
  2013-09-26 02:09:23 17100 TRACE nova     self.execute()
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/sqlalchemy_migrate-0.7.2-py2.7.egg/migrate/changeset/ansisql.py", line 42, in execute
  2013-09-26 02:09:23 17100 TRACE nova     return self.connection.execute(self.buffer.getvalue())
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/SQLAlchemy-0.7.9-py2.7-linux-mips64.egg/sqlalchemy/engine/base.py", line 1449, in execute
  2013-09-26 02:09:23 17100 TRACE nova     params)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/SQLAlchemy-0.7.9-py2.7-linux-mips64.egg/sqlalchemy/engine/base.py", line 1628, in _execute_text
  2013-09-26 02:09:23 17100 TRACE nova     statement, parameters
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/SQLAlchemy-0.7.9-py2.7-linux-mips64.egg/sqlalchemy/engine/base.py", line 1698, in _execute_context
  2013-09-26 02:09:23 17100 TRACE nova     context)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/SQLAlchemy-0.7.9-py2.7-linux-mips64.egg/sqlalchemy/engine/base.py", line 1691, in _execute_context
  2013-09-26 02:09:23 17100 TRACE nova     context)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/SQLAlchemy-0.7.9-py2.7-linux-mips64.egg/sqlalchemy/engine/default.py", line 331, in do_execute
  2013-09-26 02:09:23 17100 TRACE nova     cursor.execute(statement, parameters)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/MySQL_python-1.2.3-py2.7-linux-mips64.egg/MySQLdb/cursors.py", line 174, in execute
  2013-09-26 02:09:23 17100 TRACE nova     self.errorhandler(self, exc, value)
  2013-09-26 02:09:23 17100 TRACE nova   File "/usr/local/lib/python2.7/dist-packages/MySQL_python-1.2.3-py2.7-linux-mips64.egg/MySQLdb/connections.py", line 36, in defaulterrorhandler
  2013-09-26 02:09:23 17100 TRACE nova     raise errorclass, errorvalue
  2013-09-26 02:09:23 17100 TRACE nova IntegrityError: (IntegrityError) (1215, 'Cannot add foreign key constraint') 'ALTER TABLE security_group_instance_association ADD CONSTRAINT security_group_instance_association_instance_uuid_fkey FOREIGN KEY(instance_uuid) REFERENCES instances (uuid)' ()
  2013-09-26 02:09:23 17100 TRACE nova
  Command failed, please check log for more info

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