tabular format does not give enough details about machine provisioning errors

Bug #1478156 reported by Marco Ceppi on 2015-07-24
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Eric Snow
Eric Snow

Bug Description

Since tabular format is going to be default it needs to elevate machine provisioning errors. When running `juju status --format=tabular` or using the Juju flag for status 2.0, when a machine fails to provision this is what's provided (see machine 5)

When --format yaml is used, the user will actually see the error

It seems agent-state-info is the key, but it should be easy to determine that when an a provisioning error is made the STATE field (empty atm) could have an "error" or "provisioning error" if error is already used. As to the untrained eye it seems like GCE is just taking a long ass time to create the instance since inst-id is pending.

Curtis Hovey (sinzui) on 2015-07-27
Changed in juju-core:
status: New → Triaged
importance: Undecided → High
milestone: none → 1.25.0
summary: - summary format does not give enough details about machine provisioning
+ tabular format does not give enough details about machine provisioning
Curtis Hovey (sinzui) on 2015-08-27
Changed in juju-core:
milestone: 1.25-alpha1 → 1.25-beta1
Changed in juju-core:
milestone: 1.25-beta1 → 1.25.1
Changed in juju-core:
assignee: nobody → Eric Snow (ericsnowcurrently)
status: Triaged → In Progress
milestone: 1.25.1 → 1.26.0
milestone: 1.26.0 → none
Eric Snow (ericsnowcurrently) wrote :

From what I can tell, the message in "agent-state-info" indicates that provisioning failed. If that were the case then AgentState should have been set to "error". [1] Instead it appears to be unset. This implies to me that there is a bug in how instance provisioning failures are handled. I'm going to look into that here. If it turns out I've misunderstood then I'll circle back to injecting a more meaningful message in this case.


Eric Snow (ericsnowcurrently) wrote :

I've verified that the right thing isn't happening here. If I call task.setErrorStatus (and return) at the beginning of the startMachine method (in worker/provisioner/provisioner_task.go) then I get exactly the same situation. Status reports the correct "agent-state-info" but "agent-state" is not set. So I'm on the right trail.

Eric Snow (ericsnowcurrently) wrote :

TestProvisionerSetsErrorStatusWhenStartInstanceFailed (in worker/provisioner) should cover any direct problems so I'm guessing that there's an indirect problem here. Most likely there's some code that sets the status after provisioning happens.

Eric Snow (ericsnowcurrently) wrote :

Ah, there's a silenced panic coming out of task.setErrorStatus (in worker/provision). Getting closer!

Eric Snow (ericsnowcurrently) wrote :

hmm. Looks like there wasn't a panic after all.

Eric Snow (ericsnowcurrently) wrote :

At this point I suspect that the status formatter isn't pulling the right info or is doing so in a selective way (incorrectly).

Changed in juju-core:
milestone: none → 1.26-alpha1
Changed in juju-core:
status: In Progress → Fix Committed
Curtis Hovey (sinzui) on 2015-10-16
Changed in juju-core:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers