[maas] juju destroy-environment also destroys nodes that are not controlled by juju
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
juju-core |
Fix Released
|
High
|
Tim Penhey | ||
1.16 |
Fix Released
|
Critical
|
Roger Peppe | ||
pyjuju |
Triaged
|
Low
|
Unassigned | ||
juju-core (Ubuntu) |
Fix Released
|
High
|
Unassigned | ||
Saucy |
Fix Released
|
High
|
Unassigned | ||
maas (Ubuntu) |
Invalid
|
Critical
|
Unassigned | ||
Saucy |
Invalid
|
Critical
|
Unassigned |
Bug Description
[Impact]
juju destroy-environment destroys all machines allocated to the MAAS user being used in the environment, not just the ones owned by Juju.
[Test Case]
Allocate machines using maas-cli
juju bootstrap
juju destroy-environment
(all machines are terminated and powered off)
[Regression Potential]
The fix is limited to the MAAS provider in the codebase; so regression potential is limited in scope of provider.
[Original Bug Report]
In a saucy MAAS environment, I had machines allocated to the admin user that were deployed using maas-cli (not using juju). These were perfectly running machines. However, while trying to use juju I noticed that a 'juju destroy-
This means that juju destroys all of the machines regardless of whether they are being used by juju or not.
Related bugs:
* bug 1237398: "You'll need a separate MAAS key for each Juju environment" is wrong.
* bug 1081247: maas provider releases all nodes it did not allocate [does not play well with others]
* bug 1239488: Juju api client cannot distinguish between environments
Related branches
- Tim Penhey (community): Approve (conditional)
-
Diff: 712 lines (+186/-76)9 files modifiedprovider/maas/config.go (+16/-2)
provider/maas/config_test.go (+17/-3)
provider/maas/environ.go (+4/-2)
provider/maas/environ_test.go (+29/-34)
provider/maas/environprovider.go (+21/-1)
provider/maas/environprovider_test.go (+44/-3)
provider/maas/instance_test.go (+15/-13)
provider/maas/maas_test.go (+24/-2)
provider/maas/storage_test.go (+16/-16)
- Juju Engineering: Pending requested
-
Diff: 200 lines (+62/-9)3 files modifiedprovider/maas/environ_test.go (+7/-2)
provider/maas/storage.go (+22/-2)
provider/maas/storage_test.go (+33/-5)
- Juju Engineering: Pending requested
-
Diff: 935 lines (+267/-85)10 files modifiedprovider/maas/config.go (+22/-2)
provider/maas/config_test.go (+33/-3)
provider/maas/environ.go (+4/-2)
provider/maas/environ_test.go (+36/-36)
provider/maas/environprovider.go (+18/-1)
provider/maas/environprovider_test.go (+44/-3)
provider/maas/instance_test.go (+15/-13)
provider/maas/maas_test.go (+24/-2)
provider/maas/storage.go (+22/-2)
provider/maas/storage_test.go (+49/-21)
Changed in juju: | |
status: | New → Confirmed |
description: | updated |
tags: | added: maas |
summary: |
- juju destroy-environment also destroys nodes that are not controlled by - juju + [maas] juju destroy-environment also destroys nodes that are not + controlled by juju |
Changed in juju: | |
importance: | Undecided → High |
tags: | added: theme-oil |
Changed in juju-core: | |
assignee: | nobody → Tim Penhey (thumper) |
status: | Triaged → In Progress |
milestone: | none → 2.0 |
Changed in juju-core: | |
milestone: | 2.0 → 1.17.0 |
Changed in juju: | |
status: | Confirmed → Triaged |
importance: | High → Low |
description: | updated |
Changed in juju-core (Ubuntu Saucy): | |
importance: | Undecided → High |
status: | New → Triaged |
Changed in juju-core: | |
status: | In Progress → Fix Committed |
tags: |
added: maas-provider removed: maas |
Changed in maas (Ubuntu): | |
status: | Triaged → Invalid |
Changed in maas (Ubuntu Saucy): | |
status: | Triaged → Invalid |
Changed in juju-core: | |
importance: | Critical → High |
description: | updated |
Changed in juju-core: | |
status: | Fix Committed → Fix Released |
This might be a bug in the maas provider of juju-core… it definitely needs investigation…