cannot remove and re-add a manually provisioned machine
Bug #1851489 reported by
Andrea Ieri
This bug affects 2 people
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Canonical Juju |
Fix Released
|
Medium
|
Joseph Phillips |
Bug Description
Expected behavior:
Removing a manually provisioned machine cleans up all deployed juju code
Current behavior (2.6.9):
Manual cleanup is needed to re-deploy a manually provisioned machine
How to reproduce:
$ juju add-machine ssh:ubuntu@
created machine 64
$ juju remove-machine 64
removing machine 64
$ juju add-machine ssh:ubuntu@
ERROR machine is already provisioned
Workaround:
$ sudo systemctl disable jujud-machine-
Removed /etc/systemd/
Removed /etc/systemd/
$ sudo rm -rf /lib/systemd/
$ sudo rm -rf /var/lib/juju
# Now add-machine will work
Changed in juju: | |
status: | New → Triaged |
Changed in juju: | |
importance: | Undecided → Medium |
tags: | added: manual-provider |
Changed in juju: | |
milestone: | 2.7.1 → 2.7.2 |
To post a comment you must log in.
The removal of cleanup logic was a deliberate step to ensure that no Juju infrastructure can self-destruct under any circumstances.
As a compromise, machine initialisation has been modified to add an executable script to /sbin for cleaning a controller or machine previously provisioned by Juju.
So there is still a manual step required, but it is simply "/sbin/ remove- juju-services" .
The patch is here: https:/ /github. com/juju/ juju/pull/ 10877