grub2 floppy image with menu?
Could someone post a recipe for creating a floppy disk image with a config file, as to test the menu?
./configure
make
./grub-mkimage -v -d . -o core.img ls *.mod | sed -e 's/\\.mod//' cat boot.img core.img > floppy.dsk
but that does not include a configfile...
-- lode
_________________________________________________________________
New: download more than 350.000 tracks starting from � 0,80! http://entertainment.msn.be/muziek/musicclub
Quoted 8 lines · lode leroy
Could someone post a recipe for creating a floppy disk image with a config file,
as to test the menu?./configure
make
./grub-mkimage -v -d . -o core.imgls *.mod | sed -e 's/\\.mod//'cat boot.img core.img > floppy.dsk
This is the script I posted a while ago:
#!/bin/sh
IMAGE=grub2-floppy-i386.ext2fs
MNT=/mnt/floppy
rm $IMAGE
dd if=/dev/zero of=$IMAGE bs=512 count=2880|| exit
/sbin/mkfs.ext2 -F $IMAGE
./grub-mkimage -v -d . -o core.img ext2
sudo mount $IMAGE $MNT -o loop
mkdir $MNT/grub
cp *.img *.mod $MNT/grub
echo '(fd0)' $PWD/$IMAGE > tmp_device.map ./grub-setup -d $MNT/grub -m tmp_device.map -r '(fd0)' '(fd0)' rm tmp_device.map
cat >$MNT/grub/grub.cfg <<EOF
#GNU/Linux
insmod linux
insmod boot
insmod multiboot
title GNU/Linux
linux (hd0,4)/boot/vmlinuz-2.2.20 root=/dev/hda5
dsf
title GNU/Hurd
# GNU/Hurd
multiboot (hd0,2)/boot/gnumach root=device:hd0s3
module (hd0,2)/hurd/ext2fs.static --multiboot-command-line=\${kernel-command-line} --host-priv-port=\${host-port} --device-master-port=\${device-port} --exec-server-task=\${exec-task} -T typed \${root} \$(task-create) \$(task-resume) module (hd0,2)/lib/ld.so.1 /hurd/exec \$(exec-task=task-create)
gdsf
EOF
cat $MNT/grub/grub.cfg
sudo umount $MNT
--
Marco