[Bug 910924] [NEW] livecd: initrd: scripts/casper-helpers: fstype returns ext3 on luks container

Launchpad Bug Tracker 910924 at bugs.launchpad.net
Tue Jan 3 00:36:45 UTC 2012


You have been subscribed to a public bug:

Trying to boot ubuntu 11.10  from livecd iso image via grub.

menuentry "Ubuntu" {
  iso_path=/ubuntu-11.10-desktop-i386.iso
  export iso_path
  search --set --file $iso_path
  loopback loop $iso_path
  root=(loop)
  configfile /boot/grub/loopback.cfg
}

However, booting fails w/ an initramfs prompt stating that /dev/sda2
could not be mounted.

/dev/sda2 is a luks container.

/dev/sda7 contains ubuntu-11.10-desktop-i386.iso

Cause: in initrd.lz: file casper-helpers calls /bin/fstype. fstype returns FSTYPE=ext3 for /dev/sda2 (which is a luks container). 
find_path() in lupin-helpers then fails to mount /dev/sda2 using fstype ext3 dropping to an initramfs prompt.

fstype version:
ba50b66bff0437ff23e6e729de8f5d69 /bin/fstype

Solution: Unpack casper/initrd.lz, disable  call to fstype and repack
initrd.lz. Boot the iso file using the patched initrd.lz.

Patch:

--- casper-helpers      2012-01-02 18:28:21.000000000 +0100
+++ scripts/casper-helpers   2012-01-02 01:06:41.000000000 +0100
@@ -41,11 +41,11 @@
 get_fstype() {
     local FSTYPE
     local FSSIZE
-    eval $(fstype < $1)
-    if [ "$FSTYPE" != "unknown" ]; then
-        echo $FSTYPE
-        return 0
-    fi
+    #eval $(fstype < $1)
+    #if [ "$FSTYPE" != "unknown" ]; then
+    #    echo $FSTYPE
+    #    return 0
+    #fi
     /sbin/blkid -s TYPE -o value $1 2>/dev/null
 }

New grub config:

menuentry "Ubuntu" {
  iso_path=/ubuntu-11.10-desktop-i386.iso
  export iso_path
  search --set --file $iso_path
  loopback loop $iso_path
  root=(loop)
  linux   /casper/vmlinuz  file=/cdrom/preseed/ubuntu.seed boot=casper iso-scan/filename=${iso_path} quiet splash -- lang=de
  initrd (hd0,7)/ubuntu-11.10-desktop-i386-initrd.lz
}

** Affects: casper (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: bot-comment
-- 
livecd: initrd: scripts/casper-helpers: fstype returns ext3 on luks container
https://bugs.launchpad.net/bugs/910924
You received this bug notification because you are a member of Ubuntu Foundations Bugs, which is subscribed to casper in Ubuntu.




More information about the foundations-bugs mailing list