unit stuck in terminating on charm upgrade, no juju leader

Bug #2041714 reported by Tom Haddon
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Canonical Juju
Triaged
Low
Joseph Phillips

Bug Description

I just ran a charm upgrade on a k8s model on juju 3.1.6, having done a similar operation on two other juju models without problems.

However, the second unit to be upgraded got stuck in "Terminating" status in k8s, and "agent lost" as far as Juju was concerned: https://pastebin.canonical.com/p/b6PqDdQbFM/. As you can see there was also no juju leader.

Here's the debug-log output https://pastebin.canonical.com/p/XSTTpd9Fny/.

I was able to recover things by manually running `kubectl delete pod $podname`.

Tags: canonical-is
Tom Haddon (mthaddon)
tags: added: canonical-is
Revision history for this message
Joseph Phillips (manadart) wrote :

This appears to be a race between the unit agent and its lease claimer proxy:

- Units are shutting down for the upgrade restart, and the current leader actively revokes its lease.
- The other unit is promoted to leader, but over the course of the upgrade the lease expires.
- The original leader is promoted as it is coming up, but when it checks it is not the leader.

Changed in juju:
status: New → Triaged
importance: Undecided → Low
assignee: nobody → Joseph Phillips (manadart)
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.