juju deploy unit placement is broken
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Canonical Juju |
New
|
Undecided
|
Unassigned |
Bug Description
Juju: 2.2.1
MAAS: 2.2.1
If i create a new model and deploy a bundle as follows:
cat << EOF > bundle.yaml
machines:
'0':
series: xenial
constraints: 'tags=testnode'
services:
ubuntu:
charm: cs:ubuntu
num_units: 1
to:
- lxd:0
EOF
juju deploy bundle.yaml
It works just fine:
Model Controller Cloud/Region Version SLA
default mymaas mymaas 2.2.1 unsupported
App Version Status Scale Charm Store Rev OS Notes
ubuntu 16.04 active 1 ubuntu jujucharms 10 ubuntu
Unit Workload Agent Machine Public address Ports Message
ubuntu/0* active idle 0/lxd/0 192.168.200.125 ready
Machine State DNS Inst id Series AZ Message
0 started 192.168.200.124 mr6nmf xenial default Deployed
0/lxd/0 started 192.168.200.125 juju-826296-0-lxd-0 xenial Container started
If i then remove the ubuntu application i deployed it does so cleanly and I am left with just machine "0". If I then re-execute juju deploy bundle.yaml (unchanged from previous run) it does not use machine "0" and instead deploys a new machine onto which it deploys the ubuntu application.
Model Controller Cloud/Region Version SLA
default mymaas mymaas 2.2.1 unsupported
App Version Status Scale Charm Store Rev OS Notes
ubuntu waiting 0/1 ubuntu jujucharms 10 ubuntu
Unit Workload Agent Machine Public address Ports Message
ubuntu/1 waiting allocating 1/lxd/0 waiting for machine
Machine State DNS Inst id Series AZ Message
0 started 192.168.200.124 mr6nmf xenial default Deployed
1 pending pending xenial failed to start instance (cannot run instances: cannot run instance: No available machine matches constraints: [('agent_name', ['51e51f83-
)] (resolved to "tags=testnode zone=default")), retrying in 10s (9 more attempts)
1/lxd/0 pending pending xenial
tags: | added: sts |
Machine identifiers in bundles are 'logical' machines, not concrete machine
identifiers. There is some work being done to allow you to map the logical
identifiers in a bundle to the concrete identifiers in your model.
(Otherwise bundles won't ever work as soon as you deploy 1 extra machine,
etc.), and it would severely limit the ability to share bundles because
your models would always have to match exactly.
On Tue, Jul 11, 2017 at 5:25 PM, Edward Hope-Morley <
<email address hidden>> wrote:
> Public bug reported: ef54-4cf5- 8a48-7de6e38262 96']), /bugs.launchpad .net/bugs/ 1703610 /bugs.lau...
>
> Juju: 2.2.1
> MAAS: 2.2.1
>
> If i create a new model and deploy a bundle as follows:
>
> cat << EOF > bundle.yaml
> machines:
> '0':
> series: xenial
> constraints: 'tags=testnode'
> services:
> ubuntu:
> charm: cs:ubuntu
> num_units: 1
> to:
> - lxd:0
> EOF
> juju deploy bundle.yaml
>
> It works just fine:
>
> Model Controller Cloud/Region Version SLA
> default mymaas mymaas 2.2.1 unsupported
>
> App Version Status Scale Charm Store Rev OS Notes
> ubuntu 16.04 active 1 ubuntu jujucharms 10 ubuntu
>
> Unit Workload Agent Machine Public address Ports Message
> ubuntu/0* active idle 0/lxd/0 192.168.200.125 ready
>
> Machine State DNS Inst id Series AZ
> Message
> 0 started 192.168.200.124 mr6nmf xenial default
> Deployed
> 0/lxd/0 started 192.168.200.125 juju-826296-0-lxd-0 xenial
> Container started
>
> If i then remove the ubuntu application i deployed it does so cleanly
> and I am left with just machine "0". If I then re-execute juju deploy
> bundle.yaml (unchanged from previous run) it does not use machine "0"
> and instead deploys a new machine onto which it deploys the ubuntu
> application.
>
> Model Controller Cloud/Region Version SLA
> default mymaas mymaas 2.2.1 unsupported
>
> App Version Status Scale Charm Store Rev OS Notes
> ubuntu waiting 0/1 ubuntu jujucharms 10 ubuntu
>
> Unit Workload Agent Machine Public address Ports Message
> ubuntu/1 waiting allocating 1/lxd/0 waiting
> for machine
>
> Machine State DNS Inst id Series AZ Message
> 0 started 192.168.200.124 mr6nmf xenial default Deployed
> 1 pending pending xenial failed to
> start instance (cannot run instances: cannot run instance: No available
> machine matches constraints: [('agent_name', ['51e51f83-
> ('zone', ['default']), ('tags', ['testnode']
> )] (resolved to "tags=testnode zone=default")), retrying in 10s (9 more
> attempts)
> 1/lxd/0 pending pending xenial
>
> ** Affects: juju
> Importance: Undecided
> Status: New
>
>
> ** Tags: sts
>
> ** Tags added: sts
>
> --
> You received this bug notification because you are subscribed to juju.
> Matching subscriptions: juju bugs
> https:/
>
> Title:
> juju deploy unit placement is broken
>
> To manage notifications about this bug go to:
> https:/