Merge lp://staging/~chad.smith/charms/precise/storage/storage-volume-label-availability-zone into lp://staging/~dpb/charms/precise/storage/trunk
Status: | Merged |
---|---|
Merged at revision: | 35 |
Proposed branch: | lp://staging/~chad.smith/charms/precise/storage/storage-volume-label-availability-zone |
Merge into: | lp://staging/~dpb/charms/precise/storage/trunk |
Prerequisite: | lp://staging/~chad.smith/charms/precise/storage/storage-fix-nfs-relation-ordering |
Diff against target: |
229 lines (+97/-19) 3 files modified
hooks/common_util.py (+31/-9) hooks/storage-provider.d/block-storage-broker/block-storage-relation-changed (+2/-1) hooks/test_common_util.py (+64/-9) |
To merge this branch: | bzr merge lp://staging/~chad.smith/charms/precise/storage/storage-volume-label-availability-zone |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
David Britton | Approve | ||
Fernando Correa Neto (community) | Approve | ||
Review via email: mp+212062@code.staging.launchpad.net |
Description of the change
Volumes in EC2-land can only be attached to instances that live in the same availability zone. Block-storage-
To avoid trying to euca-attach-volume of a volume in another AZ, we need to request that our volume label (volume_label translates to a volume TAG in EC2) specify the availability zone in which that volume is created. For openstack and nova, the AZ is always nova, but for ec2, the AZ will be determined as the AZ in which the requesting instance-id lives (us-east-1b, us-west-1a etc.)
This way, the block-storage-
There will need to be more significant work in the block-storage-
This branch adds a get_availabilit
Also in this branch:
dropping the lsof -b (non-blocking) option, as called currently it was not a valid option. Will look at non-blocking lsof in a separate branch.
[0] When relating to bsb, I recieved:
2014-03-20 22:59:28 INFO worker.uniter.jujuc server.go:108 running hook tool "juju-log" ["Validated charm configuration credentials have access to block storage service"] storage- broker- ec2/0:block- storage- relation- changed: 347041481634193 8807"; dir "/var/lib/ juju/agents/ unit-block- storage- broker- ec2-0/charm" broker- ec2/0 block-storage:2: Validated charm configuration credentials have access to block storage service storage- broker- ec2/0:block- storage- relation- changed: 347041481634193 8807"; dir "/var/lib/ juju/agents/ unit-block- storage- broker- ec2-0/charm" broker- ec2/0 block-storage:2: Creating a 9Gig volume named (postgresql/0 us-west-1c volume) for instance i-53df8d0c
2014-03-20 22:59:28 DEBUG worker.uniter.jujuc server.go:109 hook context id "block-
2014-03-20 22:59:28 INFO juju juju-log.go:66 block-storage-
2014-03-20 22:59:29 INFO worker.uniter.jujuc server.go:108 running hook tool "juju-log" ["Creating a 9Gig volume named (postgresql/0 us-west-1c volume) for instance i-53df8d0c"]
2014-03-20 22:59:29 DEBUG worker.uniter.jujuc server.go:109 hook context id "block-
2014-03-20 22:59:29 INFO juju juju-log.go:66 block-storage-
2014-03-20 22:59:29 INFO juju.worker.uniter context.go:255 HOOK 'availability_zone'
2014-03-20 22:59:29 ERROR juju.worker.uniter uniter.go:350 hook failed: exit status 1