Juju allows upgrade based on stream, but fails to find agent binaries
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Canonical Juju |
Triaged
|
Undecided
|
Unassigned |
Bug Description
Using version 2.8.1, with 2.8.2 currently proposed and in QA.
$ juju upgrade-controller
no upgrades available
$ juju upgrade-controller --agent-
...
16:34:28 DEBUG juju.cmd.
16:34:34 DEBUG juju.cmd.
...
At this point the upgrade is allowed to proceed, but based on the logs we do not attempt to locate agent binaries in the correct stream:
machine-0: 16:34:43 DEBUG juju.environs.tools finding agent binaries in stream: "released"
machine-0: 16:34:43 DEBUG juju.environs.tools reading agent binaries with major version -1
machine-0: 16:34:43 DEBUG juju.environs.tools filtering agent binaries by version: 2.8.2
machine-0: 16:34:43 DEBUG juju.environs.tools filtering agent binaries by series: bionic
machine-0: 16:34:43 DEBUG juju.environs.tools filtering agent binaries by architecture: amd64
machine-0: 16:34:43 DEBUG juju.environs.tools trying datasource "keystone catalog"
machine-0: 16:34:44 DEBUG juju.environs.
...
machine-0: 16:34:44 DEBUG juju.worker.
machine-0: 16:34:44 ERROR juju.worker.
tags: | added: upgrade-juju |
So what happens here is the upgrader worker watches the model config for changes. If the version changes, it simply requests tools for the version.
Nowhere is it stored that we requested the upgrade from the specific stream, instead at this point, we just use the configured model value (default=released) for "agent-stream".
Changing this value to mirror that supplied at the CLI allows the upgrade to proceed.