Peer relation listed in relation-ids, but not queryable using relation-list
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
pyjuju |
Fix Released
|
High
|
Kapil Thangavelu | ||
juju (Ubuntu) |
Fix Committed
|
High
|
Unassigned |
Bug Description
Charm branch:
lp:~openstack-charmers/charms/precise/cinder/ha-support
Hook function:
#######
# Description: Query Cluster peer interface to see if peered
# Returns: 0 if peered, 1 if not peered
#######
is_peered() {
r_id=
if [ -z "$(relation-list -r $r_id)" ]; then
echo "Unit not yet peered"
return 1
else
echo "Unit peered"
return 0
fi
}
relation-ids cluster appears to return "cluster:11"; however the subsequent relation-list -r cluster:11 prints "Relation not found" and returns an empty string:
2013-01-31 17:21:02,128 unit:cinder/4: unit.hook.api DEBUG: Listing relation members for cluster:11
2013-01-31 17:21:02,131 unit:cinder/4: unit.deploy DEBUG: Downloading charm local:quantal/
2013-01-31 17:21:02,136 unit:cinder/4: juju.state.hook DEBUG: Ignoring partially constructed relation: amqp:26
2013-01-31 17:21:02,145 unit:cinder/4: hook.output INFO: Relation not found
2013-01-31 17:21:02,146 unit:cinder/4: juju.state.hook DEBUG: Ignoring partially constructed relation: cinder-
2013-01-31 17:21:02,148 unit:cinder/4: unit.relation.
2013-01-31 17:21:02,187 unit:cinder/4: hook.output INFO: Unit not yet peered
ProblemType: Bug
DistroRelease: Ubuntu 12.10
Package: juju 0.6-1ubuntu1
ProcVersionSign
Uname: Linux 3.5.0-22-generic x86_64
ApportVersion: 2.6.1-0ubuntu9
Architecture: amd64
Date: Thu Jan 31 17:33:04 2013
MarkForUpload: True
PackageArchitec
SourcePackage: juju
UpgradeStatus: No upgrade log present (probably fresh install)
Related branches
- Juju Engineering: Pending requested
-
Diff: 206 lines (+44/-21)4 files modifiedjuju/hooks/invoker.py (+11/-6)
juju/hooks/protocol.py (+4/-2)
juju/hooks/tests/test_invoker.py (+17/-13)
juju/state/errors.py (+12/-0)
Changed in juju: | |
status: | New → In Progress |
importance: | Undecided → High |
assignee: | nobody → Kapil Thangavelu (hazmat) |
milestone: | none → 0.7 |
Changed in juju: | |
status: | In Progress → Fix Released |
Changed in juju (Ubuntu): | |
status: | New → Fix Committed |
Changed in juju (Ubuntu): | |
importance: | Undecided → High |
2013-01-31 17:44:52,490: hook.output@INFO: ++ relation-ids cluster
2013-01-31 17:44:52,494: juju.state. hook@DEBUG: Ignoring partially constructed relation: shared-db:25 watch@DEBUG: relation watcher start lifecycle@ DEBUG: started relation:ha lifecycle hook@DEBUG: Ignoring partially constructed relation: amqp:26 hook@DEBUG: Ignoring partially constructed relation: cinder- volume- service: 27 service: 28'] wstate: transition complete start (state up) {} lifecycle@ DEBUG: Executing hook ceph-relation- joined lifecycle@ DEBUG: stopped relation:cluster lifecycle wstate: transition start (None -> up) {} wstate: execute action do_start DEBUG: start watch@DEBUG: relation watcher start lifecycle@ DEBUG: started relation:cluster lifecycle DEBUG: members changed: old=[], new=['cinder/0', 'cinder/1', 'cinder/2', 'cinder/3', 'cinder/4', 'cinder/6'] DEBUG: executing hook for cinder/0:joined DEBUG: settings changed: (('cinder/6', 0),) DEBUG: settings changed: (('cinder/4', 0),) DEBUG: settings changed: (('cinder/3', 0),) DEBUG: settings changed: (('cinder/2', 0),) DEBUG: settings changed: (('cinder/0', 0),) DEBUG: settings changed: (('cinder/1', 0),) wstate: transition complete start (state up) {} lifecycle@ DEBUG: stopped relation:shared-db lifecycle hook@DEBUG: Ignoring partially constructed relation: amqp:26 wstate: transition start (None -> up) {} wstate: execute action do_start DEBUG: start hook@DEBUG: Ignoring partially constructed relation: cinder- volume- service: 27 hook@DEBUG: Ignoring partially constructed relation: amqp:26 watch@DEBUG: relation watcher start lifecycle@ DEBUG: started relation:shared-db lifecycle hook@DEBUG: Ignoring partially constructed relation: cinder- volume- service: 27 DEBUG: members changed: old=[...
2013-01-31 17:44:52,495: unit.relation.
2013-01-31 17:44:52,496: unit.relation.
2013-01-31 17:44:52,497: juju.state.
2013-01-31 17:44:52,501: juju.state.
2013-01-31 17:44:52,501: hook.output@DEBUG: Cached relation hook contexts on 'ceph:29': ['identity-
2013-01-31 17:44:52,502: statemachine@DEBUG: relationworkflo
2013-01-31 17:44:52,551: unit.relation.
2013-01-31 17:44:52,678: unit.relation.
2013-01-31 17:44:52,686: statemachine@DEBUG: relationworkflo
2013-01-31 17:44:52,687: statemachine@DEBUG: relationworkflo
2013-01-31 17:44:52,687: hook.scheduler@
2013-01-31 17:44:52,726: unit.relation.
2013-01-31 17:44:52,727: unit.relation.
2013-01-31 17:44:52,736: hook.scheduler@
2013-01-31 17:44:52,737: hook.scheduler@
2013-01-31 17:44:52,749: hook.scheduler@
2013-01-31 17:44:52,755: hook.scheduler@
2013-01-31 17:44:52,764: hook.scheduler@
2013-01-31 17:44:52,766: hook.scheduler@
2013-01-31 17:44:52,775: hook.scheduler@
2013-01-31 17:44:52,777: hook.scheduler@
2013-01-31 17:44:52,779: statemachine@DEBUG: relationworkflo
2013-01-31 17:44:53,001: unit.relation.
2013-01-31 17:44:53,005: juju.state.
2013-01-31 17:44:53,006: statemachine@DEBUG: relationworkflo
2013-01-31 17:44:53,006: statemachine@DEBUG: relationworkflo
2013-01-31 17:44:53,007: hook.scheduler@
2013-01-31 17:44:53,007: juju.state.
2013-01-31 17:44:53,046: juju.state.
2013-01-31 17:44:53,048: unit.relation.
2013-01-31 17:44:53,048: unit.relation.
2013-01-31 17:44:53,067: juju.state.
2013-01-31 17:44:53,072: hook.scheduler@