View the Most Wanted LQ Wiki articles.
Go Back > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Ubuntu This forum is for the discussion of Ubuntu Linux.


  Search this Thread
Old 02-16-2011, 10:34 AM   #1
Registered: Jan 2009
Posts: 101

Rep: Reputation: 15
BackTrack / Grub2 ISO Boot

Ive just finished a persistent USB installation of BackTrack 4 r2 (Ubuntu based) on my USB Stick. This is all booting fine and dandy.

My goal is to add the ability to boot from another iso from my USB stick using grub2.

So far I have...

-- Copied the ISO to /boot/iso

root@bt:~# ls -l /boot/iso/
total 402372
-rw-r--r-- 1 root root 411619328 2011-02-16 16:16 HirensBootCD.13.1.iso
-- And I have add a file to the following directory ...

root@bt:~# cat /etc/grub.d/40_custom
echo "Adding 40_custom." >&2
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 "Hirens Boot CD 13.1" {
loopback loop /boot/iso/HirensBootCD.13.1.iso
linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=/iso/HirensBootCD.13.1.iso noprompt noeject
initrd (loop)/casper/initrd.lz
Can anyone else let me know what else I need to do to add this to the menu and from the ISO ??

Old 02-16-2011, 11:09 AM   #2
LQ Guru
Registered: Apr 2005
Posts: 5,817

Rep: Reputation: 1001Reputation: 1001Reputation: 1001Reputation: 1001Reputation: 1001Reputation: 1001Reputation: 1001Reputation: 1001
You will find a good tutorial here

There are tutorials both all over the web, and on this site to my knowledge. You just have to search... Use the link in my signature if need be.
Old 02-16-2011, 11:11 AM   #3
LQ Guru
Registered: Apr 2005
Posts: 5,817

Rep: Reputation: 1001Reputation: 1001Reputation: 1001Reputation: 1001Reputation: 1001Reputation: 1001Reputation: 1001Reputation: 1001
But concerning your question, all you need to do is run update-grub.
Old 02-16-2011, 11:53 AM   #4
Registered: Dec 2003
Posts: 92

Rep: Reputation: 34
If the iso doesn't show up in the boot menu, then the odds are it has something to do with the extension of the grub.cfg to find the stanza you cited. Pendrive Linux suggested directly editing grub.cfg to install such stanzas for booting multiple iso images.
-- see summary and links at TCL: multiple boot from ISO on USB pen drive

As long as you don't run update-grub (as is often done when updating kernel software in Ubuntu) and don't goof too bad on syntax, directly editing grub.cfg usually works. For the multiple boot iso with no system to refresh or update on the USB stick, an auto run of grub update to wipe out your edits won't happen. With a system on the USB stick, you'll either need to figure out how the extension to grub.cfg works or re-edit after system updates.
Old 02-17-2011, 04:53 AM   #5
Registered: Jan 2009
Posts: 101

Original Poster
Rep: Reputation: 15
Thanks for the replies...

After checking Im wondering if i am running the right version of grub to allow me to do this.

root@bt:~# grub-install -v
grub-install (GNU GRUB 0.97)
From this output it appears that I not running Grub2 ? Also considering I haven't got a grub.cfg file but only a menu.lst within my /boot/grub directory.

Does anyone know how I would go about upgrading this to grub2 ?

Last edited by felix001; 02-18-2011 at 05:20 AM.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: How To Boot An ISO With GRUB2 (The Easy Way!) LXer Syndicated Linux News 0 02-07-2011 07:42 PM
Anyone tried grub2 to boot of an iso? niravshah Linux - Newbie 12 08-03-2010 09:53 AM
Mount ISO as specific device (ie: /dev/sda1) with GRUB2 to boot KNOPPIX live cd iso BLuFeNiX Linux - General 2 12-23-2009 01:31 AM
Modifying distros iso images to boot with grub2 NightHorse Linux - Distributions 3 10-12-2009 06:46 PM
Grub2 and iso boot ---- Again niravshah Linux - Newbie 6 09-18-2009 03:32 PM

All times are GMT -5. The time now is 04:06 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration