hook failed: "shared-db-relation-changed" for mysql:shared-db

Bug #1386615 reported by neel
14
This bug affects 3 people
Affects Status Importance Assigned to Milestone
mysql (Juju Charms Collection)
New
Undecided
Unassigned

Bug Description

using juju to setup openstack

node0 (bootstrap node):
juju-gui, glance, cinder, keystone, rabitmq, mysql

node2:
nova-cloud-controller

juju deployed all charms successfully. (no lxc, kvm involved)

`juju add-relation nova-cloud-controller mysql` fails with error
    hook failed: "shared-db-relation-changed" for mysql:shared-db

Tried to place mysql and nova-cloud-controller in different bare metals

node0 (bootstrap node):
  juju-gui, glance, cinder, keystone, rabitmq

node2:
  mysql

node3:
  nova-cloud-controller

problem persists `juju add-relation nova-cloud-controller mysql` fails with error
    hook failed: "shared-db-relation-changed" for mysql:shared-db

juju debug-log reports https://gist.github.com/anonymous/5fb4cc40bbc94bc1ff58

unit-nova-cloud-controller-0: 2014-10-28 11:31:52 DEBUG worker.uniter.jujuc server.go:103 hook context id "nova-cloud-controller/0:shared-db-relation-changed:2618249070094040128"; dir "/var/lib/juju/agents/unit-nova-cloud-controller-0/charm"
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO juju-log shared-db:35: Migrating the nova database.
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 DEBUG nova.utils [-] backend <module 'nova.db.sqlalchemy.migration' from '/usr/lib/python2.7/dist-packages/nova/db/sqlalchemy/migration.pyc'> from (pid=7058) __get_backend /usr/lib/python2.7/dist-packages/nova/utils.py:663
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 CRITICAL nova [-] zone_name
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova Traceback (most recent call last):
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova File "/usr/bin/nova-manage", line 1746, in <module>
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova main()
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova File "/usr/bin/nova-manage", line 1733, in main
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova fn(*fn_args, **fn_kwargs)
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova File "/usr/bin/nova-manage", line 1102, in sync
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova return migration.db_sync(version)
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova File "/usr/lib/python2.7/dist-packages/nova/db/migration.py", line 30, in db_sync
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova return IMPL.db_sync(version=version)
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova File "/usr/lib/python2.7/dist-packages/nova/db/sqlalchemy/migration.py", line 53, in db_sync
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova versioning_api.upgrade(FLAGS.sql_connection, repo_path, version)
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova File "/usr/lib/python2.7/dist-packages/migrate/versioning/api.py", line 186, in upgrade
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova return _migrate(url, repository, version, upgrade=True, err=err, **opts)
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova File "<string>", line 2, in _migrate
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova File "/usr/lib/python2.7/dist-packages/migrate/versioning/util/__init__.py", line 159, in with_engine
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova return f(*a, **kw)
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova File "/usr/lib/python2.7/dist-packages/migrate/versioning/api.py", line 366, in _migrate
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova schema.runchange(ver, change, changeset.step)
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova File "/usr/lib/python2.7/dist-packages/migrate/versioning/schema.py", line 91, in runchange
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova change.run(self.engine, step)
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova File "/usr/lib/python2.7/dist-packages/migrate/versioning/script/py.py", line 145, in run
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova script_func(engine)
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova File "/usr/lib/python2.7/dist-packages/nova/db/sqlalchemy/migrate_repo/versions/082_zone_to_cell.py", line 22, in upgrade
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova zone_name = instances.c.zone_name
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova File "/usr/lib/python2.7/dist-packages/sqlalchemy/util/_collections.py", line 106, in __getattr__
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova raise AttributeError(key)
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova AttributeError: zone_name
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed 2014-10-28 11:31:52 TRACE nova
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed Traceback (most recent call last):
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed File "/var/lib/juju/agents/unit-nova-cloud-controller-0/charm/hooks/shared-db-relation-changed", line 860, in <module>
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed main()
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed File "/var/lib/juju/agents/unit-nova-cloud-controller-0/charm/hooks/shared-db-relation-changed", line 854, in main
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed hooks.execute(sys.argv)
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed File "/var/lib/juju/agents/unit-nova-cloud-controller-0/charm/hooks/charmhelpers/core/hookenv.py", line 502, in execute
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed self._hooks[hook_name]()
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed File "/var/lib/juju/agents/unit-nova-cloud-controller-0/charm/hooks/nova_cc_utils.py", line 901, in wrapped_f
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed f(*args)
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed File "/var/lib/juju/agents/unit-nova-cloud-controller-0/charm/hooks/charmhelpers/core/host.py", line 268, in wrapped_f
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed f(*args)
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed File "/var/lib/juju/agents/unit-nova-cloud-controller-0/charm/hooks/shared-db-relation-changed", line 289, in db_changed
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed migrate_nova_database()
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed File "/var/lib/juju/agents/unit-nova-cloud-controller-0/charm/hooks/nova_cc_utils.py", line 571, in migrate_nova_database
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed subprocess.check_output(cmd)
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed File "/usr/lib/python2.7/subprocess.py", line 544, in check_output
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed raise CalledProcessError(retcode, cmd, output=output)
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO shared-db-relation-changed subprocess.CalledProcessError: Command '['nova-manage', 'db', 'sync']' returned non-zero exit status 1
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 ERROR juju.worker.uniter uniter.go:486 hook failed: exit status 1
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 DEBUG juju.worker.uniter modes.go:398 ModeAbide exiting
unit-nova-cloud-controller-0: 2014-10-28 11:31:52 INFO juju.worker.uniter modes.go:396 ModeHookError starting
unit-nova-cloud-controller-0: 2014-10-28 11:31:53 DEBUG juju.worker.uniter.filter filter.go:421 want resolved event
unit-nova-cloud-controller-0: 2014-10-28 11:31:53 DEBUG juju.worker.uniter.filter filter.go:415 want forced upgrade true
unit-nova-cloud-controller-0: 2014-10-28 11:31:53 DEBUG juju.worker.uniter.filter filter.go:521 no new charm event
machine-0: 2014-10-28 17:01:48 DEBUG juju.state.apiserver apiserver.go:157 -> [4] machine-0 59.999673025s {"RequestId":4966,"Response":{}} N
machine-0: 2014-10-28 17:01:48 DEBUG juju.state.apiserver apiserver.go:150 <- [4] machine-0 {"RequestId":4969,"Type":"NotifyWatcher","Id":"1}}
machine-0: 2014-10-28 17:01:48 DEBUG juju.state.apiserver apiserver.go:150 <- [4] machine-0 {"RequestId":4970,"Type":"Provisioner","Request","Params":{}}
machine-0: 2014-10-28 17:01:48 DEBUG juju.state.apiserver apiserver.go:157 -> [4] machine-0 2.490419ms {"RequestId":4970,"Response":{"ResultinesWithTransientErrors
machine-0: 2014-10-28 17:01:52 DEBUG juju.worker.peergrouper publish.go:39 API host ports have not changed
machine-0: 2014-10-28 17:01:52 DEBUG juju.worker.peergrouper desired.go:39 calculating desired peer group

neel (neel-basu-z)
description: updated
neel (neel-basu-z)
description: updated
description: updated
Changed in juju-core:
status: New → Confirmed
Aaron Bentley (abentley)
Changed in juju-core:
importance: Undecided → Medium
tags: added: oil
Curtis Hovey (sinzui)
Changed in juju-core:
status: Confirmed → Triaged
tags: removed: oil
Curtis Hovey (sinzui)
no longer affects: juju-core
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.