peer relation disappears during upgrade of juju

Bug #1303697 reported by James Page
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
juju-core
Fix Released
High
William Reade
1.18
Fix Released
Critical
William Reade
juju-core (Ubuntu)
Fix Released
Critical
Unassigned
Trusty
Fix Released
Critical
Unassigned

Bug Description

Upgrading a running environment from 1.17.7 to 1.18.0, I noticed that the peer relation of a service disappears during the upgrade process (at least I think it does).

The keystone charm uses the peer relation for storage and propagation of usernames/passwords between units; however when the config-changed hook fires as part of the upgrade-juju process (which I'm assuming its mean't to), the peer relation is not accessible:

2014-04-07 09:49:10 INFO juju-log Creating service credentials for 's3_ec2_nova'
2014-04-07 09:49:10 INFO config-changed Traceback (most recent call last):
2014-04-07 09:49:10 INFO config-changed File "/var/lib/juju/agents/unit-keystone-0/charm/hooks/config-changed", line 297, in <module>
2014-04-07 09:49:10 INFO config-changed main()
2014-04-07 09:49:10 INFO config-changed File "/var/lib/juju/agents/unit-keystone-0/charm/hooks/config-changed", line 291, in main
2014-04-07 09:49:10 INFO config-changed hooks.execute(sys.argv)
2014-04-07 09:49:10 INFO config-changed File "/var/lib/juju/agents/unit-keystone-0/charm/hooks/charmhelpers/core/hookenv.py", line 381, in execute
2014-04-07 09:49:10 INFO config-changed self._hooks[hook_name]()
2014-04-07 09:49:10 INFO config-changed File "/var/lib/juju/agents/unit-keystone-0/charm/hooks/charmhelpers/core/host.py", line 217, in wrapped_f
2014-04-07 09:49:10 INFO config-changed f(*args)
2014-04-07 09:49:10 INFO config-changed File "/var/lib/juju/agents/unit-keystone-0/charm/hooks/config-changed", line 108, in config_changed
2014-04-07 09:49:10 INFO config-changed remote_unit=unit)
2014-04-07 09:49:10 INFO config-changed File "/var/lib/juju/agents/unit-keystone-0/charm/hooks/config-changed", line 180, in identity_changed
2014-04-07 09:49:10 INFO config-changed add_service_to_keystone(relation_id, remote_unit)
2014-04-07 09:49:10 INFO config-changed File "/var/lib/juju/agents/unit-keystone-0/charm/hooks/keystone_utils.py", line 712, in add_service_to_keystone
2014-04-07 09:49:10 INFO config-changed service_password = get_service_password(service_username)
2014-04-07 09:49:10 INFO config-changed File "/var/lib/juju/agents/unit-keystone-0/charm/hooks/keystone_utils.py", line 547, in get_service_password
2014-04-07 09:49:10 INFO config-changed passwd = peer_retrieve(peer_key)
2014-04-07 09:49:10 INFO config-changed File "/var/lib/juju/agents/unit-keystone-0/charm/hooks/charmhelpers/contrib/peerstorage/__init__.py", line 49, in peer_retrieve
2014-04-07 09:49:10 INFO config-changed 'peer relation {}'.format(relation_name))
2014-04-07 09:49:10 INFO config-changed ValueError: Unable to detectpeer relation cluster

I resolved the config-changed failure and then used juju run to check that the cluster relation has re-appeared:

jenkins@test-01:~$ juju run --unit keystone/0 "relation-ids cluster"

and then after resolving another config-changed error;

jenkins@test-01:~$ juju run --unit keystone/0 "relation-ids cluster"
cluster:2

it re-appears; this behaviour is not desirable as it means that all services don't know they have peers during an juju upgrade.

Related branches

Curtis Hovey (sinzui)
Changed in juju-core:
status: New → Triaged
importance: Undecided → Critical
milestone: none → 1.19.0
William Reade (fwereade)
Changed in juju-core:
assignee: nobody → William Reade (fwereade)
William Reade (fwereade)
Changed in juju-core:
status: Triaged → In Progress
John A Meinel (jameinel)
Changed in juju-core:
status: In Progress → Fix Committed
James Page (james-page)
Changed in juju-core (Ubuntu Trusty):
status: New → Triaged
importance: Undecided → Critical
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package juju-core - 1.18.1-0ubuntu1

---------------
juju-core (1.18.1-0ubuntu1) trusty; urgency=medium

  * New upstream point release, including fixes for:
    - Upgrading juju 1.16.6 -> 1.18.x fails (LP: #1299802).
    - Peer relation disappears during juju-upgrade (LP: #1303697).
    - public-address of units changes to internal bridge post upgrade
      (LP: #1303735).
    - Unable to deploy local charms without series (LP: #1303880).
    - juju scp no longer allows multiple extra arguments to be passed
      (LP: #1306208).
    - juju cannot downgrade to same major.minor version with earlier
      patch number (LP: #1306296).
 -- James Page <email address hidden> Sat, 12 Apr 2014 07:04:37 +0100

Changed in juju-core (Ubuntu Trusty):
status: Triaged → Fix Released
Curtis Hovey (sinzui)
Changed in juju-core:
importance: Critical → High
Curtis Hovey (sinzui)
Changed in juju-core:
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.