agent bouncing during startup until we have provider creds
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
juju-core |
Fix Released
|
High
|
John A Meinel |
Bug Description
We consolidated a couple of calls for the Upgrader when we moved over to the API version. However this had an unexpected interaction.
Specifically when you initially bootstrap, you don't have credentials for your provider yet (that happens on the first status/deploy/etc after bootstrap completes.)
During that time, the Machine agent is running the Upgrader, which asks the API Server what tools it should be running.
In 1.13.2 we thought it would be good to have a single API call for this, but it turns out that call then goes and tries to read the private storage, which requires provider credentials.
It will be better to have 2 calls. The first one just sees the desired agent version *without* the associated "where do I download the tools from" URL.
Related branches
- Juju Engineering: Pending requested
-
Diff: 262 lines (+150/-11)6 files modifiedstate/api/params/internal.go (+13/-0)
state/api/upgrader/upgrader.go (+26/-0)
state/api/upgrader/upgrader_test.go (+12/-0)
state/apiserver/upgrader/upgrader.go (+37/-7)
state/apiserver/upgrader/upgrader_test.go (+52/-0)
worker/upgrader/upgrader.go (+10/-4)
Changed in juju-core: | |
status: | In Progress → Fix Committed |
Changed in juju-core: | |
milestone: | none → 1.14.0 |
status: | Fix Committed → Fix Released |
note the error log looks like this: :11,"Type" :"Upgrader" ,"Request" :"Tools" ,"Params" :{"Entities" :[{"Tag" :"machine- 0"}]}} :12,"Type" :"NotifyWatcher ","Id": "3","Request" : "Next","Params":{}} :11,"Error" :"environment has no access-key or secret- key","Response" :{}} :13,"Type" :"NotifyWatcher ","Id": "3","Request" : "Stop","Params":{}} :12,"Error" :"watcher has been stopped" ,"ErrorCode" :"stopped" ,"Response" :{}} :13,"Response" :{}}
2013-08-29 10:01:35 DEBUG juju codec.go:103 rpc/jsoncodec: <- {"RequestId"
2013-08-29 10:01:35 DEBUG juju codec.go:103 rpc/jsoncodec: <- {"RequestId"
2013-08-29 10:01:35 INFO juju.provider.ec2 ec2.go:187 opening environment "amz-jam"
2013-08-29 10:01:35 DEBUG juju codec.go:168 rpc/jsoncodec: -> {"RequestId"
2013-08-29 10:01:35 DEBUG juju codec.go:103 rpc/jsoncodec: <- {"RequestId"
2013-08-29 10:01:35 DEBUG juju codec.go:168 rpc/jsoncodec: -> {"RequestId"
2013-08-29 10:01:35 DEBUG juju codec.go:168 rpc/jsoncodec: -> {"RequestId"
2013-08-29 10:01:35 ERROR juju runner.go:200 worker: fatal "upgrader": environment has no access-key or secret-key
2013-08-29 10:01:35 DEBUG juju runner.go:234 worker: killing "machiner"
2013-08-29 10:01:35 DEBUG juju runner.go:234 worker: killing "deployer"