I was wanting to try out an older version of Ubuntu on my netbook; but I did not want to write the ISO image to a thumb drive to boot it; therefore I copied the ISO image to a subfolder of my /boot folder; /boot/iso and then I added this section to my /etc/grub.d/40_custom file to enable me to boot a live Linux distribution ISO from the hard disk instead of the hassle of booting from a USB thumb drive and all that jazz.
#!/bin/sh exec tail -n +3 $0 # This file provides an easy way to add custom menu entries. Simply type the # menu entries you want to add after this comment. Be careful not to change # the 'exec tail' line above. menuentry "Ubuntu 10.10 ISO" { set isofile="/boot/iso/ubuntu-10.10-desktop-i386.iso" loopback loop (hd0,1)$isofile linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile noprompt noeject initrd (loop)/casper/initrd.lz } |
I am doing this with Linux Mint 12 Debian edition and this is working perfectly. A good trick if you have downloaded an ISO on your laptop or netbook or even a desktop PC and you want to try it out before writing the ISO to anything. Just fill out the file above like I have and then run this command.
sudo update-grub |
This will update the Grub bootloader and add the custom boot menu that will allow booting the ISO on your machine.