cloud-compute-relation-changed hook errors when database is in maintenance mode

Bug #1871647 reported by Chris MacNaughton
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Nova Cloud Controller Charm
Fix Released
Medium
Chris MacNaughton

Bug Description

2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed Traceback (most recent call last):
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed File "/var/lib/juju/agents/unit-nova-cloud-controller-0/charm/hooks/cloud-compute-relation-changed", line 1382, in <module>
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed main()
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed File "/var/lib/juju/agents/unit-nova-cloud-controller-0/charm/hooks/cloud-compute-relation-changed", line 1374, in main
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed hooks.execute(sys.argv)
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed File "/var/lib/juju/agents/unit-nova-cloud-controller-0/charm/charmhelpers/core/hookenv.py", line 934, in execute
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed self._hooks[hook_name]()
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed File "/var/lib/juju/agents/unit-nova-cloud-controller-0/charm/hooks/cloud-compute-relation-changed", line 674, in cloud_compute_relation_changed
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed add_hosts_to_cell_when_ready()
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed File "/var/lib/juju/agents/unit-nova-cloud-controller-0/charm/hooks/cloud-compute-relation-changed", line 688, in add_hosts_to_cell_when_ready
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed ncc_utils.add_hosts_to_cell()
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed File "/var/lib/juju/agents/unit-nova-cloud-controller-0/charm/hooks/nova_cc_utils.py", line 950, in add_hosts_to_cell
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed cell1_uuid = get_cell_uuid('cell1')
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed File "/var/lib/juju/agents/unit-nova-cloud-controller-0/charm/hooks/nova_cc_utils.py", line 831, in get_cell_uuid
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed cells = get_cell_details()
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed File "/var/lib/juju/agents/unit-nova-cloud-controller-0/charm/hooks/nova_cc_utils.py", line 849, in get_cell_details
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed out = subprocess.check_output(cmd).decode('utf-8')
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed File "/usr/lib/python3.5/subprocess.py", line 626, in check_output
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed **kwargs).stdout
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed File "/usr/lib/python3.5/subprocess.py", line 708, in run
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed output=stdout, stderr=stderr)
2020-04-08 13:06:21 DEBUG cloud-compute-relation-changed subprocess.CalledProcessError: Command '['sudo', 'nova-manage', 'cell_v2', 'list_cells', '--verbose']' returned non-zero exit status 1
2020-04-08 13:06:22 ERROR juju.worker.uniter.operation runhook.go:132 hook "cloud-compute-relation-changed" failed: exit status 1

Changed in charm-nova-cloud-controller:
importance: Undecided → Medium
assignee: nobody → Chris MacNaughton (chris.macnaughton)
milestone: none → 20.05
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to charm-nova-cloud-controller (master)

Reviewed: https://review.opendev.org/718467
Committed: https://git.openstack.org/cgit/openstack/charm-nova-cloud-controller/commit/?id=65ed6620c7594cac914d21c2203742f63dc43d17
Submitter: Zuul
Branch: master

commit 65ed6620c7594cac914d21c2203742f63dc43d17
Author: Chris MacNaughton <email address hidden>
Date: Wed Apr 8 16:09:25 2020 +0200

    We cannot talk to the database during maintenance

    Change-Id: Ie0d58c3f11b34d5fd6354c3f2130e8618e49b915
    Closes-Bug: #1871647

Changed in charm-nova-cloud-controller:
status: In Progress → Fix Committed
tags: added: series-upgrade
David Ames (thedac)
Changed in charm-nova-cloud-controller:
status: Fix Committed → Fix Released
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.