Bug 1288769 - Failure to restore initramfs results in corrupted raid set on shutdown/reboot
Failure to restore initramfs results in corrupted raid set on shutdown/reboot
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: dracut (Show other bugs)
23
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: dracut-maint-list
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-12-05 17:35 EST by Rolf Fokkens
Modified: 2016-01-10 14:23 EST (History)
4 users (show)

See Also:
Fixed In Version: dracut-043-63.git20151211.fc23
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-01-10 14:23:52 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Rolf Fokkens 2015-12-05 17:35:09 EST
Description of problem: Since upgrading tot F23 my PC always boots repairing its mdraid 5 set. Further investigation showed that no pivot_root to initramfs happens.

Version-Release number of selected component (if applicable):
dracut-043-61.git20151120.fc23.x86_64

How reproducible: 100% for me


Steps to Reproduce:
1. upgrade Fedora 22 -> Fedora 23 (or just install Fedora 23, I'm not sure)
2. Build a rootfs on an mdraid set
3. Reboot
4. Notice the mdraid rebuild after boot

Actual results:
Always mdraid rebuild after (re)boot.

Expected results:
No mdraid rebuild after (re)boot

Additional info:
The issue seems to be cause by the fact that /usr/lib/dracut/dracut-initramfs-restore fails. It specifically fails on the line "mount -o ro /boot &>/dev/null" which makes sense (on my system) because /boot is booted already. The "set -e" command earlier forces the dracut-initrams-restore to bail out.

A workaround on my system is to do "mount -o remount,ro /boot &>/dev/null" instead. But I'm not sure what the intention of the mount is, if the intention is just to make sure that /boot is mount a proper solution might be "mount -o ro /boot &>/dev/null || true"
Comment 1 Rolf Fokkens 2015-12-10 11:14:57 EST
My laptop has no mdraid, but suffers from the same issue:

[root@localhost ~]# journalctl -u dracut-shutdown
...
-- Reboot --
Dec 10 15:57:05 localhost.localdomain systemd[1]: Starting Restore /run/initramfs on shutdown...
Dec 10 15:57:05 localhost.localdomain systemd[1]: Started Restore /run/initramfs on shutdown.
Dec 10 16:01:35 localhost.localdomain systemd[1]: Stopping Restore /run/initramfs on shutdown...
Dec 10 16:01:36 localhost.localdomain systemd[1]: dracut-shutdown.service: Control process exited, code=exited status=32
Dec 10 16:01:36 localhost.localdomain systemd[1]: Stopped Restore /run/initramfs on shutdown.
Dec 10 16:01:36 localhost.localdomain systemd[1]: dracut-shutdown.service: Unit entered failed state.
Dec 10 16:01:36 localhost.localdomain systemd[1]: dracut-shutdown.service: Failed with result 'exit-code'.
Dec 10 16:01:36 localhost.localdomain dracut-initramfs-restore[3600]: mount: /dev/sda2 is already mounted or /boot busy
Dec 10 16:01:36 localhost.localdomain dracut-initramfs-restore[3600]: /dev/sda2 is already mounted on /boot

After fixing this:

-- Reboot --
Dec 10 16:45:32 localhost.localdomain systemd[1]: Starting Restore /run/initramfs on shutdown...
Dec 10 16:45:32 localhost.localdomain systemd[1]: Started Restore /run/initramfs on shutdown.
Dec 10 16:49:11 localhost.localdomain systemd[1]: Stopping Restore /run/initramfs on shutdown...
Dec 10 16:49:13 localhost.localdomain systemd[1]: Stopped Restore /run/initramfs on shutdown.
Comment 2 Rolf Fokkens 2015-12-14 08:20:12 EST
Seems to be fixed upstream since July:
https://github.com/haraldh/dracut/commit/da5304aabcb7c1b541a8eeabc69627f05ad47c09
Comment 3 Fedora Update System 2016-01-08 06:03:04 EST
dracut-043-63.git20151211.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2016-7ca7599efc
Comment 4 Fedora Update System 2016-01-08 23:27:04 EST
dracut-043-63.git20151211.fc23 has been pushed to the Fedora 23 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-7ca7599efc
Comment 5 Fedora Update System 2016-01-10 14:23:49 EST
dracut-043-63.git20151211.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.

Note You need to log in before you can comment on or make changes to this bug.