Bug 982608 - initramfs fails to mount luks disks and systemd drop in an emergency console
Summary: initramfs fails to mount luks disks and systemd drop in an emergency console
Keywords:
Status: CLOSED EOL
Alias: None
Product: Fedora
Classification: Fedora
Component: systemd
Version: 20
Hardware: x86_64
OS: Linux
unspecified
unspecified
Target Milestone: ---
Assignee: dracut-maint
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-07-09 12:07 UTC by Frank Murphy
Modified: 2015-06-29 12:03 UTC (History)
16 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of: 921887
Environment:
Last Closed: 2015-06-29 12:03:44 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
boot cap one (228.24 KB, image/jpeg)
2013-07-09 14:23 UTC, Frank Murphy
no flags Details
sosreport.txt (85.26 KB, text/plain)
2013-07-16 09:28 UTC, Frank Murphy
no flags Details
Failed to boot after providing disk passphrase (93.96 KB, text/plain)
2013-12-22 21:31 UTC, Jacek Krüger
no flags Details
Log from boot failure (98.53 KB, text/plain)
2014-02-21 15:11 UTC, Brandon Nielsen
no flags Details

Description Frank Murphy 2013-07-09 12:07:31 UTC
+++ This bug was initially created as a clone of Bug #921887 +++

Description of problem:
initramfs fails to mount luks disks and systemd drop in an emergency console

dracut-029-1.fc20.x86_64
grubby-8.26-2.fc20.x86_64
systemd-sysv-205-1.fc20.x86_64
systemd-libs-205-1.fc20.x86_64
systemd-journal-gateway-205-1.fc20.x86_64
systemd-205-1.fc20.x86_64
systemd-python-205-1.fc20.x86_64
cryptsetup-python-1.6.1-1.fc20.x86_64
cryptsetup-libs-1.6.1-1.fc20.x86_64
cryptsetup-1.6.1-1.fc20.x86_64
lvm2-libs-2.02.98-9.fc20.x86_64
lvm2-2.02.98-9.fc20.x86_64


How reproducible:
always

Steps to Reproduce:
boot
  
Actual results:
emergency console

Expected results:
successful boot

Additional info: am not able to run any command at emergency prompt.

Comment 1 Frank Murphy 2013-07-09 12:08:15 UTC
PS: lsinitrd initramfs-3.10.0-1.fc20.x86_64.img | head -4
Image: initramfs-3.10.0-1.fc20.x86_64.img: 6.8M
========================================================================
dracut-029-1.fc20 with dracut modules:
i18n

Comment 2 Harald Hoyer 2013-07-09 12:58:35 UTC
can you attach the /run/initramfs/sosreport.txt?

just mount /boot manually and copy over the file

Comment 3 Frank Murphy 2013-07-09 13:45:43 UTC
(In reply to Harald Hoyer from comment #2)
> can you attach the /run/initramfs/sosreport.txt?
> 
> just mount /boot manually and copy over the file


How?, mount /boot not in /etc/fstab

mount /dev/sdg (someusbstick)   vfaf not recognised.

Comment 4 Harald Hoyer 2013-07-09 14:18:51 UTC
(In reply to Frank Murphy from comment #3)
> (In reply to Harald Hoyer from comment #2)
> > can you attach the /run/initramfs/sosreport.txt?
> > 
> > just mount /boot manually and copy over the file
> 
> 
> How?, mount /boot not in /etc/fstab
> 
> mount /dev/sdg (someusbstick)   vfaf not recognised.

doh

how did you boot to get the "lsinitrd" ?

Comment 5 Frank Murphy 2013-07-09 14:22:44 UTC
(In reply to Harald Hoyer from comment #4)
> (In reply to Frank Murphy from comment #3)
> > (In reply to Harald Hoyer from comment #2)
> > > can you attach the /run/initramfs/sosreport.txt?
> > > 
> > > just mount /boot manually and copy over the file
> > 
> > 
> > How?, mount /boot not in /etc/fstab
> > 
> > mount /dev/sdg (someusbstick)   vfaf not recognised.
> 
> doh
> 
> how did you boot to get the "lsinitrd" ?

From the working F19 kernel on the system.
https://lists.fedoraproject.org/pipermail/test/2013-July/116854.html

Comment 6 Frank Murphy 2013-07-09 14:23:33 UTC
Created attachment 771053 [details]
boot cap one

Comment 7 Frank Murphy 2013-07-10 07:54:27 UTC
Some experiments. Booting with thr fc19 kernel

yum erase kernel-*-fc20
yum update kernel
doesn't add rd.auto=1 to /boot/grub2/grub.cfg on this box.

adding it to /etc/default/grub, and grub-mkconfig -o /boot/grub2/grub.cfg
still drops to shell, with rd.auto=1 or rd.auto=0 (tested both ways)
This box /dev/mapper/(root) is opened with passphrase,
other partitions use luks keyfile,
changed /etc/crypttab to "none" for all partitions, still emergency shell.


Will keep trying.

Comment 8 Frank Murphy 2013-07-10 13:28:59 UTC
(In reply to Frank Murphy from comment #7)
> Some experiments. Booting with thr fc19 kernel
> 
> yum erase kernel-*-fc20
> yum update kernel
> doesn't add rd.auto=1 to /boot/grub2/grub.cfg on this box.
> 
> adding it to /etc/default/grub, and grub-mkconfig -o /boot/grub2/grub.cfg
> still drops to shell, with rd.auto=1 or rd.auto=0 (tested both ways)
> This box /dev/mapper/(root) is opened with passphrase,
> other partitions use luks keyfile,
> changed /etc/crypttab to "none" for all partitions, still emergency shell.
> 
> 
> Will keep trying.

Apologies was mixing up changelogs.

But as it turns out, it now appears to me that it could be systemd*, as when
rd.luks.uuid=liks-foo are all added to kernel command line it boots. So am changing to systemd. Apologies for any upset.

Comment 9 Harald Hoyer 2013-07-11 08:34:14 UTC
(In reply to Frank Murphy from comment #8)
> (In reply to Frank Murphy from comment #7)
> > Some experiments. Booting with thr fc19 kernel
> > 
> > yum erase kernel-*-fc20
> > yum update kernel
> > doesn't add rd.auto=1 to /boot/grub2/grub.cfg on this box.
> > 
> > adding it to /etc/default/grub, and grub-mkconfig -o /boot/grub2/grub.cfg
> > still drops to shell, with rd.auto=1 or rd.auto=0 (tested both ways)
> > This box /dev/mapper/(root) is opened with passphrase,
> > other partitions use luks keyfile,
> > changed /etc/crypttab to "none" for all partitions, still emergency shell.
> > 
> > 
> > Will keep trying.
> 
> Apologies was mixing up changelogs.
> 
> But as it turns out, it now appears to me that it could be systemd*, as when
> rd.luks.uuid=liks-foo are all added to kernel command line it boots. So am
> changing to systemd. Apologies for any upset.

Did you install dracut-nohostonly?
What is the output of:

# grep -r hostonly /etc/dracut.conf* /usr/lib/dracut/dracut.conf*

Comment 10 Frank Murphy 2013-07-11 08:49:01 UTC
rpm -q dracut-nohostonly
package dracut-nohostonly is not installed

grep -r hostonly /etc/dracut.conf* /usr/lib/dracut/dracut.conf
/etc/dracut.conf:#hostonly="yes"
grep: /usr/lib/dracut/dracut.conf: No such file or directory

Comment 11 Frank Murphy 2013-07-16 08:25:16 UTC
@Harald 
Looking at this bz #905683

Is vfat recognised in emergency by default?
if not, maybe should?

Comment 12 Frank Murphy 2013-07-16 09:28:55 UTC
Created attachment 774128 [details]
sosreport.txt

Finally got this, by adding vfat to dracut.

Comment 13 Frank Murphy 2013-07-20 11:03:22 UTC
testing with rd.luks.crypttab=no in /boot/grub2/grub.cfg ("no") hasn't helped.
So the only real workable solution was to rebuild initramfs without systemd.
Now my /etc/crypttab works as expected.

Comment 14 Fedora End Of Life 2013-09-16 14:27:07 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 20 development cycle.
Changing version to '20'.

More information and reason for this action is here:
https://fedoraproject.org/wiki/BugZappers/HouseKeeping/Fedora20

Comment 15 Jacek Krüger 2013-12-22 21:29:58 UTC
My fresh-updated F20 system also behaves like this. Randomly boots or not (like 50% chance to boot):
-sometimes doesn't even show passphrase prompt
-sometimes displays passphrase prompt but doesnt boot
-sometimes boots as expected
So it looks like some kind of race condition. Maybe I did something weird with partitioning. But the same setup worked in F19.

The disk is partitioned like this:
/dev/sda1 /boot/efi/ EFI unencrypted
/dev/sda2 /boot/ ext4 unencrypted
/dev/sda3 swap encrypted
/dev/sda4 / ext4 encrypted
/dev/sda5 /home ext4 encrypted

Comment 16 Jacek Krüger 2013-12-22 21:31:29 UTC
Created attachment 840464 [details]
Failed  to boot after providing disk passphrase

Comment 17 Brandon Nielsen 2014-02-21 15:11:27 UTC
Created attachment 866049 [details]
Log from boot failure

System failed to prompt for LUKS password, and thus failed to boot.

Disk tree looks like this:

NAME                                     MAJ:MIN RM   SIZE RO TYPE  MOUNTPOINT
sda                                        8:0    0 238.5G  0 disk  
├─sda1                                     8:1    0   200M  0 part  /boot/efi
├─sda2                                     8:2    0   500M  0 part  /boot
└─sda3                                     8:3    0 237.8G  0 part  
  └─luks-b0a3fa52-63d3-4b09-96b0-f8a05e92b33e
                                         253:0    0 237.8G  0 crypt 
    ├─boleyn-root                        253:1    0  19.5G  0 lvm   /
    └─boleyn-home                        253:2    0 218.3G  0 lvm   /home
sdb                                        8:16   0 465.8G  0 disk  
└─md127                                    9:127  0 465.8G  0 raid1 
  └─luks-21b06c39-2ab7-43de-8209-154ba94944f4
                                         253:3    0 465.8G  0 crypt 
    ├─bulkstorage-general                253:4    0 395.8G  0 lvm   /mnt/General
    └─bulkstorage-media                  253:5    0    70G  0 lvm   /mnt/Media
sdc                                        8:32   0 465.8G  0 disk  
└─md127                                    9:127  0 465.8G  0 raid1 
  └─luks-21b06c39-2ab7-43de-8209-154ba94944f4
                                         253:3    0 465.8G  0 crypt 
    ├─bulkstorage-general                253:4    0 395.8G  0 lvm   /mnt/General
    └─bulkstorage-media                  253:5    0    70G  0 lvm   /mnt/Media

sda was recently changed to an SSD. When it was a traditional disk, system booted fine.

Comment 18 Fedora End Of Life 2015-05-29 09:10:02 UTC
This message is a reminder that Fedora 20 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 20. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora  'version'
of '20'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 20 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 19 Fedora End Of Life 2015-06-29 12:03:44 UTC
Fedora 20 changed to end-of-life (EOL) status on 2015-06-23. Fedora 20 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.


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