Containers don't restart after clean host shutdown

Bug #1647312 reported by Stéphane Graber
12
This bug affects 1 person
Affects Status Importance Assigned to Milestone
lxd (Ubuntu)
Fix Released
High
Unassigned
Trusty
Fix Released
High
Unassigned
Xenial
Fix Released
High
Unassigned

Bug Description

LXD is supposed to record the containers state on host shutdown and restore them to their previous state on restart.

A change in LXD 2.6.2 and LXD 2.0.8 regressed this, so now containers need to be manually started after reboot.

Upstream bug report: https://github.com/lxc/lxd/issues/2686
Upstream fix: https://github.com/lxc/lxd/pull/2687

This will need to be SRUed very quickly.

# SRU paperwork
## Rationale
Regresses "lxd shutdown".

## Test case
 - lxc launch ubuntu:16.04 abc
 - lxd shutdown
 - ps aux | grep -q abc && echo "FAIL, container still running"
 - lxc finger
 - lxc list | grep abc | grep RUNNING

## Regression potential
Fix is pretty straightforward and specific to this issue. A test was also added as part of this, so it's very unlikely that anything else would be affected by this fix.

Changed in lxd (Ubuntu Trusty):
status: New → In Progress
Changed in lxd (Ubuntu Xenial):
status: New → In Progress
importance: Undecided → High
Changed in lxd (Ubuntu Trusty):
importance: Undecided → High
Revision history for this message
Adam Conrad (adconrad) wrote : Please test proposed package

Hello Stéphane, or anyone else affected,

Accepted lxd into xenial-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/lxd/2.0.8-0ubuntu1~ubuntu16.04.2 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed.Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, and change the tag from verification-needed to verification-done. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

Changed in lxd (Ubuntu Xenial):
status: In Progress → Fix Committed
tags: added: verification-needed
Revision history for this message
Stéphane Graber (stgraber) wrote :

We will be releasing this SRU ahead of schedule as it's a regression fix.
Autopkgtest shows a pass for all architectures.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package lxd - 2.0.8-0ubuntu1~ubuntu16.04.2

---------------
lxd (2.0.8-0ubuntu1~ubuntu16.04.2) xenial; urgency=medium

  * Fix container last-state recording (LP: #1647312)
    - 0001-Fix-container-state-recording.patch
    - 0002-tests-Test-lxd-shutdown.patch
    - 0003-Only-mark-ready-once-containers-are-up.patch

 -- Stéphane Graber <email address hidden> Mon, 05 Dec 2016 13:45:44 +0100

Changed in lxd (Ubuntu Xenial):
status: Fix Committed → Fix Released
tags: added: verification-done
removed: verification-needed
Changed in lxd (Ubuntu Trusty):
status: In Progress → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package lxd - 2.6.2-0ubuntu3

---------------
lxd (2.6.2-0ubuntu3) zesty; urgency=medium

  * Fix container last-state recording (LP: #1647312)
    - 0001-Fix-container-state-recording.patch
    - 0002-tests-Test-lxd-shutdown.patch
    - 0003-Only-mark-ready-once-containers-are-up.patch

 -- Stéphane Graber <email address hidden> Mon, 05 Dec 2016 13:33:41 +0100

Changed in lxd (Ubuntu):
status: In Progress → 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.