juju bootstrap manual/127.0.0.1 on a unit of a different model causes that unit to lose agent

Bug #1750386 reported by Ryan Beisner
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Canonical Juju
Triaged
Low
Unassigned

Bug Description

Running `juju bootstrap manual/127.0.0.1` on a unit of a different model causes that unit to lose agent, apparently irrecoverably.

When a user tries to bootstrap manual locally, juju does give an error ("ERROR failed to bootstrap model: machine is already provisioned"), but at that point the damage is already done. Juju unit agents are clobbered in some way, and the agents go lost forever.

If a user then tries again to bootstrap, it is successful, presumably because the juju unit agent was already killed by the first attempt.

The end result appears to be that the user can turn the unit into a controller, and that unit will never take place in its original model again.

Revision history for this message
Chris MacNaughton (chris.macnaughton) wrote :

When done on the openstack provider:

On the top level model:
$ juju deploy ubuntu

On ubuntu/0:
$ juju bootstrap manual/127.0.0.1 test
Creating Juju controller "test" on manual
Looking for packaged Juju agent version 2.3.3 for amd64
ERROR failed to bootstrap model: machine is already provisioned

Back at the top level:
Model Controller Cloud/Region Version SLA
icey icey-serverstack serverstack/serverstack 2.2.6.3 unsupported

App Version Status Scale Charm Store Rev OS Notes
ubuntu 16.04 active 0/1 ubuntu jujucharms 12 ubuntu

Unit Workload Agent Machine Public address Ports Message
ubuntu/0 unknown lost 1 10.5.0.42 agent lost, see 'juju show-status-log ubuntu/0'

Machine State DNS Inst id Series AZ Message
1 down 10.5.0.42 83e48847-3860-4aad-b685-2e4085d44024 xenial nova ACTIVE

Relation provider Requirer Interface Type Message

Revision history for this message
Chris MacNaughton (chris.macnaughton) wrote :

If I then try to `juju bootstrap...` again on the ubuntu unit:

$ juju bootstrap manual/127.0.0.1
Creating Juju controller "manual" on manual
Looking for packaged Juju agent version 2.3.3 for amd64
Installing Juju agent on bootstrap instance
Fetching Juju GUI 2.11.3
Running machine configuration script...
sudo: unable to resolve host juju-67e6e5-icey-7
Bootstrap agent now started
Contacting Juju controller at 127.0.0.1 to verify accessibility...
Bootstrap complete, "manual" controller now available
Controller machines are in the "controller" model
Initial model "default" added

Revision history for this message
Ryan Beisner (1chb1n) wrote :

FTR, I don't necessarily expect this to work or be advisable, it is a bug to represent one way that we have discovered that we can create a problem for ourselves. As such, someone else will likely try the same eventually, and maybe juju can guard against it more thoroughly.

Ryan Beisner (1chb1n)
description: updated
Revision history for this message
Tim Penhey (thumper) wrote :

The check should be earlier prior to damaging an existing system.

Changed in juju:
status: New → Triaged
importance: Undecided → Medium
tags: added: blade-guards manual-provider ui
Revision history for this message
Canonical Juju QA Bot (juju-qa-bot) wrote :

This bug has not been updated in 2 years, so we're marking it Low importance. If you believe this is incorrect, please update the importance.

Changed in juju:
importance: Medium → Low
tags: added: expirebugs-bot
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.