Your message dated Fri, 5 Dec 2014 10:53:18 +0100 with message-id <[email protected]> and subject line Re: Bug#772085: fai-cd creates a grub2 image that may not boot due to missing modules has caused the Debian Bug report #772085, regarding fai-cd creates a grub2 image that may not boot due to missing modules to be marked as done.
This means that you claim that the problem has been dealt with. If this is not the case it is now your responsibility to reopen the Bug report if necessary, and/or fix the problem forthwith. (NB: If you are a system administrator and have no idea what this message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact [email protected] immediately.) -- 772085: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=772085 Debian Bug Tracking System Contact [email protected] with problems
--- Begin Message ---Package: fai-server Version: 4.3.1 Severity: important When /usr/sbin/fai-cd is creating a bootable FAI Cd, it creates its GRUB core.img (/boot/grub/core.img) while referencing a mangled path for the modules. This will eventually cause a fatal GRUB error and cause the system to drop to grub> rescue on boot since most/all of the images will not be there. Relevant lines from /usr/sbin/fai-cd are below: 73 # - - - - - - - - - - - - - - - - - - - - - - - - - - 74 create_grub2_image() { 75 76 mkdir -p $tmp/boot/grub $NFSROOT/boot/grub 77 if [ -f $NFSROOT/boot/grub/core.img ]; then 78 cp $NFSROOT/boot/grub/core.img $tmp/boot/grub 79 MODULEBASE=$NFSROOT/usr/lib/grub/ 80 elif [ -f $NFSROOT/usr/lib/grub/i386-pc/cdboot.img ]; then 81 chroot $NFSROOT /usr/bin/grub-mkimage -d /usr/lib/grub/i386-pc -o /boot/grub/core.img biosdisk iso9660 --format=i386-pc 82 cp $NFSROOT/boot/grub/core.img $tmp/boot/grub 83 MODULEBASE=$NFSROOT/usr/lib/grub/ 84 else 85 echo "no grub2 installation found in NFSROOT, using downloaded $grubPackage" 86 apt-get -y -d install --reinstall grub-pc >/dev/null 87 grubPackage=`ls -rt /var/cache/apt/archives/grub-pc*|tail -1` 88 if [ -z "$grubPackage" ]; then 89 die 22 "Downloading grub2 failed." 90 fi 91 GRUBDIR=$tmp/grubPackage 92 mkdir -p $GRUBDIR 93 dpkg -x $grubPackage $GRUBDIR 94 cd $GRUBDIR 95 ./usr/bin/grub-mkimage -d usr/lib/grub/*-pc -o $tmp/boot/grub/core.img biosdisk iso9660 --format=i386-pc 96 MODULEBASE=$GRUBDIR/usr/lib/grub/ 97 fi Setting MODULEBASE= with a trailing slash will cause a mangled path when referencing it again at line 108: 108 for a in $MODULEBASE/*-pc/{*.mod,efiemu??.o,cdboot.img,boot.img,command.lst,moddep.lst,fs.lst,handler.lst,parttool.lst}; do For example, this line may expand to /usr/lib/grub//i386-pc/*.mod ...the trailing slash causes the double slash and the path to not be found, which then leads to no modules being included in the GRUB image. Kevin Newman Linux Systems Administrator [cid:[email protected]] 141 W. Jackson Blvd. Suite 500 Chicago, IL 60604 ______________________________________________ See http://www.peak6.com/email_disclaimer/ for terms and conditions related to this email
--- End Message ---
--- Begin Message --->>>>> On Fri, 5 Dec 2014 03:37:18 +0000, Kevin Newman <[email protected]> said: > Sorry, I think it was more a result of missing the grub-pc-bin > rather than the double slash ending up in the expanded path, > though I still think it would be a code improvement to remove > the trailing slash on a variable set to a directory. Closing this bug, as it's not a bug of FAI at all. I will cleanup the two slashed in a later FAI version. -- regards Thomas
--- End Message ---

