Backport finalrd 6 to xenial and up

Bug #1895160 reported by Dimitri John Ledkov
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
finalrd (Ubuntu)
Fix Released
Undecided
Unassigned
Xenial
Fix Released
Undecided
Unassigned
Bionic
Fix Released
Undecided
Unassigned
Focal
Fix Released
Undecided
Unassigned

Bug Description

[Impact]

 * finalrd is a useful tool, that improves ability to cleanly shut down systems. It is now desired to backport it all the way back to xenial. On classic systems it will not be installed by default, but available for users to opt-in into having it. On Ubuntu Core systems it will be installed by default, and used instead of snap-shutdown. As finalrd does everything that snap-shutdown already did, and much more.

 * finalrd is only tweaked slightly in version 6 to be compatible with any systemd from xenial to groovy.

[Test Case]

Classic
 * Install finalrd
 * execute `sudo finalrd` and observe that no stderr is printed, and command exits successfully
 * check that /run/initramfs is created and populated with /run/initramfs/shutdown, binaries and libraries.
 * Reboot
 * Observe that finalrd unit is started
 ** (optional) to make observing finalrd easier add /etc/finalrd/echo.finalrd hook that does `echo $@` with a sleep
 * Shutdown, capture console-log observe that finalrd was executed

[xenial extra testcase]

 * finalrd binary package should have Task: ubuntu-core, such that when building core snap, it is installed by livebuild.

Core
 * Create custom core, core18 with finalrd preinstalled
 * Building custom Ubuntu Core 16 and Ubuntu Core 18 image with above core
 * Observe that finalrd unit is started on boot
 * Shutdown, capture console-log observe that finarld was executed.
 * Boot again
 * execute `sudo finalrd` and observe that no stderr is printed, and command exits successfully
 * check that /run/initramfs is created and populated with /run/initramfs/shutdown, binaries and libraries.

[Regression Potential]

 * Packaging & tmpfiles were changed to be compatible with older systemd versions. There are no changes to api/abi of the systemd units, or .finalrd hooks. The package is not installed by default on xenial/bionic, hence the number and type of machines affected is small. If regressions are identified, reverting to previous version of the package is safe course of action, as there are no upgrade/downgrade incompatibilities between old & new versions of finalrd.

Revision history for this message
Brian Murray (brian-murray) wrote : Please test proposed package

Hello Dimitri, or anyone else affected,

Accepted finalrd into focal-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/finalrd/6~ubuntu20.04.1 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, what testing has been performed on the package and change the tag from verification-needed-focal to verification-done-focal. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-focal. In either case, without details of your testing we will not be able to proceed.

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

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in finalrd (Ubuntu):
status: New → Invalid
Changed in finalrd (Ubuntu Focal):
status: New → Fix Committed
tags: added: verification-needed verification-needed-focal
Changed in finalrd (Ubuntu Bionic):
status: New → Fix Committed
tags: added: verification-needed-bionic
Revision history for this message
Brian Murray (brian-murray) wrote :

Hello Dimitri, or anyone else affected,

Accepted finalrd into bionic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/finalrd/6~ubuntu18.04.1 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, what testing has been performed on the package and change the tag from verification-needed-bionic to verification-done-bionic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-bionic. In either case, without details of your testing we will not be able to proceed.

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

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Revision history for this message
Ubuntu SRU Bot (ubuntu-sru-bot) wrote : Autopkgtest regression report (finalrd/6~ubuntu20.04.1)

All autopkgtests for the newly accepted finalrd (6~ubuntu20.04.1) for focal have finished running.
The following regressions have been reported in tests triggered by the package:

casper/1.445.1 (amd64)

Please visit the excuses page listed below and investigate the failures, proceeding afterwards as per the StableReleaseUpdates policy regarding autopkgtest regressions [1].

https://people.canonical.com/~ubuntu-archive/proposed-migration/focal/update_excuses.html#finalrd

[1] https://wiki.ubuntu.com/StableReleaseUpdates#Autopkgtest_Regressions

Thank you!

Revision history for this message
Steve Langasek (vorlon) wrote : Please test proposed package

Hello Dimitri, or anyone else affected,

Accepted finalrd into xenial-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/finalrd/6~ubuntu16.04.1 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, what testing has been performed on the package and change the tag from verification-needed-xenial to verification-done-xenial. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-xenial. In either case, without details of your testing we will not be able to proceed.

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

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in finalrd (Ubuntu Xenial):
status: New → Fix Committed
tags: added: verification-needed-xenial
Revision history for this message
Dimitri John Ledkov (xnox) wrote :

installed finalrd 6~ubuntu18.04.1 on bionic system.

observed that running $ sudo finalrd, manually doesn't produce any errors.

added extra hook with 6 second delay, and printing args. It did show that finalrd is running and printing things to the serial console on reboot & shutdown.

tags: added: verification-done-bionic
removed: verification-needed-bionic
Revision history for this message
Dimitri John Ledkov (xnox) wrote :

installed finalrd 6~ubuntu20.04.1 on focal system

observed that running $ sudo finalrd, manually doesn't produce any errors.

added extra hook with 6 second delay, and printing args. finalrd is running and hook is executed on shutdown as observed on the serial console.

tags: added: verification-done-focal
removed: verification-needed-focal
Revision history for this message
Dimitri John Ledkov (xnox) wrote :

installed finalrd 6~ubuntu16.04.1 on xenial system

observed that running $ sudo finalrd, manually doesn't produce any errors.

Observed that finalrd is used on shutdown too.

tags: added: verification-done verification-done-xenial
removed: verification-needed verification-needed-xenial
Revision history for this message
Dimitri John Ledkov (xnox) wrote :

Next up is building core snaps with these finalrd packages preinstalled.

Revision history for this message
Łukasz Zemczak (sil2100) wrote : Update Released

The verification of the Stable Release Update for finalrd has completed successfully and the package is now being released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

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

This bug was fixed in the package finalrd - 6~ubuntu20.04.1

---------------
finalrd (6~ubuntu20.04.1) focal; urgency=medium

  * No-change backport to focal (LP: #1895160)

finalrd (6) groovy; urgency=medium

  * xenial compat - ensure directories exist before using them
  * Change packaging to be compatible with debhelper 9
  * Update code name to 6

 -- Dimitri John Ledkov <email address hidden> Thu, 10 Sep 2020 15:53:09 +0100

Changed in finalrd (Ubuntu Focal):
status: Fix Committed → Fix Released
Changed in finalrd (Ubuntu):
status: Invalid → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package finalrd - 6~ubuntu18.04.1

---------------
finalrd (6~ubuntu18.04.1) bionic; urgency=medium

  * No-change backport to bionic (LP: #1895160)

finalrd (6) groovy; urgency=medium

  * xenial compat - ensure directories exist before using them
  * Change packaging to be compatible with debhelper 9
  * Update code name to 6

finalrd (5) focal; urgency=medium

  * Introduce hookless mode
  * Update initrd-release file to Five Man Alive

finalrd (4) eoan; urgency=medium

  * Set and export `verbose' variable for initramfs-tools, otherwise,
    finalrd fails to create shutdown initrd, resulting in shutdown hangs.

finalrd (3) cosmic; urgency=medium

  * Drop finarld hooks.
  * Do not remount /run with suid, not needed.
  * Depend on initramfs-tools-core.

 -- Dimitri John Ledkov <email address hidden> Thu, 10 Sep 2020 15:54:08 +0100

Changed in finalrd (Ubuntu Bionic):
status: Fix Committed → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package finalrd - 6~ubuntu16.04.1

---------------
finalrd (6~ubuntu16.04.1) xenial; urgency=medium

  * No-change backport to xenial (LP: #1895160)

 -- Dimitri John Ledkov <email address hidden> Thu, 10 Sep 2020 15:54:18 +0100

Changed in finalrd (Ubuntu Xenial):
status: Fix Committed → Fix Released
Revision history for this message
Dimitri John Ledkov (xnox) wrote :

finalrd is now seeded into system-image in xenial. But because it is a brand new package in -updates pocket only, it doesn't gain Task: ubuntu-core, as that is only done for packages that exist in release pocket.

Thus adding Task:ubuntu-core by hand.

description: updated
Changed in finalrd (Ubuntu Xenial):
status: Fix Released → Triaged
Changed in finalrd (Ubuntu Xenial):
status: Triaged → Fix Released
tags: added: fr-689
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.