application in error state cannot be removed and blocks destroy-model

Bug #1654928 reported by John A Meinel
16
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Canonical Juju
Fix Released
High
Ian Booth
2.1
Fix Released
High
Ian Booth

Bug Description

I managed to fail to provision the first machine for a new application, and got into this error:

$ juju status
Model Controller Cloud/Region Version
default test-jam maas21 2.1-rc1.1

App Version Status Scale Charm Store Rev OS Notes
ubuntu error 0/1 ubuntu jujucharms 10 ubuntu

Unit Workload Agent Machine Public address Ports Message
ubuntu/0 error lost cannot add a new machine: unexpected: ServerError: 503 Service Unavailable (<!DOCTYPE HTML PUBLIC "-/
...

Machine State DNS Inst id Series AZ

(note we have a separate problem where the error string is a full HTML response.)

At this point, there are no machines for this application, nor even any functional units of the application. So there are no machines that I can "remove-machine --force".
I did try "juju resolved --no-retry ubuntu/0" and the unit goes into 'resolved' status (trying to run it again tells me it is in the resolved state already), but it doesn't change status output.

$ juju remove-application ubuntu

Does return a successful code, but doesn't seem to do anything, and there is no '--force' for remove-application.

Both "juju destroy-model" and "juju destroy-controller" get stuck waiting for that application to die.

Revision history for this message
Dmitrii Shcherbakov (dmitriis) wrote :

Caught a similar issue: after running 'remove-application' a machine and its corresponding unit got destroyed but not the application itself which just hangs in the 'waiting' state.

https://paste.ubuntu.com/23921449/ (see zaqar's state)
(package versions are included in the paste)

2.1~beta4-0ubuntu1~16.04.1~juj

Changed in juju:
milestone: none → 2.2.0-alpha1
Revision history for this message
Anastasia (anastasia-macmood) wrote :

Possibly related to bug # 1661930

tags: added: eda
Revision history for this message
Ian Booth (wallyworld) wrote :

This bug appears fixed by this PR https://github.com/juju/juju/pull/6906

I can add an application and regardless of whether there's an error returned from stating an instance to host the unit of the application (the machine shows as lost), or if the application itself has an error status, removing the application and/or destroying the model clean up correctly.

Changed in juju:
assignee: nobody → Ian Booth (wallyworld)
status: Triaged → Fix Committed
Curtis Hovey (sinzui)
Changed in juju:
status: Fix Committed → Fix Released
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.