Bug 467839 - mkinitrd doesn't know how to handle encrypted CCISS devices
mkinitrd doesn't know how to handle encrypted CCISS devices
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: mkinitrd (Show other bugs)
5.3
ia64 Linux
medium Severity medium
: rc
: ---
Assigned To: Peter Jones
Alexander Todorov
:
: 469131 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2008-10-21 03:51 EDT by Alexander Todorov
Modified: 2009-01-20 17:12 EST (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-01-20 17:12:44 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
anaconda.log just in case we need it (166.98 KB, text/plain)
2008-10-21 05:20 EDT, Alexander Todorov
no flags Details
handle luks on cciss (706 bytes, patch)
2008-10-21 16:15 EDT, David Lehman
no flags Details | Diff

  None (edit)
Description Alexander Todorov 2008-10-21 03:51:43 EDT
Description of problem:
System panics when trying to boot. It has encrypted partitions.

Version-Release number of selected component (if applicable):
kernel-2.6.18-118.el5

How reproducible:
always

Steps to Reproduce:
1. Install latest RHEL5.3 build with the following disk layout:
Partition         Size  Mount point FS type Format
/dev/cciss/c0d0p1 250 M none        vfat    NO
/dev/cciss/c0d0p2 400 M none        vfat    NO
/dev/cciss/c0d0p3 100 M /boot/efi   vfat    YES
/dev/cciss/c0d0p4 132 G /           ext3    YES, Encrypted

Actual results:
Install completes and system panics on boot

Expected results:
System prompts for LUKS pass phrase and boots properly

Additional info:
Main difference between the system in question and another system that doesn't exhibit the issue is the use of hardware RAID controller (see disk names).
Comment 2 Alexander Todorov 2008-10-21 05:07:59 EDT
* kernel 2.6.18-118.el5, no disk encryption - boots to run level 3

* kernel 2.6.18-118.el5, use disk encryption:

sh-3.2# blkid /dev/cciss/c0d0p4 
/dev/cciss/c0d0p4: LABEL="/" UUID="df8568f1-bf9c-4556-b343-cf3425142d5c" SEC_TYPE="ext2" TYPE="ext3" 

^^ this is the encrypted device

sh-3.2# cat /boot/efi/efi/redhat/elilo.conf 
prompt
timeout=20
default=linux
relocatable

image=vmlinuz-2.6.18-118.el5
        label=linux
        initrd=initrd-2.6.18-118.el5.img
        read-only
        append="root=LABEL=/1"


^^ label seems incorrect

sh-3.2# cat /etc/crypttab 
luks-3017a657-fd05-4557-bc4f-6620015c08f0 UUID=3017a657-fd05-4557-bc4f-6620015c08f0 none


sh-3.2# cat /etc/fstab 
/dev/mapper/luks-3017a657-fd05-4557-bc4f-6620015c08f0 /                       ext3    defaults        1 1
/dev/cciss/c0d0p3       /boot/efi               vfat    defaults        0 0
tmpfs                   /dev/shm                tmpfs   defaults        0 0
devpts                  /dev/pts                devpts  gid=5,mode=620  0 0
sysfs                   /sys                    sysfs   defaults        0 0
proc                    /proc                   proc    defaults        0 0


after boot I got:

Mounting root filesystem.
mount: could not find filesystem '/dev/root'
Setting up other filesystems.
Setting up new root fs
setuproot: moving /dev failed: No such file or directory
no fstab.sys, mounting internal defaults
setuproot: error mounting /proc:Kernel panic - not syncing: Attempted to kill init!
 No such file or  directory
setu



* try to tell kernel / is on LUKS device (panic again):
image=vmlinuz-2.6.18-118.el5
        label=linux-luks-label
        initrd=initrd-2.6.18-118.el5.img
        read-only
        append="root=/dev/mapper/luks-3017a657-fd05-4557-bc4f-6620015c08f0"


Loading dm-log.ko module
Loading dm-mirror.ko module
Loading dm-zero.ko module
Loading dm-snapshot.ko module
Waiting for driver initialization.
Kernel panic - not syncing: Attempted to kill init!
 Scanning and con

* Install kernel 2.6.18-120 from brew in rescue mode (elilo.conf entry is automatically generated) - panic again:

image=vmlinuz-2.6.18-120.el5
        label=2.6.18-120.el5
        initrd=initrd-2.6.18-120.el5.img
        read-only
        append="root=/dev/mapper/luks-3017a657-fd05-4557-bc4f-6620015c08f0"

Scanning and configuring dmraid supported devices
Creating root device.
Mounting root filesystem.
mount: could not find filesystem '/dev/root'Kernel panic - not syncing: Attempted to kill init!

Setting up oth er filesystems.
Comment 3 Alexander Todorov 2008-10-21 05:19:24 EDT
info from rescue mode:

blkid:
/dev/mapper/luks-3017a657-fd05-4557-bc4f-6620015c08f0: LABEL="/1" UUID="9af4863a-7599-4dcc-94f1-f0ed8a9e8a6c" TYPE="ext3" 
/dev/cciss/c0d0p1: LABEL="EFIPART" UUID="A476-2271" TYPE="vfat" 
/dev/cciss/c0d0p2: LABEL="HPPART" UUID="8479-1D43" TYPE="vfat" 
/dev/cciss/c0d0p3: SEC_TYPE="msdos" LABEL="/boot/efi" UUID="48FD-93AE" TYPE="vfat" 
/dev/cciss/c0d0p4: LABEL="/" UUID="df8568f1-bf9c-4556-b343-cf3425142d5c" SEC_TYPE="ext2" TYPE="ext3"

LUKS device has the label "/1" which was in elilo.conf right after install. Not sure why it has a different UUID than the ID in the name though. CC'ing dlehman to answer this.
Comment 4 Alexander Todorov 2008-10-21 05:20:55 EDT
Created attachment 320994 [details]
anaconda.log just in case we need it
Comment 5 Alexander Todorov 2008-10-21 05:22:28 EDT
To install use update image at http://dlehman.fedorapeople.org/updates-464769.img
because of bug #464769
Comment 6 Alexander Todorov 2008-10-21 09:31:08 EDT
Tried also append="root=LABEL=/1" with -120 kernel. Same result - panic

At this time I'm thinking it's anaconda issue which manifests in the kernel not finding the root file system upon boot.
Comment 7 Alexander Todorov 2008-10-21 10:21:44 EDT
FYI:
Haven't tested on other arches than ia64 exclusively but from what I know nobody from RTT has seen such behavior so far.
Comment 8 David Lehman 2008-10-21 10:44:03 EDT
What do you see on the console when the system panics? Surely there are some messages of some sort.
Comment 9 David Lehman 2008-10-21 16:13:46 EDT
The problem is mkinitrd doesn't know how to handle encrypted CCISS devices.
Comment 10 David Lehman 2008-10-21 16:15:23 EDT
Created attachment 321086 [details]
handle luks on cciss
Comment 11 Denise Dumas 2008-10-21 16:32:28 EDT
Requesting approval for Snapshot 1 since fix is available.
Comment 12 Alexander Todorov 2008-10-22 02:21:14 EDT
updated summary to reflect real cause of problem
Comment 14 David Lehman 2008-10-30 10:00:41 EDT
Fixed in mkinitrd-5.1.19.6-39.
Comment 15 David Lehman 2008-10-30 10:02:06 EDT
*** Bug 469131 has been marked as a duplicate of this bug. ***
Comment 21 errata-xmlrpc 2009-01-20 17:12:44 EST
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2009-0237.html

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