install-amd64-minimal-20091203.iso and install-x86-minimal-20091203.iso fail to boot when you are using both the subdir and docache options. Reproducible: Always Steps to Reproduce: 1. Create a bootable flash disk with grub 2. Copy contents of amd64 minimal install cd to a subdirectory on the flash disk(ie gentoo64) 3. Add the following kernel options to boot: subdir=gentoo64 docache Actual Results: I get: !!Failed to cache the loop file! Lack of space? and then it boots normally, mounting image.squashfs off of the flash disk Expected Results: I expect it to copy the image.squashfs onto the ramdisk and use it from there The bug is because ${LOOP} contains the subdirectory, so it executes: cp -a /newroot/mnt/cdrom//gentoo64/image.squashfs /newroot/mnt//gentoo64/image.squashfs but since the /newroot/mnt/gentoo64 directory does not exist, it fails, for both the x86 and amd64 scripts. The bug is fixed by executing: mkdir -p "`dirname ${NEW_ROOT}/mnt/${LOOP}`" before the copy operation. Here is a diff of my changes to /etc/initrd.scripts --- /home/rian/deleteme/etc/initrd.scripts 2009-12-21 09:09:36.000000000 -0700 +++ etc/initrd.scripts 2009-12-21 10:49:34.000000000 -0700 @@ -175,6 +175,8 @@ # z=$(($z + $i)) ; done # echo $z good_msg "Copying loop file for caching..." + #verify that the needed directory exists + mkdir -p "`dirname ${NEW_ROOT}/mnt/${LOOP}`" cp -a ${NEW_ROOT}/mnt/cdrom/${LOOP} ${NEW_ROOT}/mnt/${LOOP} if [ $? -ne 0 ] then
I didn't even know that option existed. I bet there's lots of random code that doesn't respect it.
This has been applied in git. Thanks.
Commit included in 3.4.10.908, closing.