config-changed error does not cause error state

Bug #1494542 reported by Michael Nelson on 2015-09-11
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
juju-core
High
Andrew Wilkins
1.24
High
Tim Penhey
1.25
High
Tim Penhey

Bug Description

I'm testing a deploy in which, due to an error in a charm, the config-change hook failed, as I can verify by tailing the juju log:

http://paste.ubuntu.com/12332911/

yet juju status for the same service is not in an error state, but rather has:

$ juju status sca-app | grep agent-status -A5
        agent-status:
          current: executing
          message: running commands
          since: 11 Sep 2015 00:05:07Z
          version: 1.24.5.1
        agent-state: started

This leaves the unit in the 'started' state, but I can't do anything like debug-hooks (unit not in error state), upgrade-charm (seems to get queued, but not executed because of the running commands), as juju seems to be convinced that the unit is currently running commands.

$ juju --version
1.24.5-trusty-amd64

summary: - unit does not go to error state
+ config-changed error does not cause error state
description: updated
Aaron Bentley (abentley) on 2015-09-11
Changed in juju-core:
status: New → Triaged
importance: Undecided → High
milestone: none → 1.25-beta1
Changed in juju-core:
milestone: 1.25-beta1 → 1.25-beta2
Tim Penhey (thumper) on 2015-09-17
Changed in juju-core:
assignee: nobody → Tim Penhey (thumper)
milestone: 1.25-beta2 → 1.26-alpha1
status: Triaged → In Progress
Michael Nelson (michael.nelson) wrote :

I reproduced this using the same mojo spec and application code revisions, and have uploaded the machine-0.log and unit log to chinstrap.canonical.com:/home/michaeln/bug-1494542-logs.tgz . I can't see any credentials in there, but it does have exact configurations of our app servers etc. - not sure if that's something to put public on the bug.

Tim Penhey (thumper) wrote :

The problem is that the 'juju run' command that is executed immediately after the hook goes into an error state bumps the unit out of the error state and it says it is now running commands.

However when it has finished, it never sets the unit status back to what it was.

The fix is to return it to the previous state when the juju run command has completed.

Andrew Wilkins (axwalk) on 2015-09-23
Changed in juju-core:
assignee: Tim Penhey (thumper) → Andrew Wilkins (axwalk)
Curtis Hovey (sinzui) on 2015-10-06
tags: added: hooks
Curtis Hovey (sinzui) on 2015-10-16
Changed in juju-core:
status: In Progress → Fix Released
Andrew Wilkins (axwalk) wrote :

This has not been done for master yet.

Changed in juju-core:
status: Fix Released → In Progress
Andrew Wilkins (axwalk) wrote :
Curtis Hovey (sinzui) on 2015-11-03
Changed in juju-core:
milestone: 1.26-alpha1 → 1.26-alpha2
Andrew Wilkins (axwalk) on 2015-11-13
Changed in juju-core:
status: In Progress → Fix Committed
Curtis Hovey (sinzui) on 2015-11-25
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